On Mon, Aug 24, 2009 at 1:35 PM, fred <f...@fullmetalpacket.com> wrote:

>  Hey guys,
>
>
>
> I am having a small problem trying to send an email to XMail from a perl
> script, here is the code:
>
>
>
> #!/usr/bin/perl -w
>
> use Net::SMTP;
>
> $smtp = Net::SMTP->new('smtp.mydomain.com', Hello => '
> myserver.mydomain.com', Timeout => 60);
>
> $smtp->mail(myserv...@mydomain.com');
>
> $smtp->to('m...@mydomain.com');
>
> $smtp->data();
>
> $smtp->datasend("From: myserv...@mydomain.com\n");
>
> $smtp->datasend("To: m...@mydomain.com\n");
>
> $smtp->datasend("Subject: Test 1\n");
>
> $smtp->datasend("\n");
>
> $smtp->datasend("A simple test message\n");
>
> $smtp->dataend();
>
> $smtp->quit;
>
>
>
> XMail refuses the email :
>
> "mail"  "mail"  "myserverip"  "2009-08-24 13:31:08"   "
> myserver.mydomain.com" ""      "m...@mydomain.com"  ""      ""
> "SNDR=ESYNTAX"      ""      "0"     ""
>
>
>
>
>
> I understand that @ must be escaped, but how do we tell Perl to send the
> string without the \ ?
>
>
>
> This might be a real noob problem, I don’t know anything about perl.
>
>
>
>
>
> Thanks for help,
>
>
>
> -fred
>
My perl is rusty but it seems to me the @ doesn't need to be escaped b/c
it's encapsulated in quotes.
_______________________________________________
xmail mailing list
xmail@xmailserver.org
http://xmailserver.org/mailman/listinfo/xmail

Reply via email to