|
|
|||||||||
|
|||||||||
| |||||||||
|
|
|
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
|
|
SlickEdit: Code in over 40 languages across 7 platforms. SlickEdit’s unmatched power, speed, and flexibility allows even the most accomplished developers to write better code faster. Download a free trial today! |
|
#1
|
|||
|
|||
|
Hi,
How do I pass user-input (like using <INPUT>) to an XSL variable? Something like this; <input name="blah" type="text"> and the input string will be in $blah, so I can continue processing it in XSL. I only want to use XML/XSL, DOM, (D)(X)HTML and/or JavaScript. No ASP/PHP stuff, it has to be client-side. But how??? ![]() |
|
#2
|
|||
|
|||
|
How are you using xsl client side?
|
|
#3
|
|||
|
|||
|
I have an XML 'database' with an XSL file linked.
In the XSL file, I build up the HTML-code to display the XML data. The user-input will be used to filter the data (using keywords), so that only the data that is needed, will be displayed. Does this answer your question? Unfortunately the server went down, otherwise I could have given the website... ![]() |
|
#4
|
|||
|
|||
|
I've just never seen xsl used without a server-side language to do the transformation. Is it an IE-only technology?
|
|
#5
|
|||
|
|||
|
Euhm... IE-only? Don't think so...
Check: http://www.w3schools.com/xsl/xsl_languages.asp The bad thing is, I pass XSL variables to HTML but not the other way around; <img src="{$image_url}"> will work. |
|
#6
|
|||
|
|||
|
Hmm, ya. I don't know how you would pass variables that way. Here's the xsl tag that lets you "receive" the value and specify a default: http://www.w3schools.com/xsl/el_param.asp
Like I said, I'm not sure how you would go about overriding the defaults, though. |
|
#7
|
|||
|
|||
|
This might help. I think you'd have to use it with the javascript example at w3schools, though: http://msdn.microsoft.com/library/d...ddparameter.asp
|
|
#8
|
|||
|
|||
|
Hey, looks good!
Will have to check it out a bit further, but it seems to be what I am looking for. You have too much time on your hand? ![]() |
|
#9
|
|||
|
|||
|
I'm often bored, ya
![]() Here's an ie/mozilla transform script. http://webfx.eae.net/dhtml/xmlextras/xmlextras.html |
|
#10
|
|||
|
|||
|
I think I got it now: with VBScript (or JavaScript) & DOM you can parse the XML and compare the content of a XML-node to the value of a variable in the script.
Will try so in the next few days and let you know the result ![]() I might even post the script... :P |
|
#11
|
|||
|
|||
|
AxiMaxi,
if you already found the way to solve this prob, please post it. i also facing the same prob as you. thanks. hi, everyone. nice to meet you. |
|
#12
|
|||
|
|||
|
Just What I Need (I think)
Sorry to drag up this old topic, I found it via a google search.
Can anyone help out a newbie on the very same problem? I have a user input form from which I want to pass multiple variables to an XSL sheet, then build up a table of records that match all th input criteria. |
![]() |
| Viewing: Dev Shed Forums > Programming Languages - More > XML Programming > How to pass user-input to XSL variable? |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|