This is the mail archive of the xsl-list@mulberrytech.com mailing list .


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: XHTML+XSL --> XSL


Yes. Probably.

The only issue with this (it is not solved my way, anyway) is that the 
webmaster in our company uses DreamWeaver, and with that crap he cannot 
edit XML documents.

I think what I'll do is:

- Start from: a "source.html" file which is the same as the proposed one 
except the first line, which makes DreamWeaver go mad, as it thinks it's 
PHP code. Store that in our CVS repository.

- Prepare a publishing script that:
   - Adds the right first line
   - Converts that document into an XSL document which IMPORTs some 
templates, using my HTML2XSL XSL file.

- On production, XML documents are processed by the generated XSL files.


Anything simpler, to be able to import the templates, from the Literal 
Result Element as Stylesheet?

Antonio


> What you need is probably simplified stylesheet syntax, aka "Literal 
> Result Element as Stylesheet", see 
> http://www.w3.org/TR/xslt.html#result-element-stylesheet
> This way xslt instructions can be embedded into any xml document.
> You have just declare xsl namespace and provide xsl:version attribute.
>
> <?xml version="1.0" encoding="iso-8859-1"?>
> <!DOCTYPE html
>     PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
>     "DTD/xhtml1-transitional.dtd">
> <html xsl:version="1.0"
>       xmlns:xsl="http://www.w3.org/1999/XSL/Transform";>
> <head>
> <title>Some title with weird entities like&nbsp;&eacute;&icirc;</title>
> </head>
> <body>
>       <xsl:value-of select="/doc/somenode/something" />
>       <xsl:apply-templates select="/doc/otherthings" />
> </body>
> </html>
>




 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]