Display XML tags in HTML display

Discussion in 'HTML & Website Design' started by evelyn.gallagher, Apr 11, 2007.

  1. #1
    Hi,

    I'm new to HTML. I want to display a file that contains XML using HTML ti display it. This is what I am trying to do:

    <html>
    <body>
    <h1>Elements</h1>
    XML elements can contain other elements.
    <p>
    For example:
    <PARENT>
    <CHILD>Son</CHILD>
    </PARENT>
    <p>
    In the above example the tags for the child element are completely contained within the parent element. It is important to indent (nest) elements properly so that the application that reads the XML document will know which elements are the contents of another element. Parent elements can have different kinds of children and those children can become parents having children of their own.

    </body>
    </html>


    There are problems with displaying the XML - it comes out all funny. Any help with this would be great.
     
    evelyn.gallagher, Apr 11, 2007 IP