Subject: [xsl] Question with XSLT: pass parameters to JSP From: "Ping Chen" <cecho77@xxxxxxxxxxx> Date: Wed, 12 Mar 2003 10:52:17 -0500 |
//users-attr.xsl;
<TABLE BORDER="2">
<TR>
<TD>Name</TD>
<TD>Type</TD>
<TD>Attributes</TD>
<TD>RuleSets</TD>
</TR>
<xsl:for-each select="DataSource">
<TR>
<TD><font color="blue"><xsl:value-of select="@name"/></font><br/></TD>
<TD><font color="blue"><xsl:value-of select="@type"/></font><br/></TD>
<TD><font color="blue"><a href="editAttribute.jsp?dsname={@name}">edit</a></font><br/></TD>
<TD><font color="blue"><a href="editRuleSets.jsp?dsname={@name}">edit</a></font><br/></TD>
</TR>
</xsl:for-each>
</TABLE>
<xsl:variable name="param1" select="//DataSource[1]/@name"/> <xsl:variable name="param2" select="//DataSource[1]/X-RuleSet[1]/@name"/>
<a href="nextstep.jsp?p1={$param1}&p2={$param2}">next step</a>
//users-attr.xml;
<?xml version="1.0" encoding="UTF-8"?>
<?xml:stylesheet type="text/xsl" href="users-attr.xsl"?>
<!DOCTYPE PMML PUBLIC "Vacuum 1.0" "users.dtd">
<PMML version="2.0">
<Header/>
<DataSource name="ds1" type="database">
<X-Database driver="sun.jdbc.odbc.JdbcOdbcDriver" password="user" table="t1" url="jdbc:odbc:test" username="user"/>
<DataDictionary numberOfFields="2">
<DataField isCyclic="0" name="a" optype="continuous"/>
<DataField isCyclic="0" name="b" optype="continuous"/>
</DataDictionary>
<X-RuleSet name="rs1">
<X-Rule name="r1" type="bin">
<X-BinaryRule lag="1" leftSide="a" operator="lt" rightSide="b" type="laggedAttribute" useGrouping="0"/>
</X-Rule>
<X-Rule name="r2" type="bin">
<X-BinaryRule lag="0" leftSide="a" operator="lt" rightSide="b" type="attribute" useGrouping="0"/>
</X-Rule>
<X-Rule name="r3" type="bin">
<X-BinaryRule lag="0" leftSide="a" operator="lt" rightSide="3" type="value" useGrouping="0"/>
</X-Rule>
<X-Rule name="r4" type="cond">
<X-ConditionalRule attribute="a" useGrouping="0">
<X-Literal>AND</X-Literal>
<X-Literal>(</X-Literal>
<X-Literal>
<X-BinaryRule lag="0" leftSide="a" operator="gt" rightSide="1.0" type="value" useGrouping="0"/>
</X-Literal>
<X-Literal>)</X-Literal>
<X-BinaryRule lag="0" leftSide="a" operator="gt" rightSide="1.0" type="value" useGrouping="0"/>
</X-ConditionalRule>
</X-Rule>
<X-Rule name="rrrrr" type="bin">
<X-BinaryRule lag="0" leftSide="a" operator="lt" rightSide="1" type="value" useGrouping="0"/>
</X-Rule>
</X-RuleSet>
</DataSource>
<DataSource name="ds2" type="database">
<X-Database driver="sun.jdbc.odbc.JdbcOdbcDriver" password="user" table="t1" url="jdbc:odbc:test" username="user"/>
<DataDictionary numberOfFields="2">
<DataField isCyclic="0" name="a" optype="continuous"/>
<DataField isCyclic="0" name="b" optype="continuous"/>
</DataDictionary>
<X-RuleSet name="rs1">
<X-Rule name="r1" type="bin">
<X-BinaryRule lag="1" leftSide="a" operator="lt" rightSide="b" type="laggedAttribute" useGrouping="0"/>
</X-Rule>
<X-Rule name="r2" type="bin">
<X-BinaryRule lag="0" leftSide="a" operator="lt" rightSide="b" type="attribute" useGrouping="0"/>
</X-Rule>
<X-Rule name="r3" type="bin">
<X-BinaryRule lag="0" leftSide="a" operator="lt" rightSide="3" type="value" useGrouping="0"/>
</X-Rule>
<X-Rule name="r4" type="cond">
<X-ConditionalRule attribute="a" useGrouping="0">
<X-Literal>AND</X-Literal>
<X-Literal>(</X-Literal>
<X-Literal>
<X-BinaryRule lag="0" leftSide="a" operator="gt" rightSide="1.0" type="value" useGrouping="0"/>
</X-Literal>
<X-Literal>)</X-Literal>
<X-BinaryRule lag="0" leftSide="a" operator="gt" rightSide="1.0" type="value" useGrouping="0"/>
</X-ConditionalRule>
</X-Rule>
<X-Rule name="rrrrr" type="bin">
<X-BinaryRule lag="0" leftSide="a" operator="lt" rightSide="1" type="value" useGrouping="0"/>
</X-Rule>
</X-RuleSet>
</DataSource>
</PMML>
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
RE: [xsl] Comparing two xml documen, Ragulf Pickaxe | Thread | [xsl] Auto-Numbering, Jack Cane |
[xsl] Comparing two xml documents, Ragulf Pickaxe | Date | RE: [xsl] dynamic XPath?, Yue Ma |
Month |