Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Can I put formatting info into XML file or just in CSS XSL ect ? 2

Status
Not open for further replies.

cdXML

Programmer
Feb 1, 2001
3
IE
A quick question for anyone who can help.
Is it possible to put formatting information directly into the XML file ?
For example, I am storing a paragraph of text in an XML file. The paragraph has an underlined word, must I have a seperate element for this word and have the XSL format it as underlined or is there some way I can specify this word as being underlined from within the element that contains the paragraph of text ?

Hope that makes sense

Conor
 
Conor,

XML does not have any display characteristics, like 'underline'. You generate HTML, for example, to create the display styles desired.

It is possible to have XML data contain HTML code by using a CDATA type. I don't know if that solves your problem though.

Hope this helps
-pete
 
I've been told that this is well formed XML:

(code snippet only, not complete file)
<datablock>
This is a test of the <bold>emergency broadcast</bold> system.
</datablock>

However, your XSL is going to have to interpret your &quot;bold&quot; blocks properly.

Rosalie Dieteman
 
Thanks for all your help guys,
I think I'm on top of the problem now,

Conor
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top