471,599 Members | 977 Online
Bytes | Software Development & Data Engineering Community
Post +

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 471,599 software developers and data experts.

Dropdown z-index problem

Bob Ross
119 100+
I am trying to place an object on top of a drop down menu but the drop down always displays at the front in IE6.
Here is my code -

Expand|Select|Wrap|Line Numbers
  1.  <div runat=server align=left style="position:absolute; z-index:1"><asp:DropDownList ID="DropDownList1" runat="server" Width="234px"></asp:DropDownList></div>
  2.                                      <div runat=server align=left style="position:absolute; z-index:100"><asp:TextBox ID="TextBox1" runat="server" Height="108px"></asp:TextBox></div>
*This is simple case to try and work out a solution.
I have been googling and came across this - "Windowed elements such as SELECT and, in earlier browsers, IFRAME are always a higher z-index than other elements, such as DIV."

Does anyone know a way around this at all?
Sep 21 '07 #1
2 2485
PaulVS
13
I am trying to place an object on top of a drop down menu but the drop down always displays at the front in IE6.
Here is my code -

Expand|Select|Wrap|Line Numbers
  1.  <div runat=server align=left style="position:absolute; z-index:1"><asp:DropDownList ID="DropDownList1" runat="server" Width="234px"></asp:DropDownList></div>
  2.                                      <div runat=server align=left style="position:absolute; z-index:100"><asp:TextBox ID="TextBox1" runat="server" Height="108px"></asp:TextBox></div>
*This is simple case to try and work out a solution.
I have been googling and came across this - "Windowed elements such as SELECT and, in earlier browsers, IFRAME are always a higher z-index than other elements, such as DIV."

Does anyone know a way around this at all?
Hi there,

Its a known problem and what i find the best sollution is with Javascript trigger a onmouseover event on what needs to be on top of the dropdown. And then hide the dropdown.

Greetings,

Paul
Sep 21 '07 #2
drhowarddrfine
7,435 Expert 4TB
I never remember the solution to this (in css) though I've seen it myself. Play with adding position:relative to some of the elements (I think). You might trying adding your own z-index value.
Sep 21 '07 #3

Post your reply

Sign in to post your reply or Sign up for a free account.

Similar topics

reply views Thread by Toonman | last post: by
5 posts views Thread by Gil | last post: by
3 posts views Thread by CSharpguy | last post: by
5 posts views Thread by jung_h_park | last post: by
2 posts views Thread by XIAOLAOHU | last post: by
reply views Thread by leo001 | last post: by

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.