Re: Multiple procession instruction for different content-types

Hello Reto,

Reto Bachmann-Gmuer writes:

> Is there a way to set multiple xml-stylesheet instructions in a document
> specifing for which target content-type which stylesheet shoul be used.
> 
> I imagine something like:
> <?xml-stylesheet href="2html.xsl" type="text/xml" target="text/html"?>
> <?xml-stylesheet href="2plain.xsl" type="text/xml" target="text/plain"?>
> <?xml-stylesheet href="2rss.xsl" type="text/xml" target="text/rss+xml"?>
> 
> Is there a way I can do something similar? Thanks for any pointer.

No, there is no way to indicate what format the output of the style
sheet is. You can have multiple style sheet PIs for different media
types, different style sheet languages or just to provide
alternatives, but the result of applying the style sheet is assumed to
be a rendering on the screen, printer or whatever (depending on the
media), not a new file. That XSL can do transformations as well as
styling is a feature of XSL, but the style sheet PI is only meant for
styling.

There is currently no standard way to deliver a document in the form
of a pair of one XSLT and one other XML document. MIME types, such as
used for the Web and for e-mail, only indicate one type at a time. To
indicate that a document is delivered in the form of a program to
generate it, rather than as the document itself, needs some technology
that doesn't exist yet.



Bert
-- 
  Bert Bos                                ( W 3 C ) http://www.w3.org/
  http://www.w3.org/people/bos/                              W3C/ERCIM
  bert@w3.org                             2004 Rt des Lucioles / BP 93
  +33 (0)4 92 38 76 92            06902 Sophia Antipolis Cedex, France

Received on Friday, 19 September 2003 11:34:15 UTC