You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@lenya.apache.org by Jörn Nettingsmeier <po...@uni-duisburg.de> on 2006/03/21 11:20:29 UTC

Re: module (doctype) specific css?

(moving this thread to dev...)

Andreas Hartmann wrote:
> Joern Nettingsmeier wrote on the user list:
>> hi *!
>>
>>
>> i have a custom module that implements a cforms-based doctype.  pages of
>> this type need special css styles (not the default stuff that's defined
>> in my publication's page2html.xsl).
>>
>> problem is: the xsl of a module is supposed to produce a <div
>> id="body"/>, i.e. no chance to add another <link rel="stylesheet"../> to
>> the header.
>>
>> what's the cleanest way to accomplish this? i want this solution to work
>> with different publications (i.e. no modification of
>> publication-specific code) and with an unpatched lenya (i.e. no
>> modification of core code).
> 
> I guess it's not possible without modifying publication code.
> 
> You could add another format to the resource type which produces a
> complete XHTML including <head>, or just the XHTML head, or just
> the CSS:
> 
>   <format name="xhtml-page" uri="..."/>

btw, the same issue arises when you try to use the "odt to xhtml" 
stylesheet from http://books.evc-cit.info/odf_utils/odt_to_xhtml.html to 
spiff up the opendocument resource type (great work btw!). it relies 
heavily on additional css.

it's probably best to have one format that creates the <div id="body"/> 
and one that produces all necessary additional header lines (most likely 
script and css references). iiuc, the default publication pipeline 
should then aggregate this and the page2xhtml.xsl needs to include it.

the question is, how should it be wrapped?
i don't really like how the content snippet is marked with <div 
id="body"/>. the wrapper should be an element from an internal 
namespace, not from xhtml imho.

plus in the case of additional header tags, there is no legal wrapper 
element in xhtml.


wdyt?



-- 
"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: pol-admin@uni-duisburg.de, Telefon: 0203/379-2736

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lenya.apache.org
For additional commands, e-mail: dev-help@lenya.apache.org


Re: module (doctype) specific css?

Posted by Joern Nettingsmeier <po...@uni-duisburg.de>.
Andreas Hartmann wrote:
> Jörn Nettingsmeier wrote:
>> (moving this thread to dev...)
>>
>> Andreas Hartmann wrote:
>>> Joern Nettingsmeier wrote on the user list:
>>>> hi *!

>>> I guess it's not possible without modifying publication code.
>>>
>>> You could add another format to the resource type which produces a
>>> complete XHTML including <head>, or just the XHTML head, or just
>>> the CSS:
>>>
>>>   <format name="xhtml-page" uri="..."/>
>>
>> btw, the same issue arises when you try to use the "odt to xhtml"
>> stylesheet from http://books.evc-cit.info/odf_utils/odt_to_xhtml.html
>> to spiff up the opendocument resource type (great work btw!). it
>> relies heavily on additional css.
>>
>> it's probably best to have one format that creates the <div
>> id="body"/> and one that produces all necessary additional header
>> lines (most likely script and css references). iiuc, the default
>> publication pipeline should then aggregate this and the page2xhtml.xsl
>> needs to include it.
>>
>> the question is, how should it be wrapped?
>> i don't really like how the content snippet is marked with <div
>> id="body"/>. the wrapper should be an element from an internal
>> namespace, not from xhtml imho.
> 
> OK, this makes sense.

any suggestions? i'm not too familiar with what's going on in the
"lenya:" namespace, but what about lenya:body and lenya:header?

>> plus in the case of additional header tags, there is no legal wrapper
>> element in xhtml.
> 
> We could use a complete XHTML document, including headers and body.
> The reason for not doing this was that some elements have to be
> stripped (e.g., /head/title), which could cause confusion.
> 
> Is there anything apart from CSS references which has to be
> included in the XML returned by the format?

<script/> comes to mind. but why have any restrictions at all?

best,

jörn



-- 
"Án nýrra verka, án nútimans, hættir fortíðin að vekja áhuga."
"Without new works, without the present the past will cease to be of
interest."
        - Ásmundur Sveinsson (1893-1982)

--
Jörn Nettingsmeier, EDV-Administrator
Institut für Politikwissenschaft
Universität Duisburg-Essen, Standort Duisburg
Mail: pol-admin@uni-duisburg.de, Telefon: 0203/379-2736


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lenya.apache.org
For additional commands, e-mail: dev-help@lenya.apache.org


Re: module (doctype) specific css?

Posted by Andreas Hartmann <an...@apache.org>.
Jörn Nettingsmeier wrote:
> (moving this thread to dev...)
> 
> Andreas Hartmann wrote:
>> Joern Nettingsmeier wrote on the user list:
>>> hi *!
>>>
>>>
>>> i have a custom module that implements a cforms-based doctype.  pages of
>>> this type need special css styles (not the default stuff that's defined
>>> in my publication's page2html.xsl).
>>>
>>> problem is: the xsl of a module is supposed to produce a <div
>>> id="body"/>, i.e. no chance to add another <link rel="stylesheet"../> to
>>> the header.
>>>
>>> what's the cleanest way to accomplish this? i want this solution to work
>>> with different publications (i.e. no modification of
>>> publication-specific code) and with an unpatched lenya (i.e. no
>>> modification of core code).
>>
>> I guess it's not possible without modifying publication code.
>>
>> You could add another format to the resource type which produces a
>> complete XHTML including <head>, or just the XHTML head, or just
>> the CSS:
>>
>>   <format name="xhtml-page" uri="..."/>
> 
> btw, the same issue arises when you try to use the "odt to xhtml" 
> stylesheet from http://books.evc-cit.info/odf_utils/odt_to_xhtml.html to 
> spiff up the opendocument resource type (great work btw!). it relies 
> heavily on additional css.
> 
> it's probably best to have one format that creates the <div id="body"/> 
> and one that produces all necessary additional header lines (most likely 
> script and css references). iiuc, the default publication pipeline 
> should then aggregate this and the page2xhtml.xsl needs to include it.
> 
> the question is, how should it be wrapped?
> i don't really like how the content snippet is marked with <div 
> id="body"/>. the wrapper should be an element from an internal 
> namespace, not from xhtml imho.

OK, this makes sense.


> plus in the case of additional header tags, there is no legal wrapper 
> element in xhtml.

We could use a complete XHTML document, including headers and body.
The reason for not doing this was that some elements have to be
stripped (e.g., /head/title), which could cause confusion.

Is there anything apart from CSS references which has to be
included in the XML returned by the format?

-- Andreas

-- 
Andreas Hartmann
Wyona Inc.  -   Open Source Content Management   -   Apache Lenya
http://www.wyona.com                      http://lenya.apache.org
andreas.hartmann@wyona.com                     andreas@apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lenya.apache.org
For additional commands, e-mail: dev-help@lenya.apache.org