Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

DHTML Menu with SPAN tags

Status
Not open for further replies.

Guest_imported

New member
Jan 1, 1970
0
Hi:
I'm developing a web page with a DHTML Menu. I'm using DIV and SPAN tags. I have a problem when a submenu is shown because its items are truncated by a form. This form is after the menu.
I'm looking for a property like "Always on top" in HTML o JavaScript for solve this problem. If someone can help me,
I will thank it.
Here some of my code:
<STYLE>
.menu {background-color:darkgray;width:200; color: white; text-align: center}
.submenu {position:absolute;background-color:darkgray;color: white;width:200}
</STYLE>
<body bgcolor=&quot;#c0c0c0&quot;>
<DIV id=&quot;Menus&quot; STYLE=&quot;position:absolute;top:0;left:0;height:20;background-color:#C0C0C0;&quot; NOWRAP>
<SPAN ID=&quot;d1&quot; onmouseover=&quot;show(this,ds1);&quot; class=&quot;menu&quot; STYLE=&quot;Width:15%;background-color:#C0C0C0&quot;><LABEL STYLE=&quot;text-decoration:none;cursor:hand;font:bold xx-small Verdana;color:black&quot; >Sesión</LABEL></SPAN>
<SPAN ID=&quot;d11&quot;class=&quot;menu&quot; STYLE=&quot;Width:1px;background-color:#C0C0C0&quot;><LABEL STYLE=&quot;text-decoration:none;cursor:hand;font:bold xx-small Verdana;color:black&quot; >| </LABEL></SPAN>
<SPAN ID=&quot;d2&quot; onmouseover=&quot;show(this,ds2);&quot; class=&quot;menu&quot; STYLE=&quot;Width:15%;background-color:#C0C0C0&quot;><LABEL STYLE=&quot;text-decoration:none;cursor:hand;font:bold xx-small Verdana;color:black&quot; >Administración</LABEL></SPAN>
</DIV>
<DIV ID=&quot;ds1&quot;CLASS=&quot;submenu&quot; STYLE=&quot;Width:16%;DISPLAY: none;background-color:#C0C0C0&quot; onmouseout=&quot;MouseMenu('OUT');&quot; onmouseover=&quot;MouseMenu('OVER');&quot;>
<A HREF=&quot;/mensaje.htm&quot; STYLE=&quot;text-decoration:none;cursor:hand;font:bold xx-small Verdana;color:black&quot; >Modo Off Load</A><BR>
<A HREF=&quot;/fin.htm&quot; STYLE=&quot;text-decoration:none;cursor:hand;font:bold xx-small Verdana;color:black&quot; >Cerrar Sesión</A><BR>
</DIV>
<DIV ID=&quot;ds2&quot;CLASS=&quot;submenu&quot; STYLE=&quot;Width:16%;DISPLAY: none;background-color:#C0C0C0&quot; onmouseout=&quot;MouseMenu('OUT');&quot; onmouseover=&quot;MouseMenu('OVER');&quot;>
<A HREF=&quot;/documentos.htm&quot; STYLE=&quot;text-decoration:none;cursor:hand;font:bold xx-small Verdana;color:black&quot; >Cuadre de Documentos</A><BR>
<A HREF=&quot;/servicios.htm&quot; STYLE=&quot;text-decoration:none;cursor:hand;font:bold xx-small Verdana;color:black&quot; >Cuadre de Servicios</A><BR>
<A HREF=&quot;/cajeros.htm&quot; STYLE=&quot;text-decoration:none;cursor:hand;font:bold xx-small Verdana;color:black&quot; >Cuadre por Cajero</A></DIV>
<form id=frmTxns bgcolor=&quot;#c0c0c0&quot; STYLE=&quot;LEFT: 10pt; POSITION: absolute; TOP: 15pt; WIDTH: 550pt&quot;>
<p style=&quot;BORDER-BOTTOM: 3px inset; BORDER-LEFT: 3px inset; BORDER-RIGHT: 3px inset; BORDER-TOP: 3px inset; MARGIN-TOP: 0px; WORD-SPACING: 52px&quot; align=&quot;center&quot;> <select id=cboGrupos size=&quot;1&quot; name=&quot;D1&quot; STYLE=&quot;WIDTH: 150pt&quot;>
</select><input id=txtTrans name=&quot;T1&quot; size=5><select id=cboTrans size=&quot;1&quot; name=&quot;D2&quot; STYLE=&quot;WIDTH: 150pt&quot;>
</select> </p>
</form>
</body>
 
It's the browsers. They (particularly Netscape) always have form elements on top, no matter how you try to specify their z coordinates. Nothing you can do except wait until everyone upgrades to Netscape 6 or 7 or whenever it gets fixed. I wouldn't go making any plans for that yet. Get around it by not having DHTML layers trying to cover form elements. [sig]<p> Sincerely,<br><a href=mailto: > </a><br><a href= Anderson</a><br>CEO, Order amid Chaos, Inc.<br>
[/sig]
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top