html formatted emails

i am having diffuculty sending html formatted emails, The content of the email comes from a html form, I paste in the enitire code for a webpage, chnage all " to ' and write the full path name to the images on my server
( eg. <img src=''> )

whats happening is the the images are not displaying, and all the html formatting is messed up... this is my code

$msg = "$message\n";

$to = "$email";
$subject = "Newsletter";

$mailheaders = "From:\n";
$mailheaders .= "Reply-To:";
$mailheaders .= "MIME-Version: 1.0\r\n";
$mailheaders .= "Content-type: text/html; charset=iso-2022-jp\r\n";


seemd weird, i though this code used to work, I've used it on other servers..

Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

$mailheaders = "From:\n";
$mailheaders .= "Reply-To:";
$mailheaders .= "MIME-Version: 1.0\r\n";
$mailheaders .= "Content-type: text/html; charset=iso-2022-jp\r\n";

I think you probably have a typo. Aren't headers supposed to be seperated by \r\n(no matter what OS you are using), Shouldn't there also be a newline, after the Reply-To header?
jblayneyAuthor Commented:
didnt help at all, the emails i am testing with are outlook express for macintosh,, yahoo and hotmail wont even receive the email
jblayneyAuthor Commented:
i just doscovered something, if i hard code the image into the message

$msg = "$message\n";
$msg .= "<img src ='whatever'>";

it works, but not if i send it from the form, the images are going to change, so i need them to come from the form, as well as links
C++ 11 Fundamentals

This course will introduce you to C++ 11 and teach you about syntax fundamentals.

jblayneyAuthor Commented:
i have a thought.....(sometimes happens)

$message is coming directly from the form into the $msg, should I catch it first and convert it to a usable form...
take a look a http:\\ the program can send html emails.
There must be something wrong with the html in your message if this is happening. Try echoing it out to debug it.
jblayneyAuthor Commented:
actaully i fugured it out.. i had to add stripslashes funstion to receive it properly... tx for the help

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
Plz close the question since you've discovered your answer. Thx.
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today

From novice to tech pro — start learning today.