faqts : Computers : Internet : Web Servers : Apache

+ Search
Add Entry AlertManage Folder Edit Entry Add page to http://del.icio.us/
Did You Find This Entry Useful?

19 of 23 people (83%) answered Yes
Recently 7 of 10 people (70%) answered Yes

Entry

Any images in the cgi-bin directory are being executed instead of displayed. How do I get around?

Nov 15th, 2001 20:49
Anthony Boyd, Sabre,


Move the images out of the cgi-bin.  Images belong in htdocs.  I prefer 
to put them in htdocs/images, but anywhere is better than cgi-bin.
(For those wondering about the tech specifics, there are two ways to 
process CGI programs using the httpd.conf file.  One is by extension.  
For instance, everything ending in .cgi will run as a program, no 
matter where it is.  That's using an AddHandler line.  The other way, 
as is happening to the person asking the question, is that ScriptAlias 
can mark an entire directory as all programs, no matter what the 
extension.  This is how cgi-bin directories usually work.  It's meant 
to keep programs and content separate, so it's best to keep non-CGI 
files elsewhere.)