Re: [xsl] FW: match="/"

Subject: Re: [xsl] FW: match="/"
From: Joerg Heinicke <joerg.heinicke@xxxxxx>
Date: Mon, 06 Jan 2003 20:42:30 +0100
Hello William,

there is a difference between the root node and the root element. Change the match pattern to "/*" and it will work.

Regards,

Joerg

Lopez, William wrote:
Resending as plain text...

-----Original Message-----
From: Lopez, William Sent: Monday, January 06, 2003 10:08 AM
To: xsl-list@xxxxxxxxxxxxxxxxxxxxxx
Subject: match="/"



Hello:


I thought that match="/" was a match on the root node. I cannot retrieve the
value of an attribute from the root node by using an AVT (without specifying
the root node). What I'm missing? XML & XSL snippets below.

Thanks,

XML:
<?xml version="1.0" encoding="ISO-8859-1"?>
<!DOCTYPE WorkGroupMaint SYSTEM "../dtd/workassignmentworkgroupmaint.dtd">
<?xml-stylesheet type="text/xsl" href="../xsl/workassignmentmaint.xsl" ?>
<WorkGroupMaint entryMode="VIEW" screenID="WORKGROUPMAINT" userID="XXXXXX"
servletPath="../WorkGroupMaintServlet" fieldError="" updateComplete=""
duplicateItem="" isDirty="">
  <BusinessUnitRef oid="0:0:0:1" name="BU01">
...

XSL:
<?xml version='1.0'?>
<xsl:stylesheet version="1.0"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform";>
<xsl:variable name="servletPath" select="WorkGroupMaint/@servletPath"/>
<xsl:output method="html" doctype-public="-//W3C//DTD HTML 4.0 Strict//EN"
indent="yes"/>
<xsl:template match="/">
  <html>
    <head>
      <title>Work Assignment Maintenance- Work Group</title>
      <link rel="stylesheet" type="text/css" href="../css/wt_view.css"/>
    </head>
    <body onload="document.frmWorkTypeView.btnInquire.focus();">
    <input type="hidden" name="hfEntryMode"
value="{WorkGroupMaint/@entryMode}"/>  <-- Works
    <input type="hidden" name="hfScreenID" value="{@screenID}"/> <-- Doesn't
work
    ...

Will Lopez
EDS - Health & Insurance Application Solution Centre
MS C3-1C-37
5400 Legacy Drive
Plano, TX 75024 ( phone: +01-972-604-3372 (834-3372)
/ william.lopez@xxxxxxx
8 www.eds.com


XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list




XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list


Current Thread