http://qs321.pair.com?node_id=616336


in reply to Problem with Mime::lite and .doc files

The Type is only a hint to the receiving MUA. You can specify foo/bar and everything is fine, as long as the receiver knows what to do with objects of that type.

You didn't specify your error symptoms beyond (…nothing happens…), but I would guess your MUA does not show you the generated "inline" Word document, which is an understandable decision.

You might try to attach the document by

$msg->attach(Type =>'application/msword', Path =>'test.doc', Disposition => 'attachment', );

instead.

At least the generated mail looks good to my eyes. Though it is a bit weird to send the main text base64-coded (i. e. BINARY). I would rather use Type => 'TEXT' there.