how do i have html form data emailed to me?
March 31, 2006 8:02 AM   Subscribe

I know how to create html forms (very basic ones), but, without using mailto: I don't know how to have the data the user submits emailed to me.

I've googled around and found out that since I don't want to use the mailto: tag (I don't want to assume that the user has Outlook or another non-web based email) I want to use a CGI script to tell the form to email me the info the user submits. But I can't figure out what CGI script to use or how to implement it.

I haven't created a web form since the late 90s and I have no idea what's changed and I can't remember how I did this years ago.

Any suggestions, aside from just using mailto:, would be greatly appreciated.
posted by misanthropicsarah to Computers & Internet (7 answers total)
 
you need a serverside program likeley Perl PHP or ASP you can find about a billion of these simple scripts my googling for "PHP form mail" or "Perl form mail" you just need to find out which your webserver supports
posted by BSummers at 8:06 AM on March 31, 2006


You can get a script and instructions from HERE
posted by Ferrari328 at 8:06 AM on March 31, 2006


You will need to write or use a premade application to act as a mail sender. This can be done easily with sendmail and a simple php/perl script...but it has a lot to do with where your content is hosted. Is this a server you have access to....one a friends server, paid hosting, myspace, etc. What OS is it running, can you run php/perl/asp? Some php scripts can be found here, and soem perl scripts can be found here...trial and error...

this site allows public creation and hosting....i think


good luck
posted by killyb at 8:11 AM on March 31, 2006


There are lots of samples of Perl CGI mailers on the web (a simple one would be only a few dozen lines), just google for cgi mail perl. If you have perl on your server, just install one of them (they are so simple that it is hard to recommend one specifically).

If your server doesn't give you perl or cgi, you can use a some free "form-to-mail" services. In this case, you just put them as the post address of your form, and they format the form contents and send to your email. Of course, in this case, privacy concerns apply (all data is passing through their servers). A list of Form-to-mail gateways is here: http://www.thefreecountry.com/scripthosting/formtomail.shtml
posted by qvantamon at 8:17 AM on March 31, 2006


Best answer: One thing that I think is not 100% clear from the (helpful!) answers given thus far is that most hosts do include a form processor in the hosting package, even if you have a fairly cheapola account that doesn't otherwise let you run your own programs on the server. So check the documentation that comes with your hosting package before you drive yourself nuts trying to pick one out from the thousands that are available online.
posted by bcwinters at 8:18 AM on March 31, 2006


Best answer: Also, make sure whatever form mail script you end up using is spam-proof. I learned the hard way. See this thread
posted by Robot Johnny at 8:26 AM on March 31, 2006


Best answer: check the documentation that comes with your hosting package before you drive yourself nuts

Just what I was about to say. It's a pretty poor hosting service which doesn't include at least a mail form.
posted by AmbroseChapel at 3:19 PM on March 31, 2006


« Older Multiple channels of TV on one screen?   |   Recommend me some sparse moody instrumental music Newer »
This thread is closed to new comments.