How do I use AzNET's FormMail script?


Due to the discovery of a grave security hole in the shared common FormMail.pl script we had previously made available for our customers to use, we can no longer provide it for use. If you'd like to use a form-mail CGI script on your website, you'll need to install your own individual script on your site as per the instructions below. AzNET apologizes for any inconvenience.

1. Download the formmail script from here

2. Rename the script to "formmail.pl"

3. Open the script in a plain text editor such as NotePad or Simpletext (*not* Wordpad or MS Word). You only need to make 2 small edits to customize the script for your site. Look for the section near the top around line 40 called "SETTING YOUR SERVER NAME" and follow the instructions in the script for entering your server name.

4. After making that change, look for the section right below called "SETTING YOUR RECIPIENT ADDRESS" and follow the instructions in the script for entering the address the form contents should be emailed to.

5. Do "chmod 0755" on the script (this makes the script executable, and should be an option in your FTP program) and upload it to your site. If you don't have a folder called "cgibin" on your site already, you might want to create one and upload the script into it, but it is not necessary. If you do have a cgi directory, it's advisable to name it something besides "cgi-bin" (i.e. leave out the hyphen, etc), since "cgi-bin" is the name of the default cgi directory for the entire server and may cause the web server to look in there for your script instead of the directory on your website.

6. Then reference the script from your HTML form like so (substituting the "path/to/your/formmail.pl" with the actual path to the script on your site:)

‹form method="POST" action="path/to/your/formmail.pl"›

Example: ‹form method="POST" action="http://www.mydomain.com/cgibin/formmail.pl"›

7. Done.


A service of zNET Internet Services