contra10 Posted February 21, 2009 Share Posted February 21, 2009 im testing my email using postcast server free... im using this code <?php $headers = "From:[email protected]\r\n". "To:$email". "MIME-Version: 1.0\r\n" . "Content-Type: multipart/mixed;\r\n"; $body="$username has added you as a friend"; mail("[email protected]","Friend Request",$body, $headers); ?> the "to" and "subject" shows but i cant view the body and i can't view the from Link to comment https://forums.phpfreaks.com/topic/146201-testing-email/ Share on other sites More sharing options...
Stooney Posted February 21, 2009 Share Posted February 21, 2009 Try <?php $headers = "From: [email protected]\r\n". "To: $email". "MIME-Version: 1.0\r\n" . "Content-Type: multipart/mixed;\r\n"; $body="$username has added you as a friend"; mail("[email protected]","Friend Request",$body, $headers); ?> Link to comment https://forums.phpfreaks.com/topic/146201-testing-email/#findComment-767567 Share on other sites More sharing options...
contra10 Posted February 21, 2009 Author Share Posted February 21, 2009 ok that worked for "from" <?php <?php $headers = "From: [email protected]\r\n". "To: $email". "MIME-Version: 1.0\r\n" . "Content-Type: multipart/mixed;\r\n"; $body="$username has added you as a friend"; mail("[email protected]","Friend Request",$body, $headers); ?> how about body Link to comment https://forums.phpfreaks.com/topic/146201-testing-email/#findComment-767571 Share on other sites More sharing options...
contra10 Posted February 21, 2009 Author Share Posted February 21, 2009 i tried taking it out of $body variable and just leaving it in quotes but that didn;t work Link to comment https://forums.phpfreaks.com/topic/146201-testing-email/#findComment-767586 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.