Developer forum

Forum » Development » DW Page Lifecycle

DW Page Lifecycle

Kevin O''Driscoll
Reply

We set a Configuration Type on each  page and is available always at the page level (we also set this value to session at the same time)

If I wanted to use this page value in a paragraph, it is not available in the paragraph, I think its to  do with the page lifecycle in DW

Is there a way to get this value reliably from the page attribute, or will I always have to try and get the session value?

Again I need to understand more about the page lifecycle, so far I think:

Load:
Load Navigation
Load Paragraphs (so I suspect the session value will be the last session value loaded since the page is not loaded yet?)
Load Page (here we set the current session value)

Is this correct?

What other load events are there? Is there some complete documentation for this somewhere?


Replies

 
Mikkel Ricky
Reply

You can get Website and Page properties in all templates by using the @Item.Area and @Item.Page tags, e.g.

<!--@Item.Area.ShowCartPageId-->
<!--@Item.Page.BackgroundColor-->

See the documentation for further details: Item.Area.[FieldSystemName] and Item.Page.[FieldSystemName]

Note that these tags are not reported when using @DwTemplateTags, but they are always set and can be used in any template.

Best regards,
Mikkel

 

You must be logged in to post in the forum