ah, thanks abel.
yes, once i threw the xsl:key in there, it threw off the paths i had
already set up in my xml document (by one directory!)
it seems that the path was being called relative to the php document
instead of the xml document once the xsl:key was implemented.
now let's see if i can solve the rest of my problems with out much trouble.
also thanks for the system-output. i am using libsxlt instead of
sablotron. and i did know i was still on version 1.0.
thanks again!
Dale Tan wrote:
is there something I am not putting into my stylesheet that enables
keys and the document() function to co-exist in my stylesheet?
At work i have been successful in implementing keys and using the
document() function in the same stylesheet. But that is on a windows box.
I am working on a dreamhost system, php 5.2.1. I am either using the
sablotron processor or libxslt, but am not 100% sure. I know that
sounds a little silly, but I don't knew which proecessor i am using to
transform my stylesheets. if anyone knows which i am using, please
feel free to enlighten me.
Lookup the list guidelines: it has an instruction on how to get the
version and name of any xslt processor. In short, you should use the
following command somewhere in your stylesheet and note its output:
<xsl:value-of select="system-property('xsl:version')" />
<xsl:value-of select="system-property('xsl:vendor')" />
why would I be getting that error and not have my xml documents load
up into my page?
You state that it does work on a windows box and that it does not work
on a linux box. The most likely reason is a path problem. Are your paths
equal on both systems? Can you try a small test with the following,
silly, obfuscated way of outputting the stylesheet content itself? It
uses both a key function and the document function. If you get an error
with it about the path, then I think there's a bug with your processor.
If you don't get an error about the path, then you should check the
paths of your current XML:
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
version="1.0">
<xsl:key name="t" match="xsl:variable" use="@name" />
<xsl:variable name="test" />
<xsl:template match="/">
<xsl:copy-of select="document(string(key('t', 'test')/@nothing))"/>
</xsl:template>
</xsl:stylesheet>
call the above stylesheet with the stylesheet itself as XML input.
Cheers,
-- Abel Braaksma
------------------------------
--~------------------------------------------------------------------
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
or e-mail: <mailto:xsl-list-unsubscribe(_at_)lists(_dot_)mulberrytech(_dot_)com>
--~--