[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
RE: XML/XML Transformation - Please Help !!!.....
- From: Thushara Perera <thusharap@eurocenter.lk>
- To: Wei-Chin Hsieh <whsieh@cae.wisc.edu>,"XML-DEV (E-mail)" <xml-dev@lists.xml.org>
- Date: Mon, 30 Apr 2001 14:54:29 +0600
Hi
Thanks for the info. BUT you have mis-understood my problem. I don't need to
just get the href.
Please see below:
Part of my XML file is:
..
..
..
<URLADR>http:\\www.aaa.com</URLADR>
<URLDESC>Homepage of aaa AS</URLDESC>
<URLDESCLANGUAGE>en</URLDESCLANGUAGE>
<URLDESC>Homepage of aaa AS NO</URLDESC>
<URLDESCLANGUAGE>no</URLDESCLANGUAGE>
<URLDESC>Homepage of aaa AS SE</URLDESC>
<URLDESCLANGUAGE>se</URLDESCLANGUAGE>
<URLADR>http:\\www.aaabbb.org</URLADR>
<URLDESC>Demo of aaabbb.com</URLDESC>
<URLDESCLANGUAGE>en</URLDESCLANGUAGE>
<URLDESC>Demo of aaabbb.com NO</URLDESC>
<URLDESCLANGUAGE>no</URLDESCLANGUAGE>
..
..
..
and I want to convert this to something like:
..
..
<URLLIST>
<URL>
<URLADR>http://www.aaa.com</URLADR>
<URLDESC xml:lang="en">Homepage of aaa AS></URLDESC>
<URLDESC xml:lang="no">Homepage of aaa AS NO></URLDESC>
<URLDESC xml:lang="se">Homepage of aaa AS SE></URLDESC>
</URL>
<URL>
<URLADR>http://www.aaabbb.org</URLADR>
<URLDESC xml:lang="en">Demo of aaabbb.com></URLDESC>
<URLDESC xml:lang="no">Demo of aaabbb.com NO></URLDESC>
</URL>
</URLLIST>
..
..
-----Original Message-----
From: Wei-Chin Hsieh [mailto:whsieh@cae.wisc.edu]
Sent: Monday, April 30, 2001 3:01 PM
To: Thushara Perera; XML-DEV (E-mail)
Subject: Re: XML/XML Transformation - Please Help !!!.....
Try this
<a><xsl:attribute name="href">
<xsl:value-of select="URLADR"/></xsl:attribute>
<xsl:value-of select="URLADR"/></a>
Wei-Chin Hsieh
----- Original Message -----
From: Thushara Perera
To: XML-DEV (E-mail)
Sent: Monday, April 30, 2001 2:58 AM
Subject: XML/XML Transformation - Please Help !!!.....
Hi
Could someone PLEASE tell me how to do the XML to XML transformation as
described below ?
Part of my XML file is:
..
..
..
<URLADR>http:\\www.aaa.com</URLADR>
<URLDESC>Homepage of aaa AS</URLDESC>
<URLDESCLANGUAGE>en</URLDESCLANGUAGE>
<URLDESC>Homepage of aaa AS NO</URLDESC>
<URLDESCLANGUAGE>no</URLDESCLANGUAGE>
<URLDESC>Homepage of aaa AS SE</URLDESC>
<URLDESCLANGUAGE>se</URLDESCLANGUAGE>
<URLADR>http:\\www.aaabbb.org</URLADR>
<URLDESC>Demo of aaabbb.com</URLDESC>
<URLDESCLANGUAGE>en</URLDESCLANGUAGE>
<URLDESC>Demo of aaabbb.com NO</URLDESC>
<URLDESCLANGUAGE>no</URLDESCLANGUAGE>
..
..
..
and I want to convert this to something like:
..
..
<URLLIST>
<URL>
<URLADR>http://www.aaa.com</URLADR>
<URLDESC xml:lang="en">Homepage of aaa AS></URLDESC>
<URLDESC xml:lang="no">Homepage of aaa AS NO></URLDESC>
<URLDESC xml:lang="se">Homepage of aaa AS SE></URLDESC>
</URL>
<URL>
<URLADR>http://www.aaabbb.org</URLADR>
<URLDESC xml:lang="en">Demo of aaabbb.com></URLDESC>
<URLDESC xml:lang="no">Demo of aaabbb.com NO></URLDESC>
</URL>
</URLLIST>
..
..
Please tell me how to write the XSL file for this.
Thanks a lot
Thushara