martinix Posted May 2, 2014 Share Posted May 2, 2014 Hi, I changed blockuserinfo module template in theme folder to fit our needs and used smarty language codes to view some front office strings but after upload of modified tpl it shows only searched string (only English). This modul is only module on whole page that dont show translation Here is changed code: <ul id="header_nav"> {if $logged} <li id="your_account"> <a href="{$link->getPageLink('my-account', true)}" title="{l s='View my customer account' mod='blockuserinfo'}" class="account" rel="nofollow"><span>{l s='Welcome' mod='blockuserinfo'} {$cookie->customer_firstname} {$cookie->customer_lastname}</span></a> <a href="{$link->getPageLink('index', true, NULL, "mylogout")}" title="{l s='Log me out' mod='blockuserinfo'}" title="{l s='Log out' mod='blockuserinfo'}" class="logout" rel="nofollow">{l s='Log out' mod='blockuserinfo'}</a> {else} <li id="header_user_info"> <form action="index.php?controller=authentication&back=my-account" method="post" id="login_form" class="std"> <div class="form_content clearfix"> <ul> <li><h1>{l s='sign in' mod='blockuserinfo'}</h1> <li><input placeholder="{l s='E-mail address'}" type="text" id="email" name="email" value="" class="account_input" /> <li><input placeholder="{l s='Password'}" type="password" id="passwd" name="passwd" value="" class="account_input" /> <li><input type="hidden" class="hidden" name="back" value="my-account" /> <input type="submit" id="SubmitLogin" name="SubmitLogin" class="button" value="Log in" /> <li><a href="http://www.claristore.cz/index.php?controller=authentication">{l s='Create your account'}</a> </ul> </div> </form> </li> {/if} </ul> Do you know what I did wrong? I have no idea Thank you Link to comment Share on other sites More sharing options...
vekia Posted May 2, 2014 Share Posted May 2, 2014 for {l} functions you have to use mod='' param instead of: {l s='Create your account'} use: {l s='Create your account' mod='blockuserinfo'} Link to comment Share on other sites More sharing options...
martinix Posted May 2, 2014 Author Share Posted May 2, 2014 ok, but this string is not in blockuserinfo. I want to use Create your account from front-office translation authentication "group". Is that possible? Link to comment Share on other sites More sharing options...
vekia Posted May 3, 2014 Share Posted May 3, 2014 im confused. you said that you modified blockuserinfo.tpl file and strings there appear only in english. they appear only in english because you forgor about mod='' variable inside {l} functions, Link to comment Share on other sites More sharing options...
martinix Posted May 3, 2014 Author Share Posted May 3, 2014 (edited) I changed it but it still does not work because I dont have added these strings in module translation. I originally want to use prestashop front office translation, not a module translate because I find it unnecessary when it was translated once by presta. I think when I remove mod="" then it finding in front-office translation and not in modules. It is right or I dont get it? Edited May 3, 2014 by martinix (see edit history) Link to comment Share on other sites More sharing options...
vekia Posted May 3, 2014 Share Posted May 3, 2014 no, it's not right. if you use {l} function in module .tpl files - you have to use mod='' parameter and translate these texts from "installed modules translations" Link to comment Share on other sites More sharing options...
martinix Posted May 5, 2014 Author Share Posted May 5, 2014 Oh, Okthat I need to know Thank you Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now