greatcanada
Programmer
Hello everyone,
I have an idea as to how to send both a text and html version of an email that I would like to broadcast.
Reference:
The problem is that email application do not seem to pick up the sections that I've divided using the boundary.
Here is a simplified version of my code:
<cfmail to="whoever@whoever.com" from="whoever@whoever.com" subject="Test Mime
MIME-Version: 1.0
Content-type: multipart/mixed;
boundary=gc0p4Jq0M2Yt08jU534c0p">
hello there
--gc0p4Jq0M2Yt08jU534c0p
Content-type: text/plain; charset=US-ASCII
Content-Transfer-Encoding: 7bit
Plain text here only!
--gc0p4Jq0M2Yt08jU534c0p
Content-type: text/html; charset=us-ascii
Content-Transfer-Encoding: 7bit
<html>
<head>
<title>Hello test!</title>
</head>
<body bgcolor="F0F0F0" text="000000" link="000099" alink="800000" vlink="000066">
blah... blah ... <b>blah</b>..
</body>
</body>
</html>
--gc0p4Jq0M2Yt08jU534c0p
</cfmail>
Results:
Using my outlook, its only picking up the text version because it is the first one in the order. It should be an html page because it is an html capable page viewer.
So how can make it so that, if a user's email application can read html-based email, it will use that "section"?
I understand the MIME concept but just can't get it to work in CF?
Any ideas? Thank you.
Christopher
I have an idea as to how to send both a text and html version of an email that I would like to broadcast.
Reference:
The problem is that email application do not seem to pick up the sections that I've divided using the boundary.
Here is a simplified version of my code:
<cfmail to="whoever@whoever.com" from="whoever@whoever.com" subject="Test Mime
MIME-Version: 1.0
Content-type: multipart/mixed;
boundary=gc0p4Jq0M2Yt08jU534c0p">
hello there
--gc0p4Jq0M2Yt08jU534c0p
Content-type: text/plain; charset=US-ASCII
Content-Transfer-Encoding: 7bit
Plain text here only!
--gc0p4Jq0M2Yt08jU534c0p
Content-type: text/html; charset=us-ascii
Content-Transfer-Encoding: 7bit
<html>
<head>
<title>Hello test!</title>
</head>
<body bgcolor="F0F0F0" text="000000" link="000099" alink="800000" vlink="000066">
blah... blah ... <b>blah</b>..
</body>
</body>
</html>
--gc0p4Jq0M2Yt08jU534c0p
</cfmail>
Results:
Using my outlook, its only picking up the text version because it is the first one in the order. It should be an html page because it is an html capable page viewer.
So how can make it so that, if a user's email application can read html-based email, it will use that "section"?
I understand the MIME concept but just can't get it to work in CF?
Any ideas? Thank you.
Christopher