Creating a Mail Form

Áine on April 30th, 2003 filed in Pixel Pixies

Having avoided creating any sort of webpage “forms” for the last six years, I finally took the plunge and learned how to do it late last night. My webhosts (powersurge.net) have installed a system-wide script for sending formmail, but I had no idea how to implement it until… I went here and read the ReadMe documentation. Then, I realized that I had to create the document that would “call” that script and it’s variables within a form that I created. It all began to make sense, but since I had, up to this point, avoided any sort of webpage forms, I had no clue how to go about doing that. Eeek!

Luckily, I have FrontPage2000… don’t groan, I sometimes use that to quickly whip up a static webpage (most of mine are dynamic, on-the-fly, btw) when I don’t feel like agonizing trying to remember obscure HTML tags. Well, it turns out that FrontPage uses some sort of server bot implemented in FP server extensions, but since I wanted to use an external script to do FormMail, FP wasn’t going to completely do the trick. However, it does contain most of the buttons, drop-down menus, checkboxes, textboxes, and other assorted goodies, which can save a frazzled webmaster a lot of hair-pulling. Ah-ha! This was what I needed.

After an hour or so of randomly choosing form elements and seeing what they do, I started over with a very simple, plain page and began to create my mail form. Then I dug through the html and removed the webbot coding that FP had inserted, and using Matt’s ReadMe file explaining how FormMail works, I was able to insert the proper variables into the spots they needed to be placed to make the script work. I tested it several times to make sure it was actually working, didn’t like the ugly results, and decided to create a custom Thank You page to which users would be redirected after they sent me mail using the form. I then tweaked both pages and made them look attractive. Senders are rewarded with a cookie for their efforts, too.

Ahhhh… much better. You can see the results (and send me a short message) by clicking here. Not too shabby, eh?

Technorati Tags:


Leave a Comment

XHTML Allowed:
<a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <code> <em> <i> <strike> <strong>

Let me give you one piece of advice. Be honest.