OK,

I guess I'm being particularly slack brained today.
If I have a bit of xml like this

<rdf>
 <desc about="foo">
    .... nested nodes
 </desc>
 <desc about="bar">
    .... nested nodes
 </desc>
 <desc about="baz">
    .... nested nodes
 </desc>
</rdf>

and a stylesheet like this

<xsl:stylesheet >
<xsl:param name="which_d" />

<xsl:template match="rdf">
 <html><body><h2>descriptions</h2>
 <xsl:apply-templates select="*[@about = $which_d]" />
</body></html>
</xsl:template>

<xsl:template match="desc">
 .. etc. ...
</xsl:template>

Using sabcmd I could specify which <desc> to process with
sabcmd a.xsl a.xml  '$which_d=foo'

How can I specify in the xsl that the default value (if which_d not supplied)
should match all <desc>  ?

cheers


Tim



Reply via email to