The stupid question is the question not asked | |
PerlMonks |
Re: Sending Inline Images in e-mail with Mail::Sender (or getting them to print in Outlook)by bbfu (Curate) |
on Mar 04, 2003 at 03:11 UTC ( [id://240223]=note: print w/replies, xml ) | Need Help?? |
Well, a couple minor things. Firstly, you didn't include the HTML file you use (file.html), which can make a difference. The problem might lie there. Specifically, with the syntax of the src="cid:img" references. Also, you're manually embedding one header (Content-ID) within another. It should work the way you have it, but it is "more correct" to use the content_id parameter to Attach (see code below). And though I'm sure it doesn't make any difference to the problem, you're giving the wrong content-type for the jpeg ('image/gif' instead of 'image/jpeg'). Here is your code, slightly modified and formatted, and the html file I used. It seems to work for me, though I don't actually have Outlook to test it with. As far as I can tell, this is "correct", though, so it should work the same with Outlook as with my email client (PocoMail). If this doesn't work with Outlook, then I can only assume the problem is with Outlook and printing inline images. Perhaps you could try it in another mail client to see if it's an Outlook-specific issue. Update: There is a Knowledge Base Article (#287768) about this issue. You should check that to see if it's the same problem. The code:
The file.html:
bbfu
In Section
Seekers of Perl Wisdom
|
|