PHP Manual
PEAR Manual
Smarty Manual
PostgreSQL
MySQL Manual
Perl Manual
Ciekawe adresy
- T-shirt promocyjny
- Szkoła tańca Warszawa
- Upominki reklamowe
- Tłumacz
- Serwis Konica Minolta
- Agencja Interaktywna
- Odzież Specjalistyczna
- Wypożyczalnia Samochodów Łódź
Czytnik RSS
» Wasko partnerem Interactive IntelligenceUmowa pozwoli Wasko rozszerzyć ofertę działu telekomunikacji i wzmocnić obecność na rynku, szczególnie w sektorze administracji publicznej i rządowej.
» Uniwersytet Missouri: małe baterie atomowe
Baterie nuklearne, wytwarzające energię z rozkładu radioizotopów są atrakcyjną propozycją do wielu zastosowań, ponieważ izotopy, które je zasilają mogą dostarczać użytecznej ilości prądu przez setki lat przy gęstościach elektrycznych milion razy wyższych niż w standardowych bateriach. Baterie atomowe służyły wojsku i służbom powietrznym przez wiele lat, jednak ich duża wielkość ograniczała powszechne użytkowanie.
» SAP sfinalizował zakup Sybase i poprawia wyniki
Sybase będzie działać jako osobna firma, kierowana przez dotychczasowego szefa - Johna Chena, nadal zajmując się bazami danych i systemami informacji zarządczej.
» Adobe przejmuje producenta aplikacji webowych
Koncern Adobe zgodził się wyłożyć 240 mln USD na zakup firmy Day Software Holding, specjalizującej się w tworzeniu oprogramowania webowego (głównie aplikacji z zakresu zarządzania treścią na stronach WWW oraz pracy grupowej online).
{include}
{include} tags are used for including other templates in the current template. any variables available in the current template are also available within the included template. the {include} tag must have the attribute "file", which contains the template resource path.
you can optionally pass the 'assign' attribute, which will specify a template variable name that the output of {include} will be assigned to instead of displayed.
all assigned variables' values are restored after the scope of the included template is left. this means you can use all variables from the including template inside the included template. but changes to variables inside the included template are not visible inside the including template after the {include} statement.
| attribute name | type | required | default | description |
|---|---|---|---|---|
| file | string | yes | n/a | the name of the template file to include |
| assign | string | no | n/a | the name of the variable that the output of include will be assigned to |
| [var ...] | [var type] | no | n/a | variable to pass local to template |
you can also pass variables to included templates as attributes. any variables explicitly passed to an included template as attributes are only available within the scope of the included file. attribute variables override current template variables, in the case they are named alike.
example 7-11. {include} and assign to variable this example assigns the contents of nav.tpl to the $navbar variable, which is then output at the top and bottom of the page.
|
use the syntax for template resources to include files outside of the $template_dir directory.
example 7-12. {include} template resource examples
|
see also {include_php}, {php}, template resources and componentized templates.
Najskuteczniejsza reklama to pozycjonowanie - Pozycjonowanie stron <= zajrzyj tu i dowiedz się więcej o pozycjonowanie stron