The problem is that you're trying to use a result-tree fragment as a node-set. 
You need the exslt node-set() function. Luckily its supported well in libxml 
so you just need to add to your xsl:stylesheet element

xmlns:exslt='http://exslt.org/common'
extension-element-prefixes='exslt'

and then you can call node-set(), which you do at the point where you use your 
variable, so it becomes node-set($leftcontent).



On Wednesday 17 September 2003 02:57 am, Vaclav Barta wrote:
> Hi,
>
> I'd like to add some random decoration to my pages and thought I'll use the
> document() XSLT function to pull it in - but it causes internal AxKit
> errors...
>
> I have the attached stylesheet set up to transform XML documents (I
> simplified it for this posting to ignore the source document, but the
> original uses it successfully). The stylesheet stopped working after I
> added the variable declaration calling the document() function:
>
>   <xsl:variable name="leftcontent"
> select="document('http://localhost/gcgi/left.cgi')/vocabulary"/>
>
> http://localhost/gcgi/left.cgi is a valid URL returning the attached
> text/xml. But, when I try to access the composed XML document, I get 500
> Internal Server Error; the apache error log (also attached) says a lot of
> things, most importantly IMHO
>
> [AxKit] [Error] Can't coerce GLOB to string in entersub at
> /usr/lib/perl5/site_perl/5.8.0/i586-linux-thread-multi/Apache/AxKit/Languag
>e/LibXSLT.pm line 124.
>
> What am I doing wrong? Is my XSLT syntax correct? Is document() supported
> by AxKit?
>
>       Bye
>               Vasek
>
> P.S. AxKit 1.62, LibXML 1.54, libxml2 20508, Apache 1.3.28.

-- 
Tod Harter
Giant Electronic Brain
http://www.giantelectronicbrain.com

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to