Question:
How o I get a PHP Form mail script to work?
Desiree Gowell
2007-02-11 14:20:18 UTC
I have recently created a PHP form mailer for my webpage. Useing the mail() function. The problem is that it wont send the email to my account. SO instead I have to use a bravenet.com script.

I was wondering whether somone could tell me how to get a PHP script to work, when my server runs other PHP scripts as well
Four answers:
injanier
2007-02-11 14:31:11 UTC
The PHP mail() function has to be enabled at the server in order to work. Check with your ISP to see if the function works on your webhosting account, or if they have something else you can use. Some ISPs disable or restrict mail sending capabilities to prevent misuse by spammers.
Atif Majid
2007-02-13 02:07:16 UTC
For mail() function to work, SMTP must be configured on the server. If SMTP is running, use

mail($strTo, $strSubject, $strMessage, "From: From email address");



If you want to send HTML mails, or the mails containing attachment, you will have to alter the 4th parameter in mail function.
anonymous
2016-11-03 08:28:27 UTC
there are 2 minor issues. interior the HTML section get rid of enctype="text cloth/common" in touch.Hypertext Preprocessor you used $message = $_POST['message']; and on the HTML style you used