Skip to main content

This site requires you to update your browser. Your browsing experience maybe affected by not having the most up to date version.

We're retiring the forums!

The SilverStripe forums have passed their heyday. They'll stick around, but will be read only. We'd encourage you to get involved in the community via the following channels instead:

General Questions /

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

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

Template printing template code SS 2.4


Go to End


3 Posts   545 Views

Avatar
dylangrech92

Community Member, 17 Posts

25 October 2013 at 1:50am

This: <% _t( 'Appeak.Name', 'Name' ) %>
Prints: <% _t( 'Appeak.Name', 'Name' ) %>

Any idea why this is happening?

I have this template in root/themes/themeName/templates/AppeakPokerWidget.ss,
code in: root/appeakpoker
lang files in: root/appeakpoker/lang

Yes I have these in the lang file:
global $lang;
$lang[ 'en_US' ][ 'Appeak' ][ 'Name' ] = 'Name';

Avatar
Bereusei

Community Member, 96 Posts

25 October 2013 at 4:35am

Edited: 25/10/2013 4:36am

I think, whitespace is missing, before and after %, isn't it?
<% _t('Appeak.Name','Name') %>

Avatar
dylangrech92

Community Member, 17 Posts

25 October 2013 at 7:05pm

Thanks man, it never crossed my mind that, that would have been the problem thanks :)