User Login

Help Community Login:

How Do I Create a Web Contact Form To Email Me?

5 replies [Last post]
Smartmom's picture
From:
Wellington Florida
Smartmom
Banned Member (Way To Go!)
Relationship Status:
Married
Joined: 01/15/2009
Posts: 6392
Drops: -21
Mood: Giggly

Ok here is my stump the dogg question which I hope you really can help me because its not really a bogus question but one that has me banging my head against the wall.

So I am the webmaster for my office website and have been for the last few years. Ok my one contact form on it when they fill out the info it takes them to a page on the webhosting site that says this:

The following form submission was sent.
Name: test5
E-Mail: test5
Phone: test5
Subject: test5
Comments/Questions:test5
Submit: Submit
_submit_check: 1

to which then sends me a email with the info mailed out. Here is the thing after they hit "submit" I would like it to redirect them back to the home page or a page I create that says "thank you for submitting ...yada yada yada" . So how do I do this? Is there a way to add a redirect command into the submit button?

Here is my coding for my button:

<td colspan=1 height=33></td>
<td colspan=4 height=33></td>
<td colspan=6 rowspan=1 width=83><input name="Submit" type="submit" value="Submit" />
<input type="hidden" name="_submit_check" value="1"/>
</form>

I'll PM you dogg my web URL - sorry can't post it here (privacy and all). Help............

I Averaged: 0 | 0 votes

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
STaRDoGG's picture
From:
Olympus
STaRDoGG
Head Mucky MuckJoined the Dark SidePremium Member (Gold)I'm a Code Monkey!The Steel CurtainI use FirefoxI use Google ChromeI use Internet ExplorerI use SafariLinux UserMac UserWindows UserI donated to GeekDrop simply because I love it!Booga Booga BoogaI took a bite of the AppleFormer Phrozen Crew MemberI'm MagicMember of VileThe Dr. put the stem on the apple!The JokerSomeone thinks you're udderly delightful!
Relationship Status:
Single & Not Looking
Joined: 01/14/2009
Posts: 2566
Drops: 3023
Mood: Energetic
Re: How do I redirect?

Ok, there are many different ways to create a contact form; they can be made with PHP, CGI, Pearl, ASP, ASP.NET, and other languages, but no matter which one you choose, they all boil down to the same concept; you create a Form, that passes the form fields (whatever the user types into the blank lines) to some code (that's where the PHP, CGI, etc. comes in) and the code then handles the emailing of the info to wherever you want it. The final redirect can be chosen in the code.

Since I don't want to make any assumptions on what is already installed on your host, the easiest way is the oldest way. Most hosts have no problem handling CGI/Perl scripts, so here is a free script, very easy to configure and install, and it has an option in it's configuration (use notepad to open the configuration file, which is the script itself) to enter a page you want the user sent off to once the email has been sent to you. Clicky

There's a readme file that describes exactly how to set it all up, and the options available, as well as showing them on the webpage in that link itself. You'll see an option to redirect:

"Description: If you wish to redirect the user to a different URL, rather than having them see the default response to the fill-out form, you can use this hidden variable to send them to a pre-made HTML page."

There, you can enter your default URL if you want, but it's usually better to give them some sort fo feedback letting them know it was sent succcessfully. You can create your own page to show them saying "Your message has been successfully sent", or however you want to handle it.


Never play leapfrog with a unicorn
Smartmom's picture
From:
Wellington Florida
Smartmom
Banned Member (Way To Go!)
Relationship Status:
Married
Joined: 01/15/2009
Posts: 6392
Drops: -21
Mood: Giggly
Re: How do I redirect?

Thank ya dogg...........me love you long time. My brain is to fried tonight to play with it but I will tomorrow. I agree I would rather do a "your submission was sent...yada yada yada" so they don't send me 15 contacts Smile

STaRDoGG's picture
From:
Olympus
STaRDoGG
Head Mucky MuckJoined the Dark SidePremium Member (Gold)I'm a Code Monkey!The Steel CurtainI use FirefoxI use Google ChromeI use Internet ExplorerI use SafariLinux UserMac UserWindows UserI donated to GeekDrop simply because I love it!Booga Booga BoogaI took a bite of the AppleFormer Phrozen Crew MemberI'm MagicMember of VileThe Dr. put the stem on the apple!The JokerSomeone thinks you're udderly delightful!
Relationship Status:
Single & Not Looking
Joined: 01/14/2009
Posts: 2566
Drops: 3023
Mood: Energetic
Re: How do I redirect?

It's been years since I used that particular script, but that should be the default action once the user submits the form. Once you get it working, you can add a little custom coding to the script if you're feelin' froggy, and use a meta redirect after a pause, to still send them to another page.


Never play leapfrog with a unicorn
missb's picture
missb
Banned Member (Way To Go!)
Relationship Status:
Single & Not Looking
Joined: 01/16/2009
Posts: 3109
Drops: 3812
Mood: Weird
Re: How do I redirect?

SCORE!!! All hail the DoGG Not Worthy Laughing

Smartmom's picture
From:
Wellington Florida
Smartmom
Banned Member (Way To Go!)
Relationship Status:
Married
Joined: 01/15/2009
Posts: 6392
Drops: -21
Mood: Giggly
Re: How Do I Create a Web Contact Form To Email Me?

I am soooooooooooooo doing the happy dance I got my page to work and it redirects you to a nice Thank you page when done Big Grin

THANk YOU DOGG!!!!!!!!!!!!!!!!!!

Who's New

asDewt2354 tnw3's picture
SamCritch's picture
part's picture
tricoat's picture
noster's picture
bebiiee's picture
JustLOVETheGeek's picture
jhonzeth's picture
kaushalmalkan11's picture
avinash.5107218's picture
Raez's picture
MondayTuesday09's picture
sabrina_marie's picture
Tallen's picture
aaron420's picture
facebook codes exploits tips tricks Phrozen Crew
All contents ©Copyright GeekDrop 2009-2017
TOS | Privacy Policy