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]

How generate encoding="ISO-8859-1" in the XML output?


Hi all!

Can any body tell me how cal generate <?xml version="1.0"
encoding="ISO-8859-1"?>  in the XML output
because   MSXML generates <?xml version="1.0" encoding="UTF-16"?> discard
the sentence
 <xsl:output method="xml" indent="yes" encoding="ISO-8859-1" />?

The only way I've found is

 <?xml version="1.0" encoding="ISO-8859-1"?>
    <xsl:stylesheet version="1.0"
     xmlns:xsl="http://www.w3.org/1999/XSL/Transform";
     xsl:exclude-result-prefixes="user" >

     <xsl:output method="xml" indent="yes" omit-xml-declaration="yes" />
      <xsl:template match="/">

         <!-- Unica forma que he encontrado de generar
"encoding="ISO-8859-1'" -->
         <xsl:text disable-output-escaping='yes'>&lt;?xml version="1.0"
encoding="ISO-8859-1"?></xsl:text>

         <Valores>
            <Valor>Valor devuelto por función F1(): <xsl:value-of
select="user:F1(string(//URL))" /></Valor>
            <Valor>Valor devuelto por función F2(): <xsl:value-of
select="user:F2(2222)" /></Valor>
         </Valores>
     </xsl:template>


  </xsl:stylesheet>

Thanks in advance

Cristóbal


 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]