Re: [xslt] document('')



Matt Sergeant writes:
> > Data: typed data in stylesheet
> > (189 ...src/xml/libxslt-1.0.19/xsltproc) ./xsltproc -V
> > Using libxml 20422, libxslt 10019 and libexslt 710
> 
> Right. So is this an issue with parsing a string instead? What does
> xsltproc do if you pipe the stylesheet to it? Or can't you do that?
> 
I didn't know that you can, but it seems to work:

xsltproc 
cat ~/xslt-att/doctest.xsl | xsltproc - ~/xslt-att/x.xml 


Data: typed data in stylesheet

xsltproc -V
Using libxml 20422, libxslt 10018 and libexslt 709
xsltproc was compiled against libxml 20422, libxslt 10019 and libexslt 710
libxslt 10018 was compiled against libxml 20420
libexslt 709 was compiled against libxml 20420

(I accidentially did a make install in the xsltproc subdir only, so this
is xsltproc 1.0.19 compiled against 1.0.19 but using libxslt 1.0.18;
the latter is the relevant version here)

cat ~/xslt-att/doctest.xsl | ./xsltproc - ~/xslt-att/x.xml
-:1: error: Document is empty

^
-:1: error: Start tag expected, '<' not found

^


Data: 

./xsltproc -V
Using libxml 20422, libxslt 10019 and libexslt 710
xsltproc was compiled against libxml 20422, libxslt 10019 and libexslt 710
libxslt 10019 was compiled against libxml 20422
libexslt 710 was compiled against libxml 20422

So yes, using document('') on stylesheets not providing a base url
does not work with xsltproc either.

Did you read the thread
http://mail.gnome.org/archives/xslt/2002-June/thread.html#00055 ?

Daniel comments the problems there.

greetings
	Morus



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]