W3C home > Mailing lists > Public > www-xsl-fo@w3.org > June 2006

Re: Question about XML parsing

From: Mukul Gandhi <gandhi.mukul@gmail.com>
Date: Sat, 3 Jun 2006 11:58:03 +0530
Message-ID: <7870f82e0606022328i112e8f73j62fac4c6ddea2b22@mail.gmail.com>
To: "Guo Chen" <jardonc@nortel.com>
Cc: www-xsl-fo@w3.org

Hi Guo,
   I think your question is not related to XSL-FO. I suspect its
either related to general XML, or XSLT.

It seems your problem can be easily solved using XML DOM, or using XSLT.

For XML questions, please ask the question at xml-dev
(http://www.xml.org/xml/xmldev.shtml).

For XSLT questions, please ask at xsl-list
(http://www.mulberrytech.com/xsl/xsl-list/index.html).

Regards,
Mukul

On 5/31/06, Guo Chen <jardonc@nortel.com> wrote:
>
>
>
> Hi,
>
> I'm parsing an XML file, there is an element named <msn_message> inside this
> file, it looks like:
>
> <msn_message>
> <msn_message_type>
> ..
> ...
> ...
> </msn_message_type>
> <prod_rel name="ABC" start_rel="aa" end_rel="bb"/>
> <prod_rel name="XYZ" start_rel="cc" end_rel="dd"/>
> <other elements.../>
> </msn_message>
> This is my requirements:
>
> 1). if ABC = XYZ and either bb or dd greater than 6.0, then
> <msn_message>
> <msn_message_type>
> ..
> ...
> ...
> </msn_message_type>
> <prod_rel name="ABC"/>
> <other elements.../>
> </msn_message>
>
> 2). if ABC != XYZ and both bb and dd are less than 6.0, then
> the entire element <msn_message> should be removed.
> My difficulty is:
> 1). How to compare bb and dd, they are in different element(in the same
> level).
> 2). How to delete the entire element in this case.
>
> Thanks
>
> Guo
Received on Saturday, 3 June 2006 06:28:13 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Wednesday, 3 October 2007 16:06:13 GMT