Andreas Hartmann wrote:
Hi Lenya devs,

currently, the default publication includes a resource-type specific
CSS by default:

<xsl:when test="$document-type">
<link rel="stylesheet" href="{$root}/css/{$document-type}.css" type="text/css"/>
</xsl:when>

This leads to exceptions in the logs when the CSS does not exist.
Can't we find a better way to support resource-type specific CSS?

modules should be able to inject their own xhtml header tags, not just a <div id="body"/>. that's the only way for modules to use their own css without violating the soc principle. the publication has no way of knowing that its modules need css.

the quickest solution would be for modules to produce fragments:

<link rel="stylesheet"...>
<div id="body">
  ...
</div>

and for the page2xhtml.xsl of the publication to merge those in.

the problem is what to do with those extra tags: do they replace any existing ones, or are they added? if added, will they end up before or after the publication-global tags? (very important in the case of css.)

we will probably have to handle every single xhtml header element on its own:

title: must replace the pub-global one
[EMAIL PROTECTED]'stylesheet']: should be added after any pub-global ones.
[EMAIL PROTECTED]'SHORTCUT ICON']: must replace the global one
etc...

setting meta tags in modules should be discouraged for simplicity.



--
"Open source takes the bullshit out of software."
        - Charles Ferguson on TechnologyReview.com

--
Jörn Nettingsmeier, EDV-Administrator
Institut für Politikwissenschaft
Universität Duisburg-Essen, Standort Duisburg
Mail: [EMAIL PROTECTED], Telefon: 0203/379-2736

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to