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

Re: Trying to write XSL for TiVo's XML

Subject: Re: Trying to write XSL for TiVo's XML
From: "Joe Fawcett" <joefawcett@xxxxxxxxxxx>
Date: Sun, 27 Feb 2005 15:28:38 -0000
tivo xml
----- Original Message ----- From: "Mihir" <mihir@xxxxxxxxx>
To: <xsl-list@xxxxxxxxxxxxxxxxxxxxxx>
Sent: Sunday, February 27, 2005 2:47 PM
Subject: Re: Trying to write XSL for TiVo's XML



Thank you Brian, the namespace was indeed what was causing the problem. I am
guessing it might be because TiVo has not uploaded it yet on their server.
Although the namespace was not added by me, I removed it using preg, and it
works.

Thank you for the help!

-- Mihir

-----Original Message-----
You have a namespace problem...
When I removed the namespace in the xml declaration of your .xml,
your script output what you probably wanted it to be (below).

I don't use namespaces much.. but I'm guessing you can declare
in your xslt stylesheet somewhere that such is the xml namespace
you are looking at... otherwise, the xpath processor doesn't see
any of your elements...


<h1>Now Playing</h1> <ul> <li><ul><li id="0x4220C026"> <strong>Moonstruck</strong><span class="desc"> [An Italian-American widow, engaged to a reticent suitor, falls in love with his brother.]</span> </li></ul></li> <li><ul><li id="0x4220AB0E"> <strong>Teen Titans</strong><span class="desc"> [Beast Boy must get a job in

order to purchase a Moped.]</span>
</li></ul></li>
<li><ul><li id="0x42211B8E"><strong>Teen Titans</strong></li></ul></li>
</ul>
</body>
</html>



It doesn't have "to be on their server", it's just a unique string. You need to add the namespaces and prefixes to your stylesheet to select nodes in the namespaces.

http://www.dpawson.co.uk/xsl/sect2/N5536.html

especially numbers 14 and 23.

Joe

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.