Reply to Re: [PHP] PHP error on form

Your name:

Reply:


Posted by "-k." on 11/14/03 11:22

--- Bruce Gilbert <webguync@gmail.com> wrote:
> Hello,
>
> I am trying to get a form to work integrating html
> with PHP.

I see a couple problems...

This line:
> if ($POST['sender_email'] =="") {

Should probably be:
if ($_POST['sender_email'] =="") {
Note the underscore in $_POST


Same thing here:
> if ($POST['message'] =="") {
Should probably be:
> if ($_POST['message'] =="") {


You are getting errors here:
$msg .="Senders Name: $_POST['senders_name']\n";
$msg .="Senders E-MAIL: $_POST['senders_email']\n";
$msg .="Senders Name: $_POST['message']\n\n";
$to ="webguync@gmail.com";
$subject = "There has been a disturbance in the Force";
$mailheaders .="Reply-To: $_POST['sender_email']\n";

You can't echo out the post vars like that these lines need to look like:
$msg .="Senders Name: ".$_POST['senders_name']."\n";
$msg .="Senders E-MAIL: ".$_POST['senders_email']."\n";
$msg .="Senders Name: ".$_POST['message']."\n\n";
$to ="webguync@gmail.com";
$subject = "There has been a disturbance in the Force";
$mailheaders .="Reply-To: ".$_POST['sender_email']."\n";

It sounds like the error on line 58 (whatever that is) is probably something similar to the last
problem.





-k.



____________________________________________________
Start your day with Yahoo! - make it your home page
http://www.yahoo.com/r/hs

[Back to original message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация