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

Re: Client-side XSLT processing by browsers

Subject: Re: Client-side XSLT processing by browsers
From: "Ragulf Pickaxe" <ragulf.pickaxe@xxxxxxxxx>
Date: Sun, 27 Aug 2006 16:19:33 +0200
client side xslt parameters
Hi JJ,

Passing parameters in the querystring is an HTML construct, not an XSL
one. Also, there are 4 different types in XSL (string, boolean, number
and nodeset), how would you differentiate between these in a
querystring-based manner? Remember that the type must be declared
before passing to the XSL stylesheet.

I think, to achieve somewhat what you want, you will have to make an
html page that accepts querystring parameters and then uses javaScript
to pass these into the desired XSL document and doing the
transformation, using itself as the input document, if you desire
this.

I know that this is not what you had hoped for, but I hope my answer
is of some small help anyway.

Regards,
Ragulf Pickaxe :-)


On 8/27/06, JJ Merelo <jjmerelo@xxxxxxxxx> wrote:
Hi,
I have been looking for info on using the XSLT processors in browsers,
namely Firefox and Opera. They seem to work well (although, if you use them
on the client side, Firefox requires the extension .xhtml to apply xslt
properly), but the problem I have found is that the only way to pass
parameters to the XSLT stylesheet is using it via Javascript.
What I want to do is something like this: process a file locally using
filename.xhtml?param1=value1;param2=value2 and so on
with filename.xhtml having:
<?xml-stylesheet href="stylesheet.xsl" type="text/xsl"?>
and, in stylesheet.xsl
<xsl:param name='param1'>
on the XSLT stylesheet. I have tested in in Firefox and Opera, and it does
not seem to pick up the parameters. Is there any other way of passing params
to that stylesheet? Or at least, a way that works?
What I want to do is to present different content depeding on the way it's
called. For instance, calling filename.xhtml?mode=index would just return
the <h2> tags and so on.

Thanks for any answer!
JJ

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.