CGI/Perl Guide | Learning Center | Forums | Advertise | Login
Site Search: in

  Main Index MAIN
INDEX
Search Posts SEARCH
POSTS
Who's Online WHO'S
ONLINE
Log in LOG
IN

Home: Perl Programming Help: Beginner:
i need to alter this script

 



rikmartin
Deleted

Mar 26, 2001, 1:54 PM

Post #1 of 2 (217 views)
i need to alter this script Can't Post

i had an email script running however the module no longer exists in the default place i an am not able to get it put back, i need to put the module in my own cgi-bin directory, which i have done but how do i get the script to find it as it only trys to look in the original default directory, the module is NET::POP3 and the file is called POP3.pm

see the following top few lines

#!/usr/bin/perl

# ****** USE THIS STUFF *******
#use diagnostics;
use CGI; my $amail=CGI->new(); # THIS IS THE MAIN CGI OBJECT
#use CGI::Pretty; my $amail=CGI->new(); # THIS IS THE MAIN CGI OBJECT
use Net::POP3;
use Time::Local;
use Amail_common;
use Fcntl qw(:DEFAULT :flock);

I am new to perl and this is confusing me

Many thanks in advance

R Martin



unknownSym
stranger

Mar 27, 2001, 10:06 AM

Post #2 of 2 (207 views)
Re: i need to alter this script [In reply to] Can't Post

If you're going to put the module in you cgi-bin directory do the following:
1. Create a directory called 'Net' in you cgi-bin directory and place the POP3.pm file in that directory.
2. Now in your script file place the following line just under you "use diagnostics" line:
"use lib qw(/path/to/cgi-bin);"

You should now be able to use the Net::POP3 module.

If you have problems read the following article on installing perl modules in non-default directories:
http://forums.perlguru.com/showthreaded.pl?Board=Forum8&Number=7660&Main=7654

--unknownSym


 
 


Search for (options) Powered by Gossamer Forum v.1.2.0

Web Applications & Managed Hosting Powered by Gossamer Threads
Visit our Mailing List Archives