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

Concat question from a non-developer

Subject: Concat question from a non-developer
From: "Nicola Harlow" <Nicola.Harlow@xxxxxxxxxxxx>
Date: Thu, 7 Jul 2005 10:40:20 +0100
style.display block
Hi,

I'm trying to reproduce this line of HTML code in XSL, and I'm reaching
the limits of my inadequate knowledge.

[span onClick="document.all.menu1.style.display = 'block'"

onClickOut="document.all.menu1.style.display = 'block'"
style="text-decoration:underline; color:green"]

What I'm struggling to do is to work out how is how to do: 'block' and
get the commas surrounding the word block.

So far I have...

[span]

                    [xsl:attribute name="onClick"]

                        [xsl:value-of
select="concat('document.all.',@name,'.style.display','=','block')"/]

                    [/xsl:attribute]

                    [xsl:attribute name="onClickOut"]

                        [xsl:value-of
select="concat('document.all.',@name,'.style.display','=','block')"/]

                    [/xsl:attribute]

                    [xsl:attribute name="style"]

                        [xsl:value-of
select="'text-decoration:underline; color:green'"/]

                    [/xsl:attribute]

                          [/span]


This outputs:

[span onClick="document.all.menu1.style.display=block"
onClickOut="document.all.menu1.style.display=block"
style="text-decoration:underline; color:green"]


I can't just add commas around block because the syntax won't allow me.
If I add in the commas to the resulting HTML it works like a dream, but
that kinds of defeats the purpose of XML having to go back and change
the resulting code :)

Sorry if this is not enough of an explanation,

Nicola


(By they way I had to change < to [ because otherwise the email
bounces!)


Nicola Harlow
Technical Author
The Program Management Group plc
tel:           +44 (0) 1937 547 171
direct:      +44 (0) 1937 547 165
fax:         +44 (0) 1937 547 154
mail:     nicola.harlow@xxxxxxxxxxxx
web:        http://www.pm-group.com

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.