william wrote: > Hello, I just know that I can't have a startup script, but how can I > create an object in the startup script and then used that variable > object in child modperl script ? Thanks.
It depends on your needs. If you need a read-only object that won't change during the whole time the server is running (like a configuration object) then it's pretty straight forward. You just need to use a namespaced object that you access in your application. # in startup.pl My::Object->create(); # in your application My::Object->get(); # in My/Object.pl my $obj; sub create { $obj = ...; # do something to initialize } sub get { return $obj; } If your needs are more complicated then it does become more complicated :) -- Michael Peters Plus Three, LP