|
Posted by Loki25 on 08/07/07 02:15
On Aug 6, 10:13 pm, alice <al...@fearofdolls.com> wrote:
> Can anyone tell me why this code won't work?
> I've saved it as mail.php, and have a form on a web page with
> action="mail.php" in the html. I've gotten this to work before on
> other pages I've worked on, I can't figure out why it's not working
> today, I must have forgotten something. The thank you page comes up,
> but the mail is not actually delivered.
>
> <?php
> $to="g...@fearofdolls.com";
> $subject="Fear of Dolls web email";
> $email=$_POST["email"];
>
> $message="From Fear of Dolls web email\n";
> $message.="message: ".$message."\n";
>
> $head="From: f...@fearofdolls.com";
> mail($to,$subject,"".$message,$head);
> header("Location:thankyou.html");
> ?>
I can't see any reason why it wouldn't work, are you getting an error
message? if not, then the code is probably working and your problem is
that the SMTP server isn't properly set in your configurations.
Navigation:
[Reply to this message]
|