Hello Emmanuelle!
On Mar 8, 2010, at 22:54 , emmanuelle roux wrote:
>
>
> Hello !
>
> I'm happy, i'm almost understanding how works ezpublish ..... yes !
>
> But i can't go to sleep without one last answer ....
Haha, eZ Publish is catching you, you are on the right track :) Keep on !
>
> My website will have 3 types of page : the frontpage (index) / the page from
> 'Agence' section (green) and the page from 'formation' section (orange).
>
> The frontpage doesn't resemble the others pages but .... there's only 1
> pagelayout .....
>
> Must I write this approximately ?
>
> {if $current_node_id.eq(2)}
> include (index.tpl)
> {else if $current_section.eq(1)} /*section 1 -> agence*/
> include(agence.tpl)
> {else}
> include(formation.tpl)
> {/if}
>
> Is there an another way ?
As Carlos said, there a much handier way to do this: use the override system.
On this page :
http://ez.no/doc/ez_publish/technical_manual/4_x/reference/template_override_conditions
scroll down a bit until 'pagelayout.tpl', you will see you can use any of the
node/view/*.tpl override conditions, plus the persistent variable. Several
applications of this to satisfy your problematic:
* Have a section per subtree, and have 'section' as an override condition
* Set the persistent variable to a specific value from the view templates, and
match the override rule on this value
Let us know how things went,
--
Nicolas
>
> Thanks for your help
> Friendly,
>
> Emmanuelle Roux
> Les Clefs du Net
>
> Organisme de formation dédié au Multimédia / Centre de productions numériques
> www.les-clefs-du-net.com
>
>
> --
> Sdk-public mailing list
> [email protected]
> http://lists.ez.no/mailman/listinfo/sdk-public
--
Nicolas Pastorino
eZ Community Manager
community portal : http://share.ez.no
twitter : jeanvoye
skype : bimbamboombimbla
phone : +33 (0)671791318
eZ Systems | http://ez.no
--
Sdk-public mailing list
[email protected]
http://lists.ez.no/mailman/listinfo/sdk-public