Solved

pelase relate PERL and CGI

Posted on 2004-08-02
4
460 Views
Last Modified: 2010-04-17
I need to learn PERL. i got perl.org and perl.com
pelase can you relate PERL and CGI. how are they related and how are they different...... furthermore, i know c, c++, vc++, java, vb, asp, html, javascript, .... any relation of PERL with there. what abt PHP where does PHP stand when we talk abt PERL and CGI.

pelase help
rs
0
Comment
Question by:ravi-shekhar
4 Comments
 
LVL 1

Accepted Solution

by:
rpz earned 25 total points
ID: 11692868
Perl (Practical Extraction and Report Language) is an interpreted scripting language. Perl is a very powerful language that has borrowed from a variety of different programming languages. This makes Perl very powerful, but also quite hard to learn and very hard to read. It can be used for anything from shell scripts to server-side web applications. A good interpreter for Windows is ActiveState (http://www.activestate.com/).
CGI stands for Common Gateway Interface, and is a way for the web server to communicate with programs on the server (the programs can be scripts written in Perl, as well as other languages). CGI was created in the early days of WWW and works by executing a certain program and setting up some environment variables specific to the HTTP request. Microsoft IIS uses a different approach for server-side scripting called ISAPI, where each scripting language is a special DLL instead of a generic program.
CGI has nothing directly to do with Perl, other than that CGI scripts were traditionally written in Perl.
PHP (http://www.php.net) is another scripting language, one that is focused on web applications (although it could be used for other scripts as well). It is similar in functionality to ASP, but instead of being based on Visual Basic, PHP is not entirely unlike C++.
Both PHP and Perl can be used with the most popular Web servers like Apache and IIS. One good way of experimenting with Perl or PHP is to download a small web server to your desktop computer, for example this open-source java-based app (http://www.javascript.nu/xerver/).
0
 
LVL 8

Assisted Solution

by:adg080898
adg080898 earned 25 total points
ID: 11698585
Before CGI, the only thing webservers did was send files (web pages) on request. There was no ability to run a program to generate a response.

CGI is a way for the webserver to run a given program and send IT'S OUTPUT as the page. Anything can run can be run by CGI, for example, a compiled C or C++ program, a shell script, perl, etc..., or any language for which there is an interpreter available.

CGI defines a standard way for the launched program to get information about the request. The program writes its output to standard output. The webserver sends the output of the program as the response to the client requesting the page.
0

Featured Post

Better Security Awareness With Threat Intelligence

See how one of the leading financial services organizations uses Recorded Future as part of a holistic threat intelligence program to promote security awareness and proactively and efficiently identify threats.

Join & Write a Comment

Suggested Solutions

Go is an acronym of golang, is a programming language developed Google in 2007. Go is a new language that is mostly in the C family, with significant input from Pascal/Modula/Oberon family. Hence Go arisen as low-level language with fast compilation…
A short article about problems I had with the new location API and permissions in Marshmallow
Viewers will learn how to properly install Eclipse with the necessary JDK, and will take a look at an introductory Java program. Download Eclipse installation zip file: Extract files from zip file: Download and install JDK 8: Open Eclipse and …
In this fourth video of the Xpdf series, we discuss and demonstrate the PDFinfo utility, which retrieves the contents of a PDF's Info Dictionary, as well as some other information, including the page count. We show how to isolate the page count in a…

760 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

20 Experts available now in Live!

Get 1:1 Help Now