Contact form
-
Currently I am hosting a clients webpage on the free plan of Mezoka. They allow php 5, but not phpmail (), is there a way of that I can let users email the client at their Gmail account through the website? I read on the Mezoka forum that you could use Gmail as am smtp. I've included my php and html form. I've had a few people tell me about php mailers and php mailer class. Not too sure how to go about implementing the contact form. What I did and thought would work, doesnt, I keep getting the error message that I have in my php. I've tried using Gmail which is where the client has their email account with and my personal yahoo address, and error messages.
Contact
"; $to = "starr@yahoo.com";
$from = " ";
$headers = "MIME-Version: 1.0\r\n";
$headers.= "Content-type: text/html; charset=iso-8859-1\r\n";
$headers.= "From: $from\r\n";
$mail_body = "Hello World";if (mail($to,"Mail", $mail\_body,$headers)) { echo " Thank you! - Your feedback has been sent! "; } else { echo " Thank you! - We could not send email. Please try later! "; }
?>
?>
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Contact</title></head>
<body>* [](http://www.facebook.com/) * [](http://www.twitter.com/)
-
Currently I am hosting a clients webpage on the free plan of Mezoka. They allow php 5, but not phpmail (), is there a way of that I can let users email the client at their Gmail account through the website? I read on the Mezoka forum that you could use Gmail as am smtp. I've included my php and html form. I've had a few people tell me about php mailers and php mailer class. Not too sure how to go about implementing the contact form. What I did and thought would work, doesnt, I keep getting the error message that I have in my php. I've tried using Gmail which is where the client has their email account with and my personal yahoo address, and error messages.
Contact
"; $to = "starr@yahoo.com";
$from = " ";
$headers = "MIME-Version: 1.0\r\n";
$headers.= "Content-type: text/html; charset=iso-8859-1\r\n";
$headers.= "From: $from\r\n";
$mail_body = "Hello World";if (mail($to,"Mail", $mail\_body,$headers)) { echo " Thank you! - Your feedback has been sent! "; } else { echo " Thank you! - We could not send email. Please try later! "; }
?>
?>
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Contact</title></head>
<body>* [](http://www.facebook.com/) * [](http://www.twitter.com/)
Check the link out at the bottom, it's a PHP mailer library that should make it much easier to do what you're trying to accomplish. If you're still having trouble, just remember, Google is your friend! http://bit.ly/p9DUif[^] Literally every result on that first page should walk/help you through it. http://swiftmailer.org/[^]
-
Currently I am hosting a clients webpage on the free plan of Mezoka. They allow php 5, but not phpmail (), is there a way of that I can let users email the client at their Gmail account through the website? I read on the Mezoka forum that you could use Gmail as am smtp. I've included my php and html form. I've had a few people tell me about php mailers and php mailer class. Not too sure how to go about implementing the contact form. What I did and thought would work, doesnt, I keep getting the error message that I have in my php. I've tried using Gmail which is where the client has their email account with and my personal yahoo address, and error messages.
Contact
"; $to = "starr@yahoo.com";
$from = " ";
$headers = "MIME-Version: 1.0\r\n";
$headers.= "Content-type: text/html; charset=iso-8859-1\r\n";
$headers.= "From: $from\r\n";
$mail_body = "Hello World";if (mail($to,"Mail", $mail\_body,$headers)) { echo " Thank you! - Your feedback has been sent! "; } else { echo " Thank you! - We could not send email. Please try later! "; }
?>
?>
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Contact</title></head>
<body>* [](http://www.facebook.com/) * [](http://www.twitter.com/)
You can check out PhpClasses for a Php Smtp Library that communicates to Google Mail via network functions.
Vasudevan Deepak Kumar Personal Homepage
Tech Gossips
The woods are lovely, dark and deep, But I have promises to keep, And miles to go before I sleep, And miles to go before I sleep!