Web Design
Drawing Attention to Your Forms
A little known tip that helps draw attention to any form on your page
is the blinking cursor within a form field that flashes when the page
is loaded. This is especially effective for mailing list sign up forms,
feedback forms and recommend-it forms on your page.
Place the code below in the <BODY> tag.
This code instructs the browser to display the blinking cursor within
the "signup" form in the text box named "email".
<body onLoad="focus();signup.email.focus()">
You can change the form name and text box name to whatever you wish.
However, it must also be changed within your <BODY> tag. If they
are not the same, the browser will not understand the command.
Here is the form's source code with corresponding color codes to help
you understand.
<form name="signup" method="post"
action="http://www.yoursite.com/cgi-bin/script.cgi">
<input type="text" name="email"
size="15" maxlength="40">
<input type="text" name="name" size="15"
maxlength="40">
<input type="submit" name="submit" value="Send">
</form>
Of course, you will need to change the action line to whatever script
processes the form on the web site server. Contact your web hosting service
if you are not sure what to use.
|