Jump to:

22977 Posts in 11738 Topics by 2826 members

General Questions

SilverStripe Forums » General Questions » v2.3.2 multi language switcher on template problem

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: 801 Views
  • kudesign
    Avatar
    Community Member
    64 Posts

    v2.3.2 multi language switcher on template problem Link to this post

    I got multi language to work in v2.3.2, and now trying to set up the 'available language' code in my template:

    <% if Translations %>
    <ul class="translations">
    <% control Translations %>
    <li class="$Locale.RFC1766">
    <a href="$Link" hreflang="$Locale.RFC1766"
    title="$Title">
    <% sprintf(_t('SHOWINPAGE','Show page in %s'),$Locale.Nice)%>
    </a>
    </li>
    <% end_control %>
    </ul>
    <% end_if %>

    After applying this code into my template, I could not get it to read properly, this is what I see on my live pages:

    <% sprintf(_t('SHOWINPAGE','Show page in %s'),)%>

    How do I change this to say 'See this page in English' or 'See the page in <the language available>'

    This is what my page look like now: http://www.nisglass.co.nz/glass/home-3/

    Hope someone can help me out here, cheers!!

    801 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.