cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Russell Castagnaro <russ...@synctank.com>
Subject Re: Transform an XML document to several formats
Date Fri, 10 Mar 2000 18:05:59 GMT
Shouldn't you be able to make a custom processor that checks to see what type of
client is accessing the page, then use the correct XSL file??


Mikael Ståldal wrote:

> On Fri, 10 Mar 2000, Ulrich Mayring wrote:
>
> > Quite easy, make document.xml an XML document that calls the
> > PDF-stylesheet and document.html an XML document that calls the HTML
> > stylesheet.
>
> You mean that I should maintain two copies of the same XML document.
> I don't like that solution.
>
> > However, I'm not sure if this way of setting things up is good.
>
> It's not.
>
> > What I
> > would do is have a central document.xml and make the distinction
> > between
> > PDF and HTML in the stylesheet it calls. How to do that exactly depends
> > on your site organisation. For example, if you have an HTML page with a
> > button "This HTML page as PDF", then in the stylesheet for that HTML
> > page you can generate for this PDF button an URL like
> > "http://yourserver.domain.com/document.xml?type=pdf". In your stylesheet
> > you read that parameter and call the PDF-making stylesheet, whereas in
> > the absence of this parameter you serve an HTML page.
>
> How do I read an URL parameter from a stylesheet? Can you show an
> example?
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: cocoon-users-unsubscribe@xml.apache.org
> For additional commands, e-mail: cocoon-users-help@xml.apache.org

--

Russell Castagnaro
Chief Mentor
SyncTank Solutions
http://www.synctank.com

Earth is the cradle of mankind; one does not remain in the cradle forever
-Tsiolkovsky



Mime
View raw message