A little help with an Expandable Text Menu

admin

Administrator
Staff member
Im having a little trouble with a javascript action i was hoping someone here would be kind enough to help me with.

Im utilizing the following script in my page:

<script language="javascript">
<!--

function change() {
if(!document.all)
return
if (event.srcElement.className=="expandable"){
var x=event.srcElement.parentElement
if (x.all[2].style.display=="none"){
x.all[2].style.display='';
}
else {
x.all[2].style.display="none"
}
}
if (event.srcElement.className=="expandable2"){
var x=event.srcElement.parentElement
if (x.all[2].style.display=="none"){
x.all[2].style.display='';
}
else {
x.all[2].style.display="none"
}
}
}
document.onclick=change

function MM_displayStatusMsg(msgStr) { //v1.0
status=msgStr;
document.MM_returnValue = true;
}
//-->
</SCRIPT>

What i have been trying to do, with no avail, is change the script so the default action for the menus is expanded, and when you click they contract. If anyone out there could possibly help me with this, i would be indebted to you.

Thanks,
BRK
 
Back
Top