[thelist] readonly and visibility in Netscape 4
Peter-Paul Koch
ppk at xs4all.nl
Tue Aug 15 14:51:33 CDT 2000
>I am having a few problems with readOnly and visibility in Netscape. I want
to be able to hide a Select box and I've used these parameters to no avail.
Readonly doesn't work in Netscape.
> if (vertype()=="nav")
> {
> // None of these seem to work
>
> document.form1.list.style.visibility = "hide";
> document.layers["list"].visibility = "hide";
> }
The first one is Explorer-style, so wrong. As to the second one, if 'list'
is a layer it works. However, in order to make it a layer you *must* define
a 'position' in a style sheet (values: 'absolute' or 'relative').
If even this doesn't help, place a DIV around the SELECT and give it
ID=list so that the script now works on a DIV instead of a SELECT.
For more info about cross-browser DHTML and what can go wrong, see
http://www.xs4all.nl/~ppk/js/
under DHTML => Introduction and DOM
ppk
More information about the thelist
mailing list