Contributed by Anonymous Monk
on Jun 19, 2000 at 19:22 UTC
Q&A
> CGI programming
Answer: Is there a difference .pl and .cgi extensions? contributed by cleen these are just extentions, which can be configured on the web server itself. You could do a .hiImaFreak and as long as its defined as executable in the httpd configuration it will run. | Answer: Is there a difference .pl and .cgi extensions? contributed by merlyn Not really. Both are unneeded extensions on Unix, that drive me and many other experts nuts. You don't call cat as cat.c! A user should not need to know the implementation language to invoke a program.
Additionally, when used as part of a URL, they give away the implementation language to random users out on the net--a major security hole.
So if your webserver or O/S needs an "extension" to determine that it's a CGI script or a Perl script, please don't use it for anything other than a toy. Real web servers don't need or use those. | Answer: Is there a difference .pl and .cgi extensions? contributed by tenatious It's convention only. Kinda like when a M$Word document is named icky.doc. People like to use .pl for perl libraries, which may be required and reused. Naming a script cool.cgi makes it easy to identify cgi scripts, and allows security conscious system administrators to take proper precautions since they can be world executable. |
Please (register and) log in if you wish to add an answer
Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
Read Where should I post X? if you're not absolutely sure you're posting in the right place.
Please read these before you post! —
Posts may use any of the Perl Monks Approved HTML tags:
- a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
Outside of code tags, you may need to use entities for some characters:
| |
For: |
|
Use: |
| & | | & |
| < | | < |
| > | | > |
| [ | | [ |
| ] | | ] |
Link using PerlMonks shortcuts! What shortcuts can I use for linking?
See Writeup Formatting Tips and other pages linked from there for more info.
|
|