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. Advertisements

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. Jenny

    dotnet newbie question

    Jenny, Jul 13, 2003, in forum: ASP .Net
    Replies:
    9
    Views:
    1,388
    K_Lee
    Nov 6, 2003
  2. Alan S.

    Re: A newbie .NET question

    Alan S., Sep 4, 2003, in forum: ASP .Net
    Replies:
    2
    Views:
    983
    Jerry Dennany
    Sep 26, 2003
  3. Id0x
    Replies:
    4
    Views:
    1,445
    Erik Max Francis
    Jul 21, 2003
  4. cjl
    Replies:
    3
    Views:
    1,155
    John Nagle
    May 21, 2007
  5. JohnE

    newbie with newbie questions

    JohnE, Aug 17, 2009, in forum: ASP .Net
    Replies:
    3
    Views:
    768
    Gregory A. Beamer
    Aug 17, 2009
  6. Jerry C.
    Replies:
    8
    Views:
    577
    Uri Guttman
    Nov 23, 2003
  7. moonhkt
    Replies:
    2
    Views:
    352
    Chris Angelico
    Sep 16, 2012
  8. Dennis Lee Bieber

    Re: Newbie to python. Very newbie question

    Dennis Lee Bieber, Apr 7, 2013, in forum: Python
    Replies:
    1
    Views:
    156
    Miki Tebeka
    Apr 8, 2013
Loading...