java DOM: hide prefix from app

Discussion in 'Java' started by Thomas Jollans, Feb 4, 2004.

  1. i have an xml file

    <p:tag_one xmlns='ns'>
    <p:tag_two>
    text
    </p:tag_two>
    <p:tag_three/>
    </p:tag_one>

    and want p:tag_two to be tag_two for the app, p:tag_one to be tag_one...
    how do i do this with java xml dom?

    thanx in advance,
    thomas
    Thomas Jollans, Feb 4, 2004
    #1
    1. Advertising

  2. Thomas Jollans

    Anton Spaans Guest

    "Thomas Jollans" <> wrote in message
    news:bvr6bc$nli$06$-online.com...
    > i have an xml file
    >
    > <p:tag_one xmlns='ns'>
    > <p:tag_two>
    > text
    > </p:tag_two>
    > <p:tag_three/>
    > </p:tag_one>
    >
    > and want p:tag_two to be tag_two for the app, p:tag_one to be tag_one...
    > how do i do this with java xml dom?
    >
    > thanx in advance,
    > thomas


    Walk the entire tree-structure of the original XML document (with the p
    prefix). While doing that, copy each node and make a copy of the original
    XML. But use the getLocalName method/attribute instead of the getNodeName
    (the actual method names may be spelled a little differently, though).

    Or use an XSL transformation do to the same.

    -- Anton.
    Anton Spaans, Feb 4, 2004
    #2
    1. Advertising

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

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Mark McKay
    Replies:
    0
    Views:
    442
    Mark McKay
    Dec 1, 2004
  2. Tim Tyler
    Replies:
    36
    Views:
    1,448
    Darryl L. Pierce
    Dec 10, 2004
  3. Susan A. Smith
    Replies:
    8
    Views:
    26,091
  4. Thomas Jollans

    java DOM: hide prefix from app

    Thomas Jollans, Feb 4, 2004, in forum: XML
    Replies:
    1
    Views:
    384
    Anton Spaans
    Feb 4, 2004
  5. Chris  Chiasson
    Replies:
    6
    Views:
    607
    Richard Tobin
    Nov 14, 2006
Loading...

Share This Page