Web Wiz - Green Windows Web Hosting

  New Posts New Posts RSS Feed - Viewtable- unable to extract data
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

Viewtable- unable to extract data

 Post Reply Post Reply
Author
erinbrockovich View Drop Down
Newbie
Newbie


Joined: 12 February 2004
Status: Offline
Points: 7
Post Options Post Options   Thanks (0) Thanks(0)   Quote erinbrockovich Quote  Post ReplyReply Direct Link To This Post Topic: Viewtable- unable to extract data
    Posted: 17 February 2004 at 7:43pm

Hi,

This program aims at dispaying a table whose xml island is given by xmlisland.xml.Howevere, I am unable to extract data out of the xml island into the table. Could someone help me figure out why?

<!-- file viewtable.xml-->

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

<xsl:template match="/">

<TABLE Align="Center" Border="2" src = "xmlisland.xml">

<TR>

<TD><FONT Color="Navy"><B><center>PCB P/N</center></B></FONT></TD>

<TD><FONT Color="Navy"><B>Module P/N</B></FONT></TD>

<TD><FONT Color="Navy"><B>Panel Size</B></FONT></TD>

<TD><FONT Color="Navy"><B>PCB Panel</B></FONT></TD>

<TD><FONT Color="Navy"><B>BOM#</B></FONT></TD& gt;

<TD><FONT Color="Navy"><B>PCB Size</B></FONT></TD>

<TD><FONT Color="Navy"><B>Date Issued</B></FONT></TD>

<TD><FONT Color="Navy"><B>Proto Run Lot#</B></FONT></TD>

</TR>

<xsl:apply-templates select="root/attributes"/>

<TR>

</TR>

</TABLE>

</xsl:template>

<!--

* Template Match Section

-->

<xsl:template match="root/attributes">

<TR>

<xsl:if test="change='false'">

<xsl:attribute name="onmouseover">this.bgColor = '#BEC5DE'</xsl:attribute>

<xsl:attribute name="onmouseout">this.bgColor = 'white'</xsl:attribute>

</xsl:if>

<xsl:if test="change='true'">

<xsl:attribute name="bgColor">red</xsl:attribute>

</xsl:if>

<TD>

<Input>

<xsl:attribute name="attribute"><xsl:value-of select="attribute"/></xsl:attribute>

<xsl:attribute name="value"><xsl:value-of select="value"/></xsl:attribute>

</Input>

</TD>

</TR>

</xsl:template>

<DIV ID="DIVXMLDisp"></DIV>

<script language="vbscript">

Sub window_onload()

DIVXMLDisp.innerHTML = BINDXSLXML(XMLViewtable, "http://www2.sing.micron.com/module/new/project/viewtable.xs l", "")

MSgbox AttrDisp.XML

End Sub

 

Function BindXSLXML(xmlisland, cStyleSheet, cSrchCrit)

set stylesheet= CreateObject("MSXML2.DOMDocument")

stylesheet.async= false

stylesheet.load (cStyleSheet)

if cSrchCrit <> "" Then

set searchnode = stylesheet.selectsinglenode("//xsl:apply-templates")

searchnode.setAttribute "select", cSrchCrit

end if

BindXSLXML= xmlisland.transformnode(stylesheet)

set stylesheet= nothing

End Function

</script>

 

Thanks!

Back to Top
 Post Reply Post Reply

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 12.08
Copyright ©2001-2026 Web Wiz Ltd.


Become a Fan on Facebook Follow us on X Connect with us on LinkedIn Web Wiz Blogs
About Web Wiz | Contact Web Wiz | Terms & Conditions | Cookies | Privacy Notice

Web Wiz is the trading name of Web Wiz Ltd. Company registration No. 05977755. Registered in England and Wales.
Registered office: Web Wiz Ltd, Unit 18, The Glenmore Centre, Fancy Road, Poole, Dorset, BH12 4FB, UK.

Prices exclude VAT at 20% unless otherwise stated. VAT No. GB988999105 - $, € prices shown as a guideline only.

Copyright ©2001-2026 Web Wiz Ltd. All rights reserved.