Ok, I'm using a script that uses LWP::Simple, but the server I'm using it on, doesnt have LWP::Simple installed on it and I don't have the permissions to get to & install anything in the perl/lib directory. So....I made a directory inside my home dir named "lib", and installed it in there. Here's the file tree (I've left out all the non-directory files outside of /lib)
public_html
|
+--cgi-bin
|
+--lib (chmodded 700)
| |
| +--LWP (chmodded 700)
| | |
| | +--Simple.pm (module I need to use, chmodded 755)
| |
| +--HTTP (chmodded 700)
| |
| +--Status.pm (needed by Simple.pm, chmodded 755)
|
+--script.cgi (script I'm accessing via browser, chmodded 755)
now, (these names are case-accurate by the way), in the script I have the following lines:
BEGIN {
use CGI::Carp qw/fatalsToBrowser/;
push(@INC,"/home/user/public_html/cgi-bin/lib");
}
And when I run it via browser, I get:
Can't locate LWP/Simple.pm in @INC (@INC contains: /usr/lib/perl5/5.6.
+0/i386-linux
/usr/lib/perl5/5.6.0 /usr/lib/perl5/site_perl/5.6.0/i386-linux /usr/li
+b/perl5/site_perl/5.6.0
/usr/lib/perl5/site_perl . /home/user/public_html/cgi-bin/lib) at
/home/user/public_html/cgi-bin/script.cgi line 10.
So...whats the problem?
Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
Read Where should I post X? if you're not absolutely sure you're posting in the right place.
Please read these before you post! —
Posts may use any of the Perl Monks Approved HTML tags:
- a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
| |
For: |
|
Use: |
| & | | & |
| < | | < |
| > | | > |
| [ | | [ |
| ] | | ] |
Link using PerlMonks shortcuts! What shortcuts can I use for linking?
See Writeup Formatting Tips and other pages linked from there for more info.