in reply to perl website - htaccess

Hi,

Please create a file named startup.pl (any other name will do, but this is the convention) and add your "use" lines inside it ( within a BEGIN block if you want to add more code) Then add the apache directive

PerlRequire "/<your directory path>/startup.pl"
and restart the server.

update:
Your startup.pl should look like

#!/usr/bin/perl BEGIN{ use lib '/home/lsrfm/perllib'; use lib '/home/lsrfm/webs/qwer.lsrfm.com/perllib'; use LSRfm::Application::CMS; } 1; # return true as usual :)

Cheers !

--VC



There are three sides to any argument.....
your side, my side and the right side.

Replies are listed 'Best First'.
Re^2: perl website - htaccess
by barrycarlyon (Beadle) on Sep 03, 2007 at 18:06 UTC

    Its not my server and i dont have that kinda access

    can i out perl require in .htaccess?

    (wanders off to google to look)

    Barry Carlyon barry@barrycarlyon.co.uk

      Hi,

      You can keep the file in your cgi-bin directory. I think you can add the directives in htaccess file. Only condition is that it should be of scope outside <DIRECTORY> or <FILE> tags. see Perl Directives & allowed locations

      Cheers !

      --VC



      There are three sides to any argument.....
      your side, my side and the right side.

        The perlrequire doesnt seem to work.... i just get a white page... nothing in the error log

        Barry Carlyon barry@barrycarlyon.co.uk