For most websites, HTML (or XHTML) is the most important thing you'll be serving up.
That HTML might be static (i.e. you write the HTML on your computer, upload it to your server, and it becomes part of your site) or dynamic (i.e. you write a script on your computer, upload it to your server, and the script produces HTML as its output).
You can generally write such scripts in whatever programming language your server will be able to run. Perl is one such language - and I'd expect it to be the first choice of most of the monks here.
You'd typically then supplement the HTML with CSS to control how it looks, and possibly with Javascript to control the behaviour of the pages (e.g. make forms more interactive, add drop-down menus, etc).
What is CGI? It stands for Common Gateway Interface. It's a standardised set of conventions for a web server (such as Apache) to "talk" to a script. It basically involves the server stuffing a bunch of useful information into environment variables, executing the script, reading data from the script's STDOUT, and sending that data back to the browser.
CGI.pm (see CGI) is a Perl module that makes it easier to write scripts that will be spoken to via CGI. It deals with extracting data from environment variables, etc.
CGI is just one way that a web server can talk to your script. Although it's simple, flexible, very widely supported, and well-known, it does also have its drawbacks. Each request for a page will run your script fresh. If your script needs to do a lot of initialisation (e.g. loading modules, opening database connections, etc) this can be pretty slow - it can be preferable to have a script which starts once and is able to serve up many pages. Solutions like mod_perl and FastCGI can help here.
In reply to Re: Web-designing using PERL
by tobyink
in thread Web-designing using PERL
by Arthes
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |