[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

Re: AW: document

Subject: Re: AW: document
From: Mike Brown <mike@xxxxxxxx>
Date: Fri, 24 May 2002 14:29:05 -0600 (MDT)
Re: AW:  document
Stefan Groschupf wrote:
> <xsl:message>The document is:
>   <xsl:value-of
> select="document('http://localhost/econtent/Content.do?state=resource&resour
> ce=250')" />
> </xsl:message>
> 
> This does not give any xml back in my output.

value-of is just going to give you the string-value of the root node, which is
going to be the concatenation of all the text node descendants. So you might
be getting XML but it just doesn't contain any text. Like value-of on this
doc: 
  <foo><bar a="baz"/></foo>

would give you an empty string. So the fact that nothing comes back may not be
telling you anything. I would do something like

<xsl:value-of select="concat('there are ',
  count(document('http://...')//node()),
  ' nodes in that document!')" />

Also, you need to use &amp; not a bare &, when putting the URL in your 
stylesheet. Remember that the stylesheet is parsed just like any other XML
document, so when you mean '&', you need to write '&amp;'. i.e.,

  state=resource&amp;resource=250

   - Mike
____________________________________________________________________________
  mike j. brown                   |  xml/xslt: http://skew.org/xml/
  denver/boulder, colorado, usa   |  resume: http://skew.org/~mike/resume/

 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list


Current Thread

PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.