Re: [SMARTY] "Smart" nesting of templates

From: Date: Mon, 10 Jun 2002 11:53:40 +0000
Subject: Re: [SMARTY] "Smart" nesting of templates
References: 1  Groups: php.smarty.general 
Request: Send a blank email to php-smarty-general+get-4721@lists.php.net to get a copy of this message
On Mon, 10 Jun 2002 13:35:55 +0200 <24hdev@chaoscontent.com> wrote: > Hi there, I am standing in front of a serious design problem and would > appreciate some ideas. [skipped] > How would you avoid this? It should basically work that way: > - The first class (article) is displayed. Since the header was not > displayed yet, it is displayed first. Since there is more output later, > the footer is NOT displayed yet. > - The second class (image) is displayed. Since the header was already > displayed, it is NOT displayed again. > - The third class (comments) is displayed. Since this is the last, the > footer is displayed after everything else. > This sequence of three steps is just an example. It will change > depending on what content is requested. [skipped] You can implement this by using additional features of the {section} function. Read and look examples in smarty manual about 'first' and 'last' variables. ".. Sections also have their own variables that handle section properties. These are indicated like so: {$smarty.section.sectionname.varname} .." -- Sincerely yours, Grigory V. Kareev, Lead developer RRF.ru development group

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