Autoload cursor in textbox

I have a problem with getting to have the cursor atomatically appearing in the textbox without messing up other functions going on. Is there any way to get the cursor in the textbox when the page loads without messing up the funtion or am I stuck with users having to click in the box before entering info?

You can do it with this snippet of Javascript:
<body onLoad=“document.forms.formname.inputname.focus()”>
Obviously change the bits in green to the relevant names for your page.