Re: [SMARTY] Associative arrays with spaces

From: Date: Tue, 06 Apr 2004 17:29:22 +0000
Subject: Re: [SMARTY] Associative arrays with spaces
References: 1  Groups: php.smarty.general 
Request: Send a blank email to php-smarty-general+get-11240@lists.php.net to get a copy of this message
On Tue, Apr 06, 2004 at 12:05:12PM -0400, Graham Yardley wrote: > Forgot the $ signs the first time > > If i assign an array with Associative keys that include spaces how would > display them in smarty? > example php > > assign('dimension', array('dimension name' => 'length', > 'inches' => 46)); > > smarty that does not work > {$dimension.dimension name} > {$dimension.dimension name} way #1: {assign var=key value="dimension name"}{$dimension.$key} way #2: avoid spaces and special characters in array-keys. HTH messju

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