Saturday 08 December 2007 2:51:35 am
Hiya Sébastien,
If you which to dynamically include stylesheets or javascript to your webpage you need to place your stylesheets or javasctpt in the stylesheet or javascript folder of your siteaccess and include them in the override of the design.ini file : http://ez.no/doc/ez_publish/technical_manual/3_10/reference/configuration_files/design_ini
You can then use the ezini operator to extract the data: http://ez.no/doc/ez_publish/technical_manual/3_8/reference/template_operators/data_and_information_extraction/ezini
And you create specifique conditions for each section:
You then place something like this in the override of your page_head.tpl template for example:
{if $module_result.uri|contains('/myfolder')}
{def $stylesheets = ezini('StylesheetSettings', 'MyFolderSiteCSS', 'design.ini')}
{foreach $stylesheets as $stylesheet}
<link rel="stylesheet" type="text/css" href={"stylesheet"|ezdesign} media="screen" />
{/foreach}
{undef $stylesheets}
{/if}
This works in the same way for javascript files. There are probably ways of reducing this but this should work.
|