0

Here is my code :

<body onload="read()">
<div class="style1" id="Layer3">
<textarea name="textarea" cols="30" rows="5" id="msg" ></textarea>
</div>
<div id="Layer1">Hello World!<img src="body.jpg" width="842" height="559" /></div>
<div id="Layer2"><img src="close.jpg" alt="Go Online/Offline" name="close" width="63"    height="64" id="close" OnClick="action()"/></div>
<div id="Layer4">
<input type="button" value="Send Line" onclick="sendline()" /></div>
<div id="Layer6" style="color:white;font-family:Segoe UI;font-size:16px;width:500px; height:400px; overflow:auto;"></div>
</body>

The problem that I'm facing is that there is no cursor appearing inside the textbox! Nor does the submit button seem to be clickable :S (the above code is a sub part of my whole page's code) Any guesses as to why these error are cropping up ?

Thanks!

1
  • 1
    You are not showing the CSS behind these things so it's impossible to say what the problem may be. The best thing would be a live link. Commented Aug 8, 2010 at 15:17

2 Answers 2

1

It seems that you have float (or absolute positioned) div with transparent background that blocks mouse clicks

-- update

your #Layer6 has position:absolute css attribute, it hides your inputs behind itself using "position:absolute" to create page template is bad practice. but anyway you can try to put "Layer6" div before "Layer1" div to solve problem or play with "z-index" attributes in all your "layers"

Sign up to request clarification or add additional context in comments.

5 Comments

Yes, that is the problem. @Anant: Give the .style1 a higher z-index.(>5)
Umm, that solves the problem,but now when i press submit,the PC freezes! WHy is this happening ?
@Anant: could you please update your techknowlegy.iblogger.org/index.htm with latest version to have a look
i'm not sure about post request in sendline() function, maybe you want to send value - not html element, try something like this: var message = $("#msg").val(); $("#msg").val(" "); $.post("chat.php",{msg:message});
i wanted to send the text in the textarea:msg,so what's wrong with that ?
0

Just some thoughts
1. Where is your <form> tag?
2. A textarea is not a textbox. Try <input type="text"...>
3. I tested this on firefox, and I saw a cursor in the text area...

Edit: You might want to tag this question as jquery as well, because I notice from your source because that's what you are using.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.