473,756 Members | 6,482 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Mail::Sender problem

Hi there,

I'm trying to create an html mail with embedded pictures in it. I run perl
on Windows and Red Hat but I cannot get your module (Mail::Sender) to work.
I'm just trying to run the examples. Below this message you'll find the perl
example I'm using and the header of the e-mail. What am I doing wrong?
Regards

Merijn Boom

Perl code:

use strict;

use Mail::Sender;

my $recipients = 'm*****@con-x-com.com';

eval {

(new Mail::Sender)

->OpenMultipart( {

to => 'mailto',

FROM => 'mailfrom',

subject => 'Alternatives with images',

# debug => 'c:\temp\zkMail Flow.log',

multipart => 'related',

smtp => '127.0.0.1',

})

->Part({ctype => 'multipart/alternative'})

->Part({ ctype => 'text/plain', disposition
=> 'NONE', msg => 'A long mail message.'})

->Part({ctype => 'text/html', disposition =>
'NONE', msg => '<html><body><h 1>A long</h1><p align=center>ma il message.<img
src="cid:img1"> </p></body></html>'})

->EndPart("multi part/alternative")

->Attach({

description => 'ed\'s GIF',

ctype => 'image/GIF',

encoding => 'base64',

disposition => "inline;
filename=\"apac he_pb.gif\";\r\ nContent-ID: <img1>",

file => 'apache_pb.gif'

})

->Close();

} or print "Error sending mail: $Mail::Sender:: Error\n";

My Header:

To: *

From: *

Subject: Alternatives with images

Date: Sat, 21 Feb 2004 09:57:55 +0100

X-Mailer: Perl script "Perl-1.pl"

using Mail::Sender 0.8.10 by Jenda Krynicky, Czechlands

running on medusa (10.1.0.133)

under account "m.boom"

Message-ID: <20040221_08575 5_005175.*>

MIME-Version: 1.0

Content-type: multipart/related;

boundary="Messa ge-Boundary-by-Mail-Sender-1077353872"

Return-Path: *
X-OriginalArrival Time: 21 Feb 2004 08:58:38.0243 (UTC)
FILETIME=[E52FC730:01C3F8 58]

--Message-Boundary-by-Mail-Sender-1077353872

Content-Type: multipart/alternative;
boundary="Part-Message-Boundary-by-Mail-Sender-1077353872_2"

--Part-Message-Boundary-by-Mail-Sender-1077353872_2

Content-type: text/plain

Content-transfer-encoding: 7BIT

--Part-Message-Boundary-by-Mail-Sender-1077353872_2

Content-type: image/GIF; name="apache_pb .gif"

Content-description: ed's GIF

Content-transfer-encoding: base64

Content-disposition: inline; filename="apach e_pb.gif";

Content-ID: <img1>

--Part-Message-Boundary-by-Mail-Sender-1077353872_2--

--Message-Boundary-by-Mail-Sender-1077353872-

My Message:

A long mail message.--Part-Message-Boundary-by-Mail-Sender-1077353872_2

Content-type: text/html

Content-transfer-encoding: 7BIT

<html><body><h1 >A long</h1><p align=center>ma il message.<img
src="cid:img1"> </p></body></html>--Part-Message-Boundary-by-Mail-Sender-1077
353872_2--


Jul 19 '05 #1
0 3294

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

5
3107
by: Bruce W...1 | last post by:
In my effort to learn PHP I'm playing with some simple email scripts. They worked a few days ago but they stopped working. The only thing I've done to this Windows 2000 PC in this time was a Windows Update which I do regularly. The only part of this update that might be related was an IE 6 update. So I uninstalled and reinstaled PHP 4.3.3. The mail server setting is correct in the php.ini file. But email is still not being sent. ...
6
2054
by: Mike the Canadian | last post by:
I am having a very strange problem sending email with php. I have two domains. I can send an email to one domain using php but not the other. If I put both email addresses in the mail command only the one email will arrive. I can send emails the traditional way to the problem domain and they arrive fine. Is there anything that might explain this? _______ Free Windows Clipboard Utility http://www.clipboardmagic.com/
6
1601
by: chris | last post by:
My code <?php $name = "freddie"; $message.="Hi Joe,\n"; $message.="\t $name has Filled out the form on the Website,\n"; $message.="The information from the form is listed below:\n"; $message.="more info\n"; $message.="more info\n";
1
1010
by: vandanasridhar | last post by:
Hi, Vandana Writing. I saw a project on freelancer's Site. they want a project that accepts an email id and a contents and can able to send Email. Will anyone Guide Me how to crete a mail sender. I have already done ofline database projects.
2
3012
by: Mitul | last post by:
Hello Friend, I am having very strange problem with mail function. As I have to implement Newsletter things in my hebrew site. I have implemented everything but having problem with subject line is not display on any one of mail services. Mail display body part properly in hebrew but subject line having problem its display junk character in subject. I am not able figure out what is the actual problem. Please help me for this matter.
1
2514
by: mobs6 | last post by:
This error messages always shown up, after i filled the registration form Can some body tell me about this problems, ok this is error the message looks like: " sendmail: Can't send mail: Sender domain (yahoo.com) does not belong to user, please use your own domain X-Powered-By: PHP/5.2.0-8+etch3+spbutters1 Content-type: text/html " is it because, the webserver configuration on my webhost? i had already try too use 2 command like: ...
3
2244
rsrinivasan
by: rsrinivasan | last post by:
Hi, When i run the below program to send mail, I hava an error msg like this. What is the problem? javax.mail.SendFailedException: Invalid Addresses; nested exception is: class com.sun.mail.smtp.SMTPAddressFailedException: 550 <mailtovasan@hotpop.com>: Recipient address rejected: Relaying Denied: Authenticate with POP first or contact support@HotPOP.com at com.sun.mail.smtp.SMTPTransport.rcptTo(SMTPTransport.java:1141) at...
0
1215
by: Emmanuel Petit | last post by:
I apologise in advance for my little knowledges in php. I use PHP 5.2.1 Here is an extract of the script which causes me problems. //email of recipient $ea='mister@somesite.com'; //tracking email to the webmaster of the site $dd='webmaster@testsite.com'; mail($dd, 'Activation',$details, 'From: administration@testsite.com');
1
914
by: =?Utf-8?B?VGltb3RoeQ==?= | last post by:
Hi all, who can help me , recently i found a problem from the window mail whic are i am using my own personal mail account and try to using window mail to log in. anywhre i can receive some of the mail from my contact list but cant read it in my inbox. when i recive it can be reciev and show hand incomming mail but while loading fining the mail i cant find in the inbox, Wander kneo who are the pro can help me up on this problem?
0
9462
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
9287
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
9886
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
0
9722
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
1
7259
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
6542
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
5155
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
5318
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
3817
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.