How to Install a CGI Script and Increase Web Site Interactivity - Create your html form
(Page 3 of 4 )
8. Rename your cgi script - name your script something else besides formmail (ie contactus.pl), as this is the most common name people use. This will prevent spammers from harvesting your email address.
9. Create your html form (contactus.htm)
<html>
<head>
<title>Contact Us</title>
</head>
<body bgcolor="#FFFFFF" text="#000000">
<form method="post" action="http://www.yourdomain.com/
cgi-bin/contactus.pl">
<input type=hidden name="recipient" value="siteowner">
<input type=hidden name="subject" value="Subscribe Me Please">
<input type=hidden name="required" value="fullname,email">
<input type=hidden name="redirect" value="http://www.yourdomainname.com/thankyou.htm">
Full Name<br>
<input type=text name="fullname">
<br>
Email Address<br>
<input type=text name="email"><br>
<br>
Comments<br>
<textarea name="comments"></textarea>
<br>
<br>
<input type="submit" name="Submit" value="Submit">
</form>
</body>
</html>
10. Create a confirmation page (ie thankyou.htm) - this will automatically thank people for filling in your form. It can be a simple html page with the comments "Thank you for your interest. We will respond shortly".
Next: Uploading the cgi script and html email form >>
More Web Hosting How-Tos Articles
More By Herman Drost