Smarty Forum Index Smarty
WARNING: All discussion is moving to https://reddit.com/r/smarty, please go there! This forum will be closing soon.

errror config load in parent template

 
This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies.    Smarty Forum Index -> Smarty 3
View previous topic :: View next topic  
Author Message
gtraxx
Smarty Regular


Joined: 08 Jan 2008
Posts: 56

PostPosted: Fri Nov 12, 2010 10:47 am    Post subject: errror config load in parent template Reply with quote

Hello, I use config_load to load in the entire application variables that are translated.
However, since the stable release, I am obliged to call my files containing the variables in each TPL, before I called him once.
Code:
{config_load file="localize_{sessionlang}.conf"}

Can not call the file once as a parent. Crying or Very sad
Back to top
View user's profile Send private message
U.Tews
Administrator


Joined: 22 Nov 2006
Posts: 5068
Location: Hamburg / Germany

PostPosted: Fri Nov 12, 2010 1:58 pm    Post subject: Reply with quote

In Smarty3 the default scope of config variables loaded with {config_load} has always been local. That means they are available in the templates which has the {config_load} and it's subtemplates, but not in the parent template.

But you can make them available in the parten template by using the scope attribute {config_load .... scope=parent}.

nothing has change here since a while. (But it's different from Smarty2 as it did not have real scopes}
Back to top
View user's profile Send private message
Display posts from previous:   
This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies.    Smarty Forum Index -> Smarty 3 All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group
Protected by Anti-Spam ACP