Click to See Complete Forum and Search --> : New Line Character in the Attribute Value??


deepak7819
01-08-2008, 05:03 AM
Hello;

I've created a XML document that contains attribute string.

I want the following Details value

<DHCPDevice_ServerResponseResults Iteration="1" Details="WINS Server Disabled&#xD;&#xA;NB Node Type Disabled&#xD;&#xA;NB Scope Disabled&#xD;&#xA;SMTP Server Disabled&#xD;&#xA;POP3 Server Disabled&#xD;&#xA;Web Server Disabled" ResponseTime="0.000" Status="Failed" />

to be displayed as

WINS Server Disabled
NB Node Type Disabled
NB Scope Disabled
SMTP Server Disabled
POP3 Server Disabled
Web Server Disabled

But it show appear on the same line. I have tried various option character code but invein.

Thanks.
Deepak Singh

jkmyoung
01-08-2008, 11:02 AM
What tool are you using to output the value? Can we see the code used to do so?

deepak7819
01-09-2008, 12:32 AM
What tool are you using to output the value? Can we see the code used to do so?

I am using Firefox to view the XML file. Please find attached code along with this message. I have set the properties in the stylesheet, but it still appears on the same line
<xsl:value-of select="@Details" disable-output-escaping="yes"/>

jkmyoung
01-09-2008, 10:38 AM
Still not enough code...
If you're treating your output as html, you''ll have to use <br/> tags instead, since internet browsers automatically strip out whitespace.