newbie question

Discussion in 'XML' started by d_cymbal@hotmail.com, Jun 9, 2005.

  1. Guest

    Hi,

    There is probably an easy answer to this but I am stumbling all over
    myself trying to find it.

    I am trying to create a quick and dirty xslt to pretty up some
    generated xml documents for display. Nothing fancy, I just want to
    create some basic HTML tables from the xml.

    Just about all the xml comes in two forms:

    (1)

    <root>
    <key1>value1</key1>
    <key2>value2</key2>
    <key3>value3</key3>
    </root>

    or (2) on slightly more complicated

    <root>
    <key1>value1</key1>
    <key2>value2</key2>
    <subelement>
    <key1>value1</key1>
    <key2>value2</key2>
    <key3>value3</key3>
    </subelement>
    <key3>value3</key3>
    </root>

    So what I want to be able to do is iterate over the entire doc and be
    able to extract each key name and value pairs for display. I also want
    to know if I am an a more complex element than a simple key/value so
    that I can generate a new table for that. I have bits and pieces of
    this working in separate xslts but things seem to fall apart when I
    attempt to combine everything into one xslt to rule them all :)

    Any samples I have missed via google that shows how to do this? It's
    really nothing more than a glorified echo it seems....

    Thanks.

    dc
     
    , Jun 9, 2005
    #1
    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. Jerry C.
    Replies:
    8
    Views:
    248
    Uri Guttman
    Nov 23, 2003
  2. Kruno Saho
    Replies:
    0
    Views:
    145
    Kruno Saho
    Apr 7, 2013
  3. Dave Angel
    Replies:
    0
    Views:
    126
    Dave Angel
    Apr 7, 2013
  4. rusi
    Replies:
    0
    Views:
    114
  5. Miki Tebeka
    Replies:
    0
    Views:
    85
    Miki Tebeka
    Apr 7, 2013
Loading...

Share This Page