xsl-list
[Top] [All Lists]

declare the charset by an output element not the xml declaration?

2004-06-15 07:39:48
Hallo,
we want to hold the charset of the stylesheet flexibel. Is it well formed to
give no encoding in the xml declaration but in the output element?

Many thanks,
markus

<?xml version="1.0"?>
<xsl:stylesheet version="1.0"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform";>

<xsl:template match="/">
<html>
<head>
<xsl:processing-instruction name='output'>
  <xsl:text>method="html"
</xsl:text><xsl:text>encoding="</xsl:text><xsl:value-of
select="$etc/et[attribute::name = 'charset']" /><xsl:text>"</xsl:text>
</xsl:processing-instruction>
<title></title>
</head>

<body>
  <xsl:apply-templates />
</body>
</html>
</xsl:template>



<Prev in Thread] Current Thread [Next in Thread>