Support Forum Softcomplex logo
About Us  | Services  | Download  | Order  | Support  | |
| Search | Today's Posts | Stats | Board Rules | Not logged in [ Login | Register ]
go to bottom
Last active: Never

Printable Version | Subscribe | Add to Favourites   Post new thread
Author: Subject: Tip: How to hide select form elements
aetchell
Junior Member

Posts: 2
Registered: 7/10/2005
Location: sheffield UK
Member Is Offline
posted on 7/10/2005 at 01:33 PM Reply With Quote
Tip: How to hide select form elements


Hi All

this has probebly already been done but i couldnt find any reference to it in the forums

if you want to hid select form elements that render above everything in a browser window (i think this is an IE only thing)

amend the following functions in menu.js

menu_onmouseout
add:
var selNodes = document.getElementsByTagName('select')
var i=0;
if (!selNodes.item(0)){
return false;
} else {
do{selNodes.item(i).style.visibility = 'visible';}
while(++i < selNodes.length);
}


menu_onmouseover
add:
var selNodes = document.getElementsByTagName('select')
var i=0;
if (!selNodes.item(0)){
return false;
} else {
do{selNodes.item(i).style.visibility = 'hidden';}
while(++i < selNodes.length);
}

this will show/hide all select elements on the page when the menu is activated

my javascript knowledge is pretty poor so someone could come up with a much better way i imagine, flash elements could do with being hidden too.

Would love to see a better version of the code above, as its just a quick hack i just added.

regards
ash
View User's Profile View All Posts By User U2U Member
aetchell
Junior Member

Posts: 2
Registered: 7/10/2005
Location: sheffield UK
Member Is Offline
posted on 7/10/2005 at 01:48 PM Reply With Quote
oops error in js


it had return false; in there, you dont wont to be doing that

amended code:

menu_onmouseout
add:
var selNodes = document.getElementsByTagName('select')
var i=0;
if (!selNodes.item(0)){

} else {
do{selNodes.item(i).style.visibility = 'visible';}
while(++i < selNodes.length);
}


menu_onmouseover
add:
var selNodes = document.getElementsByTagName('select')
var i=0;
if (!selNodes.item(0)){

} else {
do{selNodes.item(i).style.visibility = 'hidden';}
while(++i < selNodes.length);
}
View User's Profile View All Posts By User U2U Member
Post new thread

Related Links:
Product Page Tigra Menu
Product Demonstrations Live Demos:
Traditional Blue
White Steps
Inner HTML
All Together
Frames Targeting
Free Download Free Download
Free Download Menu Builders
Online Builder
Builder for Windows
Product Documentation Documentation:
Documenation Page
Change Log
Menus Comparison Table
Support Forum Support Forum
 

Go To Top


Powered by XMB 1.9.1 Nexus
Developed By Aventure Media & The XMB Group © 2002-2004