Beefy Boxes and Bandwidth Generously Provided by pair Networks RobOMonk
go ahead... be a heretic
 
PerlMonks  

Re: How was my script launched?

by gaal (Parson)
on Jul 20, 2008 at 17:25 UTC ( #698923=note: print w/ replies, xml ) Need Help??


in reply to How was my script launched?

It's not the socket that invokes your script, it's a web server or some other server process. Perhaps you can configure them to pass a command line argument. In the case of CGI, you typically have cgi environment variables set up for you that you might try to detect.

In many cases, you can replace "use" with runtime "require Foo; Foo->import(ARGS)", which you can of course predicate on the method you detected you were called with. Best.pm also has some goodies for conditional module loading that may suit your needs.


Comment on Re: How was my script launched?
Select or Download Code

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://698923]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others contemplating the Monastery: (6)
As of 2014-04-20 12:47 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    April first is:







    Results (485 votes), past polls