Hi All,
We have script that including functions in different file.
Can I pre-loading the functions?
Where I put it? into startup.pl?
How I pre-loading it?

Here is my startup.pl

#/usr/bin/perl
use strict;

# only library-type routines should go in this directory

use lib "/var/www/perllib";

# Why below not working???
# make sure we are in a sane environment.
# ENV{GATEWAY_INTERFACE} =~ /^CGI-Perl/ or die "GATEWAY_INTERFACE not Perl!";


use Apache::Registry(); # for things in the "/programs" URL

# Why below not working???
#use Apache::RegistryLoader();
#Apache::RegistryLoader->new->handler("/perl/timeres.pl","/var/www/cgi-bin/timeres.pl");

use CGI (); CGI->compile(':all');
use DBI ();
use DBD::mysql ();

1;

---

Here is my script:

#!/bin/perl
require "cgi_lib.pl";
require "library.pl";

Both are function files.



Thank you,

Ricky

Reply via email to