[Javascript] was: How to hide check box inside a form

vallinis vallinis at yahoo.com
Fri Jan 4 13:15:28 CST 2002


God willing, I did it finally... I kept interacting with the yahoo egroup 
for two days trying to work out why just that group out of 20 I am 
subscribed with at yahoo did not accept my postings LOL... I definitively 
suggest to outline in a nice bold red H2 tagged text at the yahoo archive 
front page that users should not subscribe/post using the yahoo egroups 
address: that's atypical an approach for yahoo groups, you see, and many 
users do not know what "this group is a remote group" mean (now I know ha ha!).
Ok, let's go.
----------------------
Hallo,

uhm actually you could and could not, with Ns4. I mean that if
you create a div and nest in it a form of its own with its own
elements, as long as these elements
1)are NOT select menus,
2)and as long as the div tag as an id
3)and has a style where position top left z-index and visibility are
all defined,

well you can show and hide it on NS4 too, to some degree.
You might stumble into a problem given to the fact that at times, in
an unpredictable way, NS4 accepts to read an invisible value to the
visibility property not like ''hidden'' but like... "hide", so you'd
tailor your script in order to dectect both possibilities, sort of in
pseudocode:
if (object.style.visibility=="hidden"||"hide")
of course that's not javascript, it is pseudocode (and, by the way,
don't get the idea using the || operator in that fashion is a cool
idea! it is not for it doesn't compare at all, it just returns. Which
means: works only if you already know one object of the hypotetic
comparison is a false or a zero. Some feature such use of the or
operator like a comparison. It compares as much as plummet can decide
which spot to fall on).

Keeping in mind these tips, you'd be able to toggle some items
visibility in NS4 too. You'd obviously find an enormous amount of
further problems: to read the values of the layer you'd address it
like
document.layers['layerName'].document.forms[0].filedName.value
which is very much aristocratic and very much unpractical as well.

Last but not least, I've never hidden fiorms for the simple reason
that NS4 cannot hide a select no matter what you do, and my forms
always included a lot of elements and select boxes too so I never
implemented it, but I heard a few times that NS4 when showing/hiding
a form, might stop toggling the visibility after the first two or
three attempts. So, just keep in mind.
I hope all this helps. Remember that what Toms says to you is
correct: you can toggle visibility on NS4 only by calling in a fair
amount of adjunctive work, and with several cautions to by-pass a lot
of tricky situations.
Obivuosly, you need a DOM detection script, but I believe that you
can manage.
ciao (sorry for typos or so, english not my native tongue)


Alberto .·. Vallini
http://www.unitedscripters.com



_________________________________________________________
Do You Yahoo!?
Get your free @yahoo.com address at http://mail.yahoo.com




More information about the Javascript mailing list