Div over textbox, can't select the textbox as used to!

I have a div over all of the forms inside of a asp.net page.

All form are clickable but only the textbox and the textarea aren't.

if i want to click in the textbox i don't get the prompt in the controls.

My div looks like this:
<div style="position:absolute; top:180px; width:980px; height:2000px; z-index:101;"></div>

While my textbox looks like this:
<asp:TextBox ID="myTextBox" runat="server" Width="160px"></asp:TextBox>

I've tried putting an z-index to the textbox also , bigger as value but it didn't helped!

Any ideas?

Thanks.
LVL 1
drcyrus3dAsked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

JezcentralCommented:
Sorry, I don't understanbd what you are trying to do. Can you try to explain in a little more detail, or maybe give me a URL to go to so I can see what you mean?

Cheers. :)
0
drcyrus3dAuthor Commented:
Hi Jez,

I've pasted you a short example of what i am trying to do.
My problem is that i can't select the textbox or the textarea as you could do it usualy!

The Selectbox works perfectly, when i want to select a value from it.

Any ideas? I know it's a css catch, but i'm totaly out of any ideas!

Thanks.
<form id="form1" name="form1" method="post" action="">
  <input type="text" name="textfield" id="textfield" /><br /><br />
  <textarea name="textarea" id="textarea" cols="45" rows="5">This is just an example!</textarea><br /><br />
  <select name="a">
  <option value="a1">a1</option>
  <option value="a2">a2</option>
  <option value="a3">a3</option>
  <option value="a4">a4</option>
  <option value="a5">a5</option>
  </select>
</form>
<div style="position:absolute; top:0px; left:0px; width:1500px; height:1500px; z-index:10001;"></div>

Open in new window

0
JezcentralCommented:
The select box could be a known IE bug where, like a flash movie, or a Windows Media Player, you can't put an HTML element on top of it.

If you try this code in Firefox, you can't click on any of the form boxes, even the SELECT box, which is correct behaviour, as there is a DIV hanging in front of them.

Are you trying to disable the forms? You are better off using "disable='true' " in the HTML.
Then, when you want to enable the form element again, just use a simple javascript:
document.formXXX.elementXXX.disabled=false; fired by a mouseevent (usually an onclick/onblur on the element you needed filled in before they could fill in these ones).

Is this what you are after? :)
0
The Ultimate Tool Kit for Technolgy Solution Provi

Broken down into practical pointers and step-by-step instructions, the IT Service Excellence Tool Kit delivers expert advice for technology solution providers. Get your free copy for valuable how-to assets including sample agreements, checklists, flowcharts, and more!

drcyrus3dAuthor Commented:
Unfortunately no. The div is above my form and serves as an control for other components.

I want to be able to click the textbox and the texarea in IE.

I am interested only on the IE side of it (like IE7).
0
JezcentralCommented:
Give the input a z-index AND a position: absolute; (Just no left or top).

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
      "http://www.w3.org/TR/html4/loose.dtd">
 
<html>
<head>
    <title>Test</title>
    <style type="text/css">

    </style>
</head>
 
<body>
<form id="form1" name="form1" method="post" action="">
  <input style="position: absolute; z-index: 20001;" type="text" name="textfield" id="textfield" /><br /><br />
  <textarea name="textarea" id="textarea" cols="45" rows="5">This is just an example!</textarea><br /><br />
  <select name="a">
  <option value="a1">a1</option>
  <option value="a2">a2</option>
  <option value="a3">a3</option>
  <option value="a4">a4</option>
  <option value="a5">a5</option>
  </select>
</form>
<div style="position:absolute; top:0px; left:0px; width:1500px; height:1500px; z-index:10001;"></div>
 
Open in New Window
</body>
</html>
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
drcyrus3dAuthor Commented:
Thanks for the solution! It worked. :) I knew it had to be something very easy.
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
CSS

From novice to tech pro — start learning today.