Search...
FAQs
Subscribe
Pie
FAQs
Recent topics
Flagged topics
Hot topics
Best topics
Search...
Search within XML
Search Coderanch
Advance search
Google search
Register / Login
Post Reply
Bookmark Topic
Watch Topic
New Topic
programming forums
Java
Mobile
Certification
Databases
Caching
Books
Engineering
Micro Controllers
OS
Languages
Paradigms
IDEs
Build Tools
Frameworks
Application Servers
Open Source
This Site
Careers
Other
Pie Elite
all forums
this forum made possible by our volunteer staff, including ...
Marshals:
Campbell Ritchie
Jeanne Boyarsky
Ron McLeod
Paul Clapham
Liutauras Vilda
Sheriffs:
paul wheaton
Rob Spoor
Devaka Cooray
Saloon Keepers:
Stephan van Hulst
Tim Holloway
Carey Brown
Frits Walraven
Tim Moores
Bartenders:
Mikalai Zaikin
Forum:
XML and Related Technologies
How to integrate xsl:value-of inside the ID property of TD
Mahendran Aiyappan
Ranch Hand
Posts: 102
posted 17 years ago
Number of slices to send:
Optional 'thank-you' note:
Send
Hi guys,
I dont know why the following code is not working.
<xsl:when test="@status='No School Day'"> <td class="no_school_day" id="<xsl:value-of select=@number>" onKlick="show_popup('Non_School_Day'); return false"> <xsl:value-of select="@number"/> </td> </xsl:when>
If you notice inside the ID property of the TD I used a xsl:value-of.
Whether this is possible or what is the alternate way to do this.
Purushoth Thambu
Ranch Hand
Posts: 425
posted 17 years ago
Number of slices to send:
Optional 'thank-you' note:
Send
Since you have enclosed the value-of element in double quote it's not being parsed/processed by the xslt engine. Try using xsl:element and xsl:attribute element to create. You can first try using just xsl:attribute
<xsl:attribute name="id"> <xsl:value-of...> </xsl:attribute>
within the "td" element.
Mahendran Aiyappan
Ranch Hand
Posts: 102
posted 17 years ago
Number of slices to send:
Optional 'thank-you' note:
Send
Hi Purushothaman ,
Thanks for your reply,
But I don't know how to use this inside TD
Can you give me any example code or links for this.
Mahendran Aiyappan
Ranch Hand
Posts: 102
posted 17 years ago
Number of slices to send:
Optional 'thank-you' note:
Send
Hi Purushothaman,
I did like this
<xsl:when test="@status='Meal Choice Available'"> <xsl:attribute name="id"><xsl:value-of select="@number"/></xsl:attribute> <td class="meal_choice_available" onMouseKOVER="bcolor('#00FF00','');" onMouseKOut="bcolor('#FFFFFF','');" onKlick="show_popup('Meals_Choice_Available'); return false">\ <xsl:value-of select="@number"/> </td> </xsl:when>
If you notice in the onKlick() event the second parameter is empty.
But I want to pass that xsl:valus-of in it.
How this is possible.
Please help me.
This is very urgent.
Purushoth Thambu
Ranch Hand
Posts: 425
posted 17 years ago
Number of slices to send:
Optional 'thank-you' note:
Send
Try like this.
<xsl:when test="@status='Meal Choice Available'"> <td class="meal_choice_available" onMouseKOVER="bcolor('#00FF00','');" onMouseKOut="bcolor('#FFFFFF','');" onKlick="show_popup('Meals_Choice_Available'); return false"> <xsl:attribute name="id"><xsl:value-of select="@number"/></xsl:attribute> <xsl:value-of select="@number"/> </td> </xsl:when>
I am not clear what you meant by second parameter is empty. Can you explain in detail what you want to do?
reply
reply
Bookmark Topic
Watch Topic
New Topic
Boost this thread!
Similar Threads
xsl - need to select on attribute and limit output
How to create an array of ID names for TD?
Getting my HTML output to backspace one character
Newbie Question---Help?
NBSP in Html output
More...