Beefy Boxes and Bandwidth Generously Provided by pair Networks
Don't ask to ask, just ask
 
PerlMonks  

Re^5: CGI program

by moritz (Cardinal)
on Sep 23, 2009 at 19:00 UTC ( [id://797055]=note: print w/replies, xml ) Need Help??


in reply to Re^4: CGI program
in thread CGI program

The web server has a configuration file which tells it if a certain program is to be run as a CGI script or not. If the answer is "yes", the web server sets up all these variables before calling the script.
For example, will QUERY_STRING have different name before its named by web server ?

The web server likely has an internal data structure that holds that information - it doesn't matter how that thing is called.

Perl 6 - links to (nearly) everything that is Perl 6.

Replies are listed 'Best First'.
Re^6: CGI program
by manishrathi (Beadle) on Sep 24, 2009 at 16:08 UTC
    So when I create a Perl script with the "use CGI" in the script and save this file as say "trialOfCGI.pl", will it be automatically marked as CGI script ? Or do we have to manually mark the script as CGI ? If we save the file with .cgi extension e.g. "trialOfCGI.cgi", does it mark the script as CGI script ? If thats the case, then every CGI script has to be marked with cgi extension only ? When do we use cgi extension for a script ? In the cgi-bin dir, can we put a script without .cgi extension ?
      The webserver controls all that. If it wants .vagina, you need .vagina :)

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others meditating upon the Monastery: (5)
As of 2024-04-24 07:46 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found