[Javascript] Fw: hide other divs

Troy III Ajnej trojani2000 at hotmail.com
Wed Apr 12 16:58:05 CDT 2006


Laurent, your script should have worked perfectly if you haven't 
accidentally misstyped
"=" (asingement) instead of "!=" (comparement) in your substituted 
conditional.

---------------------------------------------------------------------
       var divElementsId = ''
if(divElementsId != divElements[i].getAttribute("id")){//that is, -not 
empty! Than...
if(divElementsId.substring(0,6) == mySubstring && divElementsId != 
myDiv)//All other, but not myDiv. Than...
   {
    divElements[i].style.display = "none";//Hide them!
    }     }}
---------------------------------------------------------------------

nice work!
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Troy III
progressive art enterprise
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

_________________________________________________________________
Express yourself instantly with MSN Messenger! Download today - it's FREE! 
http://messenger.msn.click-url.com/go/onm00200471ave/direct/01/




More information about the Javascript mailing list