Jump to content


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


PHP Form Help

Recommended Posts

Hey i have been busting for some help.

I was looking for a PHP script. Its like a emailer script, basically i want to have a script where someone comes along fills in a feilds then submits it. I then i whould like the script to send a copy of what has been filled out in the fields to my email then i would like the script to send a seperate email to the person who subbmitted the form.

so something basically like


Then as i said a email sent to me on what they filled out, then a seperate emial sent to the person who filled this out.
I am a little familar with PHP I know abit about it but just dont know the syntax to make this work its really got me stunned how to do this ? any ideas or even scripts would be gratefull. The person who can help me do this i will pay through paypal a price will be discussed.

Thanks again if you guys wish to talk to me MSN me jurasiprize@hotmail.com

Share this post

Link to post
Share on other sites
welcome to the forums! hope you find lots of great help here.

if you simply want 2 emails sent out, then, do something like this:
if (isset($_POST['submit'])) {
  // send first email:
  $to = 'you@yourdomain.com';
  $from = $_POST['email'];
  $subject = "Comment from $_POST[name]\n";
  $message = "You have received a message from your contact form:\n\n" .
      "Name: $_POST[name]\n\n" .
  mail($to, $subject, $message, "From: $from\r\n Reply-To: $from\r\n");

  // send confirmation email
  $to = $_POST['email'];
  $from = 'you@yourdomain.com';
  $subject = "Thanks for your comments";
  $message = "Thank you for taking the time to send me your comments!";
  mail($to, $subject, $message, "From: $from\r\n Reply-To: $from\r\n");

<form name='comments' method='post' action=''>
Name: <input type='text' name='name' /><br />
Email: <input type='text' name='email' /><br />
Comment: <textarea name='comment' cols='60' rows='12'></textarea>

of course, for the final version of this, you'd want to run some validation to make sure they enter a valid email address, etc.

hope this helps

Share this post

Link to post
Share on other sites
Thanks allot i still do need some help and as i said, i will pay you through paypal. If you could add my msn it would be great man.

Knowledge is time time is money.

Share this post

Link to post
Share on other sites


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.