PHP contact form problems - Webmaster Forums - Webmaster forum for HTML, PHP, ASP, CSS and more
Webmaster Forums - Webmaster forum for HTML, PHP, ASP, CSS and more
Go Back   Webmaster Forums - Webmaster forum for HTML, PHP, ASP, CSS and more > Webmaster Tech > Programming > PHP Development

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old 01-18-2011, 06:25 AM   #1 (permalink)
Junior Member
 
Join Date: Jan 2011
Posts: 1
Unhappy PHP contact form problems

ok so i think i have the codeing correct but im having trouble actually getting an email to the specified account.

i have tested it with another account which uses hotmail and it works fine but when i change the email address to one on the Gmail servers it doesnt actually get there. if your asking if i have spelt the email address, yes i have and i have checked many times. please help to figure out what to do as i am completely lost.

<?php

/* subject and email variables */

$emailSubject = 'Contact Form From Rapid Action Website';
$webMaster = 'info@rapidaction.com.au';

$Email = $_POST['Email'];
$Name = $_POST['Name'];
$Phone = $_POST['Phone'];
$Event = $_POST['Event'];
$Comments = $_POST['Comments'];

$body = <<<EOD
<br><hr><br>
Email: $Email <br>
Name: $Name <br>
Phone: $Phone <br>
Type of Event: $Event <br>
Comments: $Comments <br>
EOD;

$headers = "From: $Email\r\n";
$headers .= "Content-type: text/html\r\n";
$success = mail($webMaster, $emailSubject, $body, $headers);

$theResults = <<<EOD

EOD;
echo "$theResults";

?>
ethan698 is offline   Reply With Quote
Sponsored Links
Old 03-08-2011, 09:49 PM   #2 (permalink)
Junior Member
 
Join Date: Mar 2011
Posts: 1
Default Re: PHP contact form problems

The problem may have something to do with your envelope sender in the php.ini on the server. I believe Google is a little more strict about accepting messages from e-mail addresses with conflicting header/from information. So you may need to take that header info out and just put the e-mail that someone has submitted in the body of your e-mail.

Hopefully this helps!
krgriffin is offline   Reply With Quote
Old 03-21-2011, 07:06 AM   #3 (permalink)
Junior Member
 
Join Date: Mar 2011
Posts: 7
Default Re: PHP contact form problems

Thanks for sharing guys....
n.williams0440 is offline   Reply With Quote
Old 04-08-2011, 12:17 PM   #4 (permalink)
Regular User
 
Join Date: Apr 2011
Posts: 115
Default Re: PHP contact form problems

This links gives you a detailed view
chunnilal is offline   Reply With Quote
Old 05-16-2012, 06:09 AM   #5 (permalink)
Regular User
 
Join Date: May 2012
Location: usa
Posts: 18
Default Re: PHP contact form problems

you should set up again with your gmail server which you changed
. maybe incorrect smtp port
y8games2012 is offline   Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



» Sponsors

» Links

» Affiliates
Web Hosting
Online Backup Reviews
Marketing Find
Merchant Select
SiteMap Builder
Host Compare

» Links

» Sports Network
Paintball Forum
Football Forum
Hockey Forum
Golf Forum
Boxing Forum
Lacrosse Forum
Baseball Forum
SnowBoarding Forum
Soccer Forum
MMA Forum


All times are GMT -4. The time now is 04:29 PM.


Powered by vBulletin® Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.3.2
Webmaster Forums
Web Hosting | Chicago Web Hosting | Web Hosting