Win a copy of TensorFlow 2.0 in Action this week in the Artificial Intelligence and Machine Learning forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Liutauras Vilda
  • Paul Clapham
  • Bear Bibeault
  • Jeanne Boyarsky
Sheriffs:
  • Ron McLeod
  • Tim Cooke
  • Devaka Cooray
Saloon Keepers:
  • Tim Moores
  • Tim Holloway
  • Jj Roberts
  • Stephan van Hulst
  • Carey Brown
Bartenders:
  • salvin francis
  • Scott Selikoff
  • fred rosenberger

xsl dynamic extraction of xml data help

 
Greenhorn
Posts: 7
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi,

I'm new to this forum and to xsl and xml.

I've a got a fairly large xml doc which I want to be able to manipulate using xsl.

However I want the user to decide how to manipulate using html forms i.e. what search to do via date, name, key word.

However I'm unsure how to get the information from the form and place it into the xsl doc. Can anyone help?

here is some of my code

<?xml version="1.0" encoding="UTF-8"?>
<?xml-stylesheet type="text/xsl" href="xsl.xsl"?>
<Conferences>
<Conference>
<Name>2006 World Congress on Medical Physics and Biomedical Engineering (W2006)</Name>
<Dates>27 Aug - 01 Sep 2006</Dates>
<Location>COEX Convention & Exhibition Center Seoul, Korea</Location>
<OrgUrl>http://www.wc2006-seoul.org/</OrgUrl>;
<Extra-Info>WC 2006 Secretariat SL Gangnam PO Box 305 Seoul 135-603 KOREA +82 2 3476 7700 +82 2 3476 8800 (Fax) wc2006@koconex.com</Extra-Info>
<SouceUrl>http://webapps1.ieee.org/conferenceSearch/details.do;jsessionid=...?tagNo=10454</SouceUrl>;
</Conference>
.....

.....
</Conferences>


the xsl doc....

<?xml version="1.0" encoding="UTF-8" ?>
- <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
- <xsl:template match="/">
- <html>
- <body>
<h2>Ur Search results</h2>
- <table border="1">
- <tr bgcolor="#9acd32">
<th>Name</th>
<th>Dates</th>
<th>Location</th>
<th>Orginial URL</th>
<th>Extra Information</th>
<th>Source URL</th>
</tr>
- <xsl:for-each select="Conferences/Conference">
- <tr>
- <td>
<xsl:value-of select="Name" />
</td>
- <td>
<xsl:value-of select="Dates" />
</td>
- <td>
<xsl:value-of select="Location" />
</td>
- <td>
<xsl:value-of select="OrgUrl" />
</td>
- <td>
<xsl:value-of select="Extra-Info" />
</td>
- <td>
<xsl:value-of select="SouceUrl" />
</td>
</tr>
</xsl:for-each>
</table>
</body>
</html>
</xsl:template>
</xsl:stylesheet>

for exampe <xsl:for-each select="Conferences/Conference[name="information posted from the form]">....
but how to get the information from the form??

thanks in advance!.

Jam

(I edited your post a little so that it doesn't make the page too wide - Paul Clapham)
[ July 20, 2006: Message edited by: Paul Clapham ]
 
Marshal
Posts: 25965
70
Eclipse IDE Firefox Browser MySQL Database
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
"Jam Jam", welcome to JavaRanch.

We're glad to have you here, but we do require members to have valid display names.

Display names must be at least two words: your first name, a space, then your last name. Fictitious names are not allowed.

Please edit your profile and correct your display name since accounts with display names get deleted.
 
Jamil Zakaria
Greenhorn
Posts: 7
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
done so. Anyone able to help with my problem??
 
Paul Clapham
Marshal
Posts: 25965
70
Eclipse IDE Firefox Browser MySQL Database
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thank you, Jamil.

So what is your actual question? Do you have a problem designing a form to ask the user for the required information? Or do you already have a form, and you want to know how to use servlet code to produce an XSLT document? Or something else?
 
Jamil Zakaria
Greenhorn
Posts: 7
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi, sorry for not making it clear.

I presume that the form is created using htm in the normal way in which case I know how to create the form. If there is a specific way please could you advise me otherwise.

I really need to know how to create the XSLT doc using search info from the form.

thanks

Jamil
 
Brace yourself while corporate america tries to sell us its things. Some day they will chill and use tiny ads.
Building a Better World in your Backyard by Paul Wheaton and Shawn Klassen-Koop
https://coderanch.com/wiki/718759/books/Building-World-Backyard-Paul-Wheaton
reply
    Bookmark Topic Watch Topic
  • New Topic