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

RE: Contents of a <div> into an AVT?

Subject: RE: Contents of a <div> into an AVT?
From: cknell@xxxxxxxxxx
Date: Wed, 06 Aug 2003 13:48:05 -0400
RE:  Contents of a <div> into an AVT?
If I understand your question, I don't think that your answer lies in XSLT, but rather in JavaScript and the HTML DOM. Of which element is the "onclick" event handler you showed in your message a part?

If your HTML has this element:
<div id="Step_2.1" onclick="Javascript:newWin('here is where i need the above', '{para}')">2.1  </div>

Then try this:
<div id="Step_2.1 " onclick="Javascript:newWin('here is where i need the above', event.srcElement.getAttribute('id'))">2.1 </div>

Of course, if I don't understand your question, that answer will be wrong.

-- 
Charles Knell
cknell@xxxxxxxxxx - email



-----Original Message-----
From:     "Kathy Burke" <Kathy_Burke@xxxxxxxxx>
Sent:     Wed, 6 Aug 2003 12:06:38 -0400
To:       xsl-list@xxxxxxxxxxxxxxxxxxxxxx
Subject:   Contents of a <div> into an AVT?

Hello. I'm sure I'll phrase this incorrectly..but here goes.

building html table, my xsl contains:

<xsl:variable name="id">
      <xsl:number level="multiple" count="step" format="1.1">
</xsl:variable>

<div id="Step_{$id}">
<xsl:value-of select="$id"/>
</div>

This results as desired:

<div id="Step_2.1 ">2.1  </div>


My question is: how to get either the div id ("Step_2.1") or div contents
("2.1") into a script parameter?

In my html, I have onclick="Javascript:newWin('here is where i need the
above', '{para}')"

The {para} give me the content of the <step> correctly. 

I though {id} would work, but it remains blank.

Any clues?

Thanks.

Kat


 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.