![]() ![]() |
| mario |
Jun 14 2012, 01:29 AM
Post
#1
|
|
Group: Members Posts: 4 Joined: 28-March 12 Member No.: 16,812 |
The following is the code i used in my website form.
the form is function as it should but the issue is the email that is received is showing the html code in the inbox insted of rendering the html as it should. site located at: www.yellow.navmana.com CODE <?php $contact= $_REQUEST['email']; $to = $contact; $subject = "Welcome to YellowTrunk.com"; $message1 = <<<EOD <html> <head> <head> <body> <h1 style="color:#3399cc;">Test Mail</h1> </body> </html> EOD; $message2 = "\nThe following person contacted you on the website\n\nEmail : ".$contact; $from = "info@yellowtrunk.com"; $headers = "From: $from"; $headers2 = "From: $contact"; mail($to,$subject,$message1,$headers); mail($from,$subject,$message2,$headers2); ?> Urgent help reqired please ! |
| pandy |
Jun 14 2012, 07:52 AM
Post
#2
|
|
Don't like donuts. Don't do MySpace. ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Group: WDG Moderators Posts: 13,726 Joined: 9-August 06 Member No.: 6 |
You must get a content-type header in there and set it to 'text/html'. Found this example.
http://css-tricks.com/sending-nice-html-email-with-php/ -------------------- |
![]() ![]() |
|
Lo-Fi Version | Time is now: 23rd May 2013 - 04:58 AM |