Jump to:

23461 Posts in 18908 Topics by 2878 members

General Questions

SilverStripe Forums » General Questions » set locale to de_DE works except for a few tiny exceptions...

General questions about getting started with SilverStripe that don't fit in any of the categories above.

Moderators: martimiz, Sean, biapar, Willr, Ingo, swaiba, simon_w

Page: 1
Go to End
Author Topic: 1002 Views
  • tchintchie
    Avatar
    Community Member
    63 Posts

    set locale to de_DE works except for a few tiny exceptions... Link to this post

    hello it´s me again!

    as mentioned above I have successfully set the locale for the whole site to German and it´s actually working EXCEPT for:

    BLOG MODULE: it still show´s the "comments" in English down next to the "read more" link. Strangely enough underneath the headline of each blog entry the work "Kommentare" seems to work :-/ Also I tried to change the "tag cloud" headline into something like "Stichworte" since our users are mainly retirees and probably never heard of anything like tag clouds... oh and the date on the bottom is still displayed in English too....

    EVENT_CALENDAR MODULE: actually perfectly translated except for the month name "M�rz 2011" (March) in the monthNav on top of the calendar widget. It´s displayed correctly as "März" in the headline and drop down month picker :-?

    SEARCH BUTTON: though "Los" is actually German I wanted to change the button to display "Suchen" because it makes the function more obvious...not only to retirees I have already changed the line

    $lang['de_DE']['AdvancedSearchForm']['GO'] = 'Suchen';

    from the /lang/de_DE.php in my sapphire directory from "Los" to "Suchen" but without effect.... also the search results page still shows "read more about ...." instead of the German line....everything else is correctly translated though.

    quite strange...any hints are most welcome

    kind regards from Austria!

    PS: included two screenies

    Attached Files
  • Invader_Zim
    Avatar
    Community Member
    141 Posts

    Re: set locale to de_DE works except for a few tiny exceptions... Link to this post

    Hi.

    It's been a while since i taught my blog to "speak" german, but i'll try my best...

    If i recall right, the word "comments" is hardcoded into your BlogSummary.ss (some line at the bottom).
    So replace it there with either <% _t('COMMENTS', 'Comments') %> , or Kommentare.

    Don't know why you can't change the TagCloud heading, since it works for me.
    Here is the code of my TagCloudWidget.ss (maybe it helps):

    <h3>$Title</h3>
    <div class="tagcloud">
    <% control TagsCollection %>
    <a href="$Link" title="Zeige alle Artikel unter '$Tag'" class="$Class tooltip">$Tag</a>
    <% end_control %>
    </div>

    I can't help with the event calendar module, 'cause i never used it.
    Search button: don't know...
    But have a look at Page_results.ss, the string "read more about ...." is hardcoded there, too

    Servus
    Christian

  • tchintchie
    Avatar
    Community Member
    63 Posts

    Re: set locale to de_DE works except for a few tiny exceptions... Link to this post

    Hi Chris!

    Thanks a lot for the effort However most of our codes seem to differ...probably due to different versions?? Here´s my blog summary:

    <div class="blogSummary">
       <h2 class="postTitle"><a href="$Link" title="<% _t('VIEWFULL', 'View full post titled -') %> '$Title'">$MenuTitle</a></h2>
       <p class="authorDate"><% _t('POSTEDBY', 'Posted by') %> $Author.XML <% _t('POSTEDON', 'on') %> $Date.Long | <a href="$Link#PageComments_holder" title="Kommentare lesen">$Comments.Count <% _t('COMMENTS', 'Kommentare') %></a></p>
       <% if TagsCollection %>
          <p class="tags">
             Tags:
             <% control TagsCollection %>
                <a href="$Link" title="View all posts tagged '$Tag'" rel="tag">$Tag</a><% if Last %><% else %>,<% end_if %>
             <% end_control %>
          </p>
       <% end_if %>
       
       <p>$Content.FirstParagraph(html)</p>
       
       <p class="blogVitals"><a href="$Link#PageComments_holder" class="comments" title="Kommentare zu diesem Beitrag ansehen">$Comments.Count comments</a> | <a href="$Link" class="readmore" title="Lesen Sie den ganzen Beitrag">Lesen Sie den ganzen Beitrag</a></p>
    </div>


    As you can see there´s no <% _t('COMMENTS', 'Comments') %> line on the bottom whereas on the top there is...which is where I already changed it into "Kommentare" and it works. So where do the bottom comments come from??
    Our TagCloudWidgets seem to differ too:

    <p class="tagcloud">
       <% control TagsCollection %>
          <a href="$Link" class="$Class">$Tag</a>
       <% end_control %>
    </p>


    For some reason I managed to change "browse by date" to "nach Datum durchsuchen" in the archivewidget.php. I tried the same for "tagcloud" in the tagcloudwidget.php but without success :-/

    Trotzdem vielen Dank! At least you solved my search results issue ;-)

    liebe Grüsse!

  • Invader_Zim
    Avatar
    Community Member
    141 Posts

    Re: set locale to de_DE works except for a few tiny exceptions... Link to this post

    Hi,

    i totally forgot that i messed around quite a lot in my blog installation (v.0.4.1)...

    But have a look at the code you posted (4th line from the bottom):
    ... <a href="...">$Comments.Count comments</a> ...,
    change it to <a href="...bla">$Comments.Count Kommentare</a>...
    and it should work

    Cheers
    Christian

  • tchintchie
    Avatar
    Community Member
    63 Posts

    Re: set locale to de_DE works except for a few tiny exceptions... Link to this post

    Ha!

    You´re a genius! I didn´t dare mess around with that coz I thought it was some kind of command line!

    thanks for the help!!!!

    PS: anyone got a solution for my other problems??? :->

    1002 Views
Page: 1
Go to Top

Want to know more about the company that brought you SilverStripe? Then check out SilverStripe.com

Comments on this website? Please give feedback.