Computer Forums

Member Login

Remember Me? Sign Up! | Forgot Password
 
Slogan
 
Computer Forums > Programmers Lounge > Programming Discussions » Email Forms - "Thank You" Page
Closed Thread
Old 02-22-2004, 12:56 AM   #1 (permalink)
 
Junior Techie

Join Date: Feb 2004

Posts: 81

JimShorts

Send a message via AIM to JimShorts
Exclamation Email Forms - "Thank You" Page

Hey guys I need to know how to do this by Friday so please respond! It's for a FBLA (Future Business Leaders of America) competition. Okay, here we go.

On my website I have a "contact us" form that I want to send an email to me. My problem is that I know how to make it send the email, and I know how to make a form that just links to a new page. BUT I don't know how to make the form send me an email and take the user to a "thank you" page.

I really need to know how to do this guys. Thanx.
__________________
KEVIN
JimShorts is offline  
Old 02-22-2004, 02:22 AM   #2 (permalink)
 
Monster Techie

Join Date: Jul 2003

Posts: 1,179

Emily is on a distinguished road

Send a message via AIM to Emily
Default

Put the form on one page and in the form tag, put action="page2.php". Then on page2.php, put the PHP code for sending the email and the thank you message you want.

Hope this helped.
__________________
<a href=\"http://www.upstark.com\">www.upstark.com</a>
Emily is offline  
Old 02-23-2004, 12:58 AM   #3 (permalink)
 
Super Techie

Join Date: Dec 2003

Posts: 333

Harold III

Send a message via AIM to Harold III
Default

omfg I found one fbla guy!!!!!!!!!!!1 oh my god

you must be doing the webdesign competition, creating a website for a multimedia company right? I'm going to do the networking concept. last year I did that network design with another girl but we failed... and I don't like that network design, it's so stupid, you have to figure out a whole set of solution in scarcely 15 minutes.
__________________
I do this for Aiur. NOT YOU.
Harold III is offline  
Old 02-23-2004, 01:39 AM   #4 (permalink)
 
Junior Techie

Join Date: Feb 2004

Posts: 81

JimShorts

Send a message via AIM to JimShorts
Default

Emily- Where do I learn how to post PHP code?

Harold- Yep, webdesign. I won Word Processing II last year. Good luck on the networking concepts.
__________________
KEVIN
JimShorts is offline  
Old 02-23-2004, 02:00 AM   #5 (permalink)
 
Super Techie

Join Date: Dec 2003

Posts: 333

Harold III

Send a message via AIM to Harold III
Default

Everybody, please call me Harold the second instead of Harold cuz the English King Harold was a dummy. please please please.

"*" means "<", "%" means ">"
in your contact page:
*form action="page2.php"%
name your subject field as subject. name your message field as message

you put your php code on your page2.php file, like:

*?php
function thanx() {
echo "Thank you for your comments!";
}

function failure() {
echo "My mailbox is not available right now, please contact later!";
}

$to="jimshorts@bhabhabha.com";

if (mail($to, $subject, $message)) {
thanx();
}
else {
failure();
}

//Emily is my teacher, so I answered for her
?>
__________________
I do this for Aiur. NOT YOU.
Harold III is offline  
Old 02-23-2004, 10:35 AM   #6 (permalink)
 
Monster Techie

Join Date: Jul 2003

Posts: 1,179

Emily is on a distinguished road

Send a message via AIM to Emily
Default

^^ That should do it.
__________________
<a href=\"http://www.upstark.com\">www.upstark.com</a>
Emily is offline  
Old 02-23-2004, 05:51 PM   #7 (permalink)
 
Super Techie

Join Date: Dec 2003

Posts: 333

Harold III

Send a message via AIM to Harold III
Default

Thank you mam.
__________________
I do this for Aiur. NOT YOU.
Harold III is offline  
Old 02-23-2004, 08:30 PM   #8 (permalink)
 
Junior Techie

Join Date: Feb 2004

Posts: 81

JimShorts

Send a message via AIM to JimShorts
Default

Thanx for your help!
__________________
KEVIN
JimShorts is offline  
 
Closed Thread

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On