html forms xml and xml

P

Patrick

So I have been working on a little project and with the help of some
folks here I have the xml and xsl part working nicely.

Here is the link to the xml;
<http://ocgweb.marine.usf.edu/c10B.xml>
and the xsl;
<http://ocgweb.marine.usf.edu/testds.xsl>

As you can see I can change which Mooring Info is displayed by changing
the select on line 9 of the xsl sheet.

So I turned to working on my form where a user would select a specific
mooring and then submit and the action= would pass the post value of the
submit to the c10B.xml. Of course I found that this doesn't work and I
googled all over the place trying to find a way to pass this single
value to the xsl sheet so it knew which mooring to display. Then it
occurred to me that I am not telling it to pass the value to the xsl
sheet because I am telling it to go to the xml page. So I am a little
confused here as to how exactly this would work and was hoping that
someone might explain it to me and maybe point me in the right direction
as to how I can accomplish this task. Keeping in mind that anything
beyond basic right now will look like rocket science to me.

Thanks,
Patrick
--
Patrick A. Smith Assistant System Administrator
Ocean Circulation Group – USF - College of Marine Science
http://ocgweb.marine.usf.edu Phone: 727 553-3334

The trouble with doing something right the first time is that nobody
appreciates how difficult it was. - La Rochefoucauld
 
M

Martin Honnen

Patrick said:
So I turned to working on my form where a user would select a specific
mooring and then submit and the action= would pass the post value of the
submit to the c10B.xml.

A static XML document cannot process your form values when the browser
submits them, instead make the action point to a PHP page (I think you
said earlier you have and use PHP on your server) that processes the
form values the browser submits (using $_GET for method GET, $_POST for
method POST), then run the transformation server side with PHP's XSLT
processor API where you can pass in parameters before a stylesheet is
being executed.
See <http://www.php.net/manual/en/ref.xsl.php> for the PHP 5 API to its
XSLT processor.
 
P

Patrick

Martin said:
A static XML document cannot process your form values when the browser
submits them, instead make the action point to a PHP page (I think you
said earlier you have and use PHP on your server) that processes the
form values the browser submits (using $_GET for method GET, $_POST for
method POST), then run the transformation server side with PHP's XSLT
processor API where you can pass in parameters before a stylesheet is
being executed.
See <http://www.php.net/manual/en/ref.xsl.php> for the PHP 5 API to its
XSLT processor.
Thanks Martin. I will take a look at this and see what I can work out.

Patrick


--
Patrick A. Smith Assistant System Administrator
Ocean Circulation Group – USF - College of Marine Science
http://ocgweb.marine.usf.edu Phone: 727 553-3334

The trouble with doing something right the first time is that nobody
appreciates how difficult it was. - La Rochefoucauld
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,769
Messages
2,569,580
Members
45,054
Latest member
TrimKetoBoost

Latest Threads

Top