Jump to content

form sending to e-mail


johentie80

Recommended Posts

hello all ; >
i am new with php and and i searched a lot of things online and i have come here for help... i have taken a basic course on open source programming and it included a unit on PHP but it had nothing to do with e-mails.

i have been reading some things and i have no idea how to set up an e-mail server etc..

basically i am making a webpage for a friend's wedding so the people can RSVP through the website..

i made the form using Macromedia Flash and i have set the SEND button to send to my email.php and used POST to link it to my PHP file that has all the coding..

here is my php code..


$sendTo = "[email protected]";
$subject = "My Flash site reply";


$headers = "From: " . $_POST["firstName"] ." ". $_POST["lastname"] . "<" . $_POST["email"] .">\r\n";

$headers .= "Reply-To: " . $_POST["email"] . "\r\n";

$headers .= "Return-path: " . $_POST["email"];

$message = $_POST["message"];

mail($sendTo, $subject, $message, $headers);

?>

so i am using the yahoo.com mail server...

now i was reading about having to have a mail server of some sort and set up the php.ini?

it would be of GREAT help if someone can explain what the next step would be in plain english , because i read a lot of tutorials and post and it;s all in terms i don;t know, so i can get this form working ; >

thank you
Link to comment
https://forums.phpfreaks.com/topic/33401-form-sending-to-e-mail/
Share on other sites

If you are going to test this script on your local PC you will need to change the smtp setting in your php.ini to point to your ISP mail server (smtp.your_isp.com or whatever). If you already have some hosting setup test the script there, you will probably find it will work as expected.

:)
[quote author=matto link=topic=121576.msg500151#msg500151 date=1168298842]
If you are going to test this script on your local PC you will need to change the smtp setting in your php.ini to point to your ISP mail server (smtp.your_isp.com or whatever). If you already have some hosting setup test the script there, you will probably find it will work as expected.

:)
[/quote]

how do i change my smtp setting in my php.ini ?? i do not have a php editor.. my komodo 3.5 is not set up for PHP..

yah i tested it online..

i have space on my school server to host stuff temporarily..

i don't know if my school server has the ability for e-mail to work but when i clicked SEND .. it says THANK YOU but i do not receive an e-mail

here is the link to the test swf file

http://munro.humber.ca/~rcsn0009/site/formtest.swf
Just a quick follow up. If you are looking at testing more php mail on your PC you should be able to edit your php.ini file with any text editor (windows notepad etc). If you make any changes to your ini file just remember you will need to restart your web server to benefit from your changes.

;)

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.