in reply to Re: MIME::Lite question
in thread MIME::Lite question

use MIME::Lite; #### Start with a simple text message: $msg = MIME::Lite->new( From => 'francis@suresoft.info', To => 'thomas.g@suresoft.info', Subject => 'A message with 2 parts...', Type => 'TEXT', Data => "Here's the GIF file you wanted", ); $msg->send();

Actually this is the first time i am using this module, i am working in windows 2000 and outlook express mail. For outgoing mails in our company we are using smtp server with ip address(192.168.1.5),and for incoming mail we are using pop3 server with same ip address. The name of the server is Intranet.suresoft.info.

Replies are listed 'Best First'.
Re^3: MIME::Lite question
by kwaping (Priest) on Jun 15, 2005 at 15:25 UTC
    Thank you! So that's the entire program? After reading through the docs for MIME::Lite, you might want to specify MIME::Lite->send("smtp"); at the beginning of your program, after the use line.

      Thanks for your reply, i included that line after use, i am getting the following error.

      Can't locate object method "send_by_intranet.suresoft.info" via packag +e "MIME ::Lite" at C:/Perl/site/lib/MIME/Lite.pm line .

      Also i changed the last line to $msg->send("intranet.suresoft.info")

        Try this instead of the line I previously recommended:
        MIME::Lite->send('smtp', 'send_by_intranet.suresoft.info', Timeout=>60 +);
        (Adapted from the MIME::Lite documentation.)
        Then go back to just $msg->send; . This is basically what jbrugger said in the first post, modified for the specifics of your system and without the if() statement.