Subject: Re: [xsl] xbind:module == xsl:script + an essential layer of indirection From: "Clark C. Evans" <cce@xxxxxxxxxxxxxx> Date: Sat, 3 Mar 2001 04:07:35 -0500 (EST) |
On Sat, 3 Mar 2001, Jeni Tennison wrote: > Perhaps it was the situation where the scripts are in a separate, > imported stylesheet? Namespace resolution is local to a particular > entity, so if just because you have the prefix 'date' in your script > module stylesheet doesn't mean that you have to use it in the > stylesheet importing it. The XSLT processor uses the local mapping. > So I could have: > > --- mymodule.xsl --- > <xsl:stylesheet xmlns:date="http://datestuff.com/xslt/extensions"> > <xsl:script implements-prefix="date" language="perl" > src="http://datestuff.com/xslt/extension/impl/dates.pl"/> > <xsl:script implements-prefix="date" language="javascript" > src="http://datestuff.com/xslt/extension/impl/dates.js"/> > </xsl:stylesheet> > --- > > and then have: > > --- mystylesheet.xsl --- > <xsl:stylesheet xmlns:d="http://datestuff.com/xslt/extensions"> > ... > <xsl:value-of select="d:today()" /> > ... > </xsl:stylesheet> > --- Ok. I stand corrected here. You do have to read the WD carefully to construct this meaning. > So, as Steve said, the above are *completely* identical. The only > difference is the amount of typing that you have to do to associate a > piece of code with a particular namespace. Hmm. Ok. Steve, I owe you an apology for not doing my proper homework on this one. ;) (a) this still only has a single "resolution" mechanism for discovering implementations (b) it'd be cool if the WD used an example with a non-trivial uri so that this was more clear. Thanks! Clark XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
Re: [xsl] xbind:module == xsl:scrip, Jeni Tennison | Thread | Re: [xsl] xbind:module == xsl:scrip, Clark C. Evans |
Re: [xsl] Working with QNames in va, Curt Arnold | Date | Re: [xsl] RDDL as a delivery vehicl, Clark C. Evans |
Month |