|
[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] RE: expandble list in XSL
get some ideas at www.bayes.co.uk/xml -----Original Message----- From: owner-xsl-list@xxxxxxxxxxxxxxxx [mailto:owner-xsl-list@xxxxxxxxxxxxxxxx]On Behalf Of Johan Andreasson Sent: Thursday, March 30, 2000 02:45 To: XSL-List@xxxxxxxxxxxxxxxx Subject: expandble list in XSL In HTML, when you want to have an expandable list, following is concvinient: <SCRIPT> var xxxx_exposed = false; <---- 2. var yyyy_exposed = false; var zzzz_exposed = false; function show_details(obj) { if ( eval(obj.id+"_exposed" ) == false ) // expand the list { obj.insertAdjacentHTML("BeforeEnd", document.all[obj.id+"_list"].innerHTML); eval(obj.id+"_exposed=true"); } else // collapse the list { obj.children[0].outerHTML=''; eval(obj.id+"_exposed=false"); } } </SCRIPT> with the things you want to hide/show as: <DIV ID="xxxx_list"> <---- 1. thing 1 </BR> thing 2 </BR> .... thing n </BR> </DIV> <DIV ID="yyyy_list"> <---- 1. thing 1 </BR> thing 2 </BR> .... thing n </BR> </DIV> <DIV ID="zzzz_list"> <---- 1. thing 1 </BR> thing 2 </BR> .... thing n </BR> </DIV> .... and the collapsed list as: <H1> LIST </H1> <UL> <LI ID="xxxx" ONCLICK="show_details(this)">xxxx</LI> <LI ID="yyyy" ONCLICK="show_details(this)">yyyy</LI> <LI ID="zzzz" ONCLICK="show_details(this)">zzzz</LI> .... </UL> But to do this with XML and XSL I've come to some problems that forces me to think in another way, those are: 1. I get an error message in IE5 that says it's not allowed to to put <xsl:value-of> within an attribute, is this because of the '<' char or is the whole line forbidden? 2. Here, the script has to have one varable for each item in the list. How can this be solved in XSL? Could it be done as a vector declaration? 3. There is probably more... I really would appriciate some help Thanks Johan Andreasson ______________________________________________________ Get Your Private, Free Email at http://www.hotmail.com XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
|
PURCHASE STYLUS STUDIO ONLINE TODAY!Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced! Download The World's Best XML IDE!Accelerate XML development with our award-winning XML IDE - Download a free trial today! Subscribe in XML format
|

Cart








