cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Sam" <>
Subject Displaying XML document as it is ??
Date Tue, 11 May 2004 18:48:38 GMT
Hello ppl,<BR>
I would like to know the best practice to display a simple XML document as it is on the browser.
say I have an XML document called vector.xml which looks like:<BR>
&lt;?xml version=&quot;1.0&quot; standalone=&quot;no&quot;?&gt;<BR>
&lt;!DOCTYPE class SYSTEM &quot;collection.dtd&quot;&gt;<BR>
&nbsp; &nbsp; &lt;info&gt;&nbsp; &nbsp; &nbsp;&nbsp; &nbsp;
&nbsp;&nbsp; &nbsp; &nbsp;<BR>
&nbsp; &nbsp; &nbsp;&nbsp; &nbsp; &nbsp;public class Vector<BR>
&nbsp; &nbsp; &nbsp;&nbsp; &nbsp; &nbsp; &nbsp; extends AbstractList<BR>
&nbsp; &nbsp; &nbsp;&nbsp; &nbsp; &nbsp;implements List, RandomAccess,
Cloneable, Serializable<BR>
&nbsp; &nbsp; &nbsp;&nbsp; &nbsp; &nbsp;<BR>
&nbsp; &nbsp; &nbsp;&nbsp; &nbsp; &nbsp;The Vector class implements
a growable array of <BR>
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; objects.
Like an array, it contains components that can<BR>
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; be
accessed using an integer index. However, the size <BR>
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; of
a Vector can grow or shrink as needed to accommodate<BR>
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; adding
and removing items after the Vector has been <BR>
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; created.<BR>
&nbsp; &nbsp; &lt;/info&gt;<BR>
What would be the best practice to display the contents of &lt;info&gt; element on
the browser as it is without disturbing the allignments, linebreaks etc etc ...<BR>
In other words just display it as it looks inside the &lt;info&gt; element.<BR>
Any body ....<BR>
<A target="_blank" HREF=""><IMG

View raw message