Re: [SMARTY] Variable Scope and Default values in Config files

From: Date: Thu, 11 Jul 2002 15:30:13 +0000
Subject: Re: [SMARTY] Variable Scope and Default values in Config files
References: 1  Groups: php.smarty.general 
Request: Send a blank email to php-smarty-general+get-5252@lists.php.net to get a copy of this message
From an assignment the variable is $submenu, and from a config file the variable is #submenu#, so there is no scoping issue for that matter. Avern Williams wrote:
A line from one of my templates looks like this: {section name=SubMenu loop=$submenu} I would like to assign $submenu a default value, just in case no value was passed. If I set a value for $submenu in a config file and then also pass a value for $submenu when calling the template, which value gets precedence? I guess I'm just not sure if the config file variables are for global static values, global default values, or both. Can anyone please shed some light? thanks, Avern _________________________________________________________________ Chat with friends online, try MSN Messenger: http://messenger.msn.com
-- Monte Ohrt <monte@ispi.net> Director of Technology, ispi Inc.

« previous php.smarty.general (#5252) next »