[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

RE: Trying to put a <BR> in a string parameter

Subject: RE: Trying to put a <BR> in a string parameter
From: Kerin Cosford <Kerin.Cosford@xxxxxxxxxxxxxxxxx>
Date: Fri, 13 Jul 2001 13:51:20 +0100
kerin cosford
It's possible that <xsl:value-of select="."/><br/> is working fine - have
you viewed source in your browser, and had a look if the br tag is there?

Most browsers choke on <br/>. The other option when generating them through
XSL is to use <br class="none"/>.

-----Original Message-----
From: Daniel Newman [mailto:daniel.newman@xxxxxxxxxxx]
Sent: 13 July 2001 12:50
To: xsl-list@xxxxxxxxxxxxxxxxxxxxxx
Subject:  Trying to put a <BR> in a string parameter


Hello all,

I can't figure out what's going on here, so hopefully someone can help.

I have a template I'm calling, and I'm passing it a string (someone's
address). The address is made up of multiple Nodes. I'm looping through
these nodes and adding there text content to my parameter.

<xsl:with-param name="Value">
	<xsl:for-each
select="RetrieveNameAndAddressRSResponse/*[starts-with(local-name(),
'NameAddress') and 	preceding-sibling::*[generate-id() =
generate-id($comma-element)]]">
		<xsl:value-of select="." />
	</xsl:for-each>
</xsl:with-param>

The loop is fine, and does pass the whole address to the parameter, but I
want to introduce a <BR> tag after each line. I've tried everything I can
think of, but the tag does not want to appear.

This seems like the simplest way of doing it, but it doesn't work:
<xsl:value-of select="." /><br/>

And I've tried
<xsl:value-of select="<br/>" />
<xsl:value-of select="'<br/>'" />
<xsl:value-of select="'&lt;br/&gt;'" />
<xsl:value-of select="&lt;br/&gt;" />

But none of them worked - except for <xsl:value-of select="'&lt;br/&gt;'" />
which wrote all those &lt; to the page, so my page was displaying "street
name<br>town name<br>county name", not quite I wanted. But if I converted
them to proper tags, it didn't work. Just ignored it completely.

I'm most confused. Hope someone can help.

Thanks,
Daniel Newman.

Bis-Web Ltd.
Tel: 01993 880614
Fax: 01993 881625

****************************************************************************
The information transmitted is intended only for the person or entity to
which it is addressed and may contain confidential and/or privileged
material. Any review, retransmission, dissemination or other use of, or
taking of any action in reliance upon, this information by persons or
entities other than the intended recipient is prohibited. If you received
this in error, please contact the sender and delete the
material from any computer.
****************************************************************************


 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list

 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list


Current Thread

PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.