Re: [SMARTY-DEV] Need for an answer: quotes or no quotes around smarty functions parameters ?

From: Date: Mon, 09 Feb 2004 16:48:20 +0000
Subject: Re: [SMARTY-DEV] Need for an answer: quotes or no quotes around smarty functions parameters ?
References: 1  Groups: php.smarty.dev 
Request: Send a blank email to php-smarty-dev+get-2096@lists.php.net to get a copy of this message
On Mon, Feb 09, 2004 at 05:28:49PM +0100, Katana wrote: > Hi, > > I need to know when quotes are needed and where they have to be omitted > when adding parameters to a smarty function. > I'm attempting to cleanup formsess a bit, and I have to admit it's quite > a mess :) > > So: > - are they needed when a parameter is a single string with no smarty > variables ? you should quote them, but when the value is an identifier ( /\w+/ ), you don't need to: {assign var=foo ...} and {assign var="foo" ...} are the same. only the following words have different meaning when not quoted: true, false, yes, no, on, off, null > - are they needed around a parameter which is a single smarty variable ? no. greetings messju > Thanks in advance, > > Katana

« previous php.smarty.dev (#2096) next »