You've already seen the Submit button and you know how to place custom
text on a button. But if that's not enough control for you, you can always
use an image. Let's look at the following form.
Choose an item and click on the monkey to submit:
How did we make that monkey into a Submit button? Well, here's the code
for the form:
<form action="nextpage4.html" method="get" name="form3">
<select name="menu" size="3" multiple>
<option value="1">menu item 1</option>
<option value="2">menu item 2</option>
<option value="3">menu item 3</option>
<option value="4">menu item 4</option>
</select>
<input type="image" alt="The Monkey" src="stuff/smallmonkey.gif">
</form>
You see? Just change the type from submit
to image and provide a GIF. Now you're set.
Finally, if you have a really long form and you want to give your users
a chance to clear out the selections they've made, you can add a Reset
button. If you enter some information into the textbox below and then click
Reset, you'll see how this works.
Here's the code for this form:
<form action="nextpage4.html" method="get" name="form1">
<input type="Text" value="" name="thebox" size="40" maxlength="25"><br>
<input type="reset" name="mybutton" value="Reset">
</form>
And that's about it. You now have pretty much all you need to drop a
form onto your site. What's left? You need to set up something on the
backend to process the information you glean with your form.
To learn how to put your forms to work, take a look at Tim's article, in which he shows how
to put a guest book on your site. (This is a lesson you can use to process all
different kinds of forms.) In his JavaScript Tutorial, Thau!
shows all manner of form manipulation. And if you'd like to try some
databasing, check out the Your First Database tutorial.
That's all folks! Now it's only a matter of time before those
users start reaching out and touching you through your Web site.