I'd like to have a text cursor inside of a textarea input box when the page loads, but I lack the Javascript know-how to do it. Could someone point me in the right direction?
| SitePoint Sponsor |

I'd like to have a text cursor inside of a textarea input box when the page loads, but I lack the Javascript know-how to do it. Could someone point me in the right direction?




assuming that your textarea was named "textarea1", and your form was named "form1", you'd do this...
Code:<body onload="document.form1.textarea1.focus()">
----Adopt-a-Sig----
Your message here!

That's perfect! Thanks a lot for your help!![]()
Bookmarks