[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] Embedded stylesheets
hi, I have tried to use an embedded xslt stylesheet according to example in Michael Kays XSLT Programmers Reference 2nd edition on page 109 but it does not seem to work as desired by me. Extract of my xml-file is at end of message. If I look at the result with IE 6 it shows the headers OK but it also all other text (with default template). I tried to translate it using XMLStarlert (http://xmlstar.sourceforge.net/) that complained xml-stylesheet : no ID backup found My question is: should this way of using embedded stylesheets work or is it very much dependent on spaciel features of various xslt engines? regards Kaarle -- Kaarle Kaila email: kaarle dot kaila at iki dot fi www.iki.fi/kaila <?xml version="1.0" encoding="UTF-8"?> <?xml-stylesheet type="text/xsl" href="#backup"?> <genealog><owner><ownername>Kaarle Kaila</ownername><ownerinfo>Kallen lisätietoa Tämä tulee riville 2 ja tässä näin riville 3 (Cyrillic text)?????? ???????? on rivillä 4</ownerinfo><address><street>Kalenteritie 23 B 4</street><postalcode>02200</postalcode><postoffice>Espoo</postoffice><count ry>Suomi</country> <email>kaarle.kaila@xxxxxx</email></address><mediapath>Kaila</mediapath></ow ner> <xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0" id="backup"> <xsl:template match="xsl:sylesheet"/><xsl:template match="genealog"><html><body><h1>suku-backup</h1><xsl:apply-templates/></bod y></html></xsl:template><xsl:template match="units"><xsl:apply-templates/></xsl:template><xsl:template match="unit"><xsl:value-of select="./name"/><br/></xsl:template></xsl:stylesheet> <units> <unit unitid="I1" tag="INDI" sex="F" createdate="2004-01-16"><name><givenname>Liisa Annikki</givenname><surname>Koski</surname></name><notices><notice tag="NAME" row="1" createdate="2004-01-16"><name><givenname>Liisa Annikki</givenname><surname>Kaila</surname></name></notice> <notice tag="BIRT" row="2" createdate="2004-01-16"> <date><start>19180929</start></date><place>Hämeenkyrö</place><name/></notice > <notice tag="DEAT" row="3" createdate="2004-01-16"> <date><start>19880531</start></date><place>Espoo</place><name/></notice> <notice tag="OCCU" row="4" createdate="2004-01-16"><description>Vaatesuunnittelija</description><name/> </notice></notices></unit> <!-- more unit elements --> </units> <!-- other elements --> </genealog> XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
|
PURCHASE STYLUS STUDIO ONLINE TODAY!Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced! Download The World's Best XML IDE!Accelerate XML development with our award-winning XML IDE - Download a free trial today! Subscribe in XML format
|