xsl-list
[Top] [All Lists]

Re: Document function with Sablotron and timestamp conversion

2005-02-28 11:29:23
Mihir writes:
So instead I opted to use the document function
I used... <xsl:value-of select="document(concat('timeconvert.php?hex=',
tivo:Details/tivo:CaptureDate)/time)" /> but Sablotron doesn't like it and
says it can't open the file even though timeconvert.php is in the same
folder as the XSL and xml files. The timeconvert.php returns <time>[Human
readable time]</time>


Warning: Sablotron error on line 1: cannot open file
'/home/riffola/public_html/tivo/timeconvert.php?hex=0x422226BE' in
/home/riffola/public_html/tivo/index.php on line 4

Where index.php is just a short script that asks PHP to parse nowplaying.xml
with nowplaying.xsl using Sablotron.

Exactly: it's a CGI script, not merely a file name, and it takes a
parameter.  And the document function takes a URI.  So you need
something like

<xsl:value-of select="document(concat('http://localhost/timeconvert.php?hex=',
                                      tivo:Details/tivo:CaptureDate)/time)" />

-- 
Kevin Rodgers


--~------------------------------------------------------------------
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>
--~--



<Prev in Thread] Current Thread [Next in Thread>