Home. 
.

transparent

transparent

transparent

Altova Mailing List Archives


XML and Viewlink component

From: "Ilya Volodin" <ivolodin@---.--->
To: NULL
Date: 8/5/2004 2:53:00 PM
Hello,
I'm trying to transform XML document into HTML using XSLT. But one of the
tags should be transformed into viewlink tag. XSL doesn't allow me to insert
<HTML xmlns:viewlink> instead of regular <HTML> tag into output. How can I
go around it?
Here's what I'm trying to do:

 <xsl:template match="/">
  <HTML xmlns:viewlink>         <---- Error on this line. Desc - "A name
contained an invalid character. Error processing resource"
  <?IMPORT NAMESPACE="VIEWLINK" IMPLEMENTATION="bars.htc"?>
   <BODY>
    <xsl:apply-templates/>
   </BODY>
  </HTML>
 </xsl:template>

  <xsl:template match="dropdown">
   <xsl:variable name="questionID" select="../@id"/>
   <xsl:variable name="bars"
select="document('responses.xml')/root/response[@id=$loginName]/question[@id
=$questionID]"/>
   <VIEWLINK:bars>        <--- If I use just <HTML> error in this line:
Desc - "Reference to undeclared namespace prefix: 'VIEWLINK'. Error
processing resource".
  <script type="JavaScript">
    var bars=new Array();
    <xsl:for-each select="$bars/bar">
     bars[{@id}]={@selected};
    </xsl:for-each>
  </script>
   </VIEWLINK:bars>
  </xsl:template>

Thanks in advance for your help.

            Ilya Volodin




transparent
Print
Mail
Like It
Disclaimer
.

These Archives are provided for informational purposes only and have been generated directly from the Altova mailing list archive system and are comprised of the lists set forth on www.altova.com/list/index.html. Therefore, Altova does not warrant or guarantee the accuracy, reliability, completeness, usefulness, non-infringement of intellectual property rights, or quality of any content on the Altova Mailing List Archive(s), regardless of who originates that content. You expressly understand and agree that you bear all risks associated with using or relying on that content. Altova will not be liable or responsible in any way for any content posted including, but not limited to, any errors or omissions in content, or for any losses or damage of any kind incurred as a result of the use of or reliance on any content. This disclaimer and limitation on liability is in addition to the disclaimers and limitations contained in the Website Terms of Use and elsewhere on the site.

.
.

transparent

transparent