I never really understood: what is CGI?

irstaxgh

New Member
CGI is a Comman Gateway Interface. As the name says, it is a "common" gateway interface for everything. It is so trivial and naive from the name. I feel that I understood this and I felt this every time I encountered this word. But frankly, I didn't. I'm still confused. I am a PHP programmer. I did lot of web development. user (client) request for page ---> webserver(->embedded PHP interpreter) ----> Server side(PHP) Script ---> MySQL Server.Now say my PHP Script can fetch results from MySQL Server && MATLAB Server && Some other server.So, now PHP Script is the CGI? because its interface for the between webserver & All other servers? I don't know. Sometimes they call CGI, a technology & othertimes they call CGI a program or someother server.
  • What exactly is CGI?
  • Whats the big deal with \[code\]/cgi-bin/*.cgi\[/code\]? Whats up with this? I don't know what is this \[code\]cgi-bin\[/code\] directory on the server for. I don't know why they have *.cgi extensions.
  • Why does Perl always comes in the way. CGI & Perl (language). I also don't know whats up with these two. Almost all the time I keep hearing these two in combination "CGI & Perl". This book is another great example http://rads.stackoverflow.com/amzn/click/1565924193
 
Back
Top