ricardo259
11-21-2003, 08:46 PM
Hi
Trying to add some usability to my forms...I'm struggling to make the onLoad and onFocus event handlers have any effect.
I was led to believe by the HTML Goodies site that this code:
VALUE="This is text in a text box" SIZE="45" onFocus="this.value=''">
...would enable example text in a text box to be removed with one click, rather than by highlighting and erasing. But it doesnt seem to.
Also, this code:
onLoad="self.focus();document.FORM_NAME.ELEMENT_NAME.focus()"
...should make the cursor start flashing in the first text entry box when the page loads, but it doesnt.
Any ideas what I'm doing wrong?
Trying to add some usability to my forms...I'm struggling to make the onLoad and onFocus event handlers have any effect.
I was led to believe by the HTML Goodies site that this code:
VALUE="This is text in a text box" SIZE="45" onFocus="this.value=''">
...would enable example text in a text box to be removed with one click, rather than by highlighting and erasing. But it doesnt seem to.
Also, this code:
onLoad="self.focus();document.FORM_NAME.ELEMENT_NAME.focus()"
...should make the cursor start flashing in the first text entry box when the page loads, but it doesnt.
Any ideas what I'm doing wrong?