Question:
I want to display an example of XML using HTML as the display?
step_hen_90
2007-04-21 15:53:35 UTC
Whenever I try to do it the XML tags don't come up.

Example:

John
Main St




Then the browser only displays:
John Main St
Five answers:
jake cigarâ„¢ is retired
2007-04-21 16:14:16 UTC
the way a browser displays an unstyled xml is up to the browser.



If you want to control the way it displays use a xsl stylesheet or even a css stylesheet (xhtml)



You can get the pretty default display by changing/upgrading your browser, I suggest firefox, http://getfirefox.com



YEAH, doesn't work!!! and changing < to & lt; makes it no longer xml!



UPDATE:

I had a xsl stylesheet laying around that makes any xml into viewable html.



Pick up a copy at http://jpassoc.com/xml-color.xsl



and add 1 line to the your xml, before the line.



Rex M
2007-04-21 16:13:55 UTC
The browser is a sophisticated XML parser, so it recognizes your XML tags and includes them in the tree as markup, not text to display. But obviously, since there is no behavior definition for person, name or address, it does not do anything different with them. The fastest solution is probably to use & lt; person & gt; (sans the spaces) which will be displayed as



does not seem to respect XML markup as I'd thought.
lindeen
2016-12-04 15:34:35 UTC
Obama is a shame to the Harvard evaluation Committee. Obama's Harvard regulation employer record and says he had "0 skills" to change into president of the regulation evaluate "depending upon his achievements and academic credentials." it truly is the second one time i have heard that Obama replaced into the universal affirmative action president of the regulation evaluation. in basic terms formerly he replaced into elected, the abilities for being president were switched over from smarts and academic excellence to 'helping proper the wrongs of a facist society.'
anonymous
2007-04-25 14:13:21 UTC
this is a cool stylesheet!











































<>



>











=""



anonymous
2007-04-21 21:41:16 UTC
You need a stylesheet!


This content was originally posted on Y! Answers, a Q&A website that shut down in 2021.
Loading...