XML Programming
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me
Go Back   Dev Shed ForumsProgramming Languages - MoreXML Programming

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Dev Shed Forums Sponsor:
  #1  
Old March 1st, 2004, 12:51 PM
cezar2000 cezar2000 is offline
Registered User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Mar 2004
Posts: 2 cezar2000 User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
Question need help with xsl

The xml format is:

Code:
<collateral-list>
- <collateral>
- <collateral>
- <collateral>
</collateral-list>


This is my xsl:
Code:
<xsl:for-each select="collateral-list">
       <tr >
             <td colspan="2"><strong><font face="verdana" size="-1">Collateral Type</font></strong></td>
       </tr>
       <tr>
             <td colspan="2"><font face="verdana" size="-1"><xsl:value-of select="."/></font></td>
       </tr>
	</xsl:for-each>


The problem is:
It's displaying all the collateral in one line, and without any space. How do you insert a newline in between the values ?
I have tried the
Code:
<xsl:variable>
<xsl:text>
</xsl:text>
</xsl:variable>


and using the
Code:
<xsl:text>ascii of newline</xsl:text>

but none of them is working

Any help will be greatly appreciated
Cezar2000

Reply With Quote
  #2  
Old March 1st, 2004, 02:20 PM
khwang's Avatar
khwang khwang is offline
Über nübe
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Sep 2003
Location: Babylon 4
Posts: 240 khwang User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 29 m 27 sec
Reputation Power: 6
Could you get away with doing this?


Code:

<xsl:for-each select="collateral">
       <tr >
             <td colspan="2"><strong><font face="verdana" size="-1">Collateral Type</font></strong></td>
       </tr>
       <tr>
             <td colspan="2"><font face="verdana" size="-1"><xsl:value-of select="."/></font></td>
       </tr>
	</xsl:for-each>
__________________
Hello, old friend...

Reply With Quote
  #3  
Old March 1st, 2004, 03:01 PM
cezar2000 cezar2000 is offline
Registered User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Mar 2004
Posts: 2 cezar2000 User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
Thumbs up

It's working. Thx a lot :>
Sorry for such a newbie question

Reply With Quote
  #4  
Old March 1st, 2004, 05:36 PM
khwang's Avatar
khwang khwang is offline
Über nübe
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Sep 2003
Location: Babylon 4
Posts: 240 khwang User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 29 m 27 sec
Reputation Power: 6
My solution is not elegant, it's quick-and-dirty.

Reply With Quote
Reply

Viewing: Dev Shed ForumsProgramming Languages - MoreXML Programming > need help with xsl


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump


Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 2 hosted by Hostway
Stay green...Green IT