|
|
|
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
#1
|
|||
|
|||
|
CGI Server Side Includes - IIS6 config. Perlis.dll
Hi everyone, usually I find everything I need to know just from browsing the other great posts here, but I've been tearing my hair out with this so I am very hopeful you can help.
My config is: Win2k3, IIS6 with ActivePerl 5.8 .pl and .cgi are mapped to perlis.dll GET, HEAD, POST .shtml is mapped to ssinc.dll GET, POST Perl works great! But calling a .pl or .cgi as an SSI is giving problems: This tag <!--#include virtual="/cgi-bin/path/script.pl?info=action" --> doesn't interpret the file e.g. http://mytreo.net/test.shtml and the following tag <!--#exec cgi="/cgi-bin/path/script.pl?info=action" --> interprets the file correctly, but adds a header to the output e.g. http://mytreo.net/test1.shtml The header it adds is: "HTTP/1.1 200 OK Date: Sun, 29 Aug 2004 12:42:32 GMT Server: Microsoft-IIS/6.0 Content-type: text/html;CHARSET=ISO-8859-1" How can I remove this header information? Or, how do I configure the server to process CGI scripts correctly as SSI's? Please help! Many thanks Chris N |
|
#2
|
|||
|
|||
|
I don't know the answer for you. www.iisfaq.com has a lot of helpful information about cgi
__________________
====== Doug G ====== "Hide, hide witch! The good folk come to burn thee. Their keen enjoyment hid behind their gothic mask of duty." -Mark Clifton |
|
#3
|
|||
|
|||
|
<!--#exec cgi="../../.pl"-->
Hi Chris,
Just wanted to know whether you've find the fix on your problem in using <!--#exec cgi="/cgi-bin/path/script.pl?info=action" --> For my case is a bit worse than you cause this line does nothing at all(treated like a comment). hope to have some light from you so I can also get out from this mess . thanks edwin_me69@yahoo.com Quote:
|
|
#4
|
|||
|
|||
|
The answer to this is not obvious. This happened to me about 2 years ago under IIS5. It took me days to find how to solve the headers problem.
So, the solution is to map perl extensions (.cgi, .pl, etc) to /path/to/perl.exe "%s" %s where path/to/perl is the path to your bin directory. Example: c:\Perl\bin\perl.exe "%s" %s Off course, by doing this, you will sacrifice the speed load of your scripts as perl for isapi (perlis component) loads once and your scripts load faster than when you use perl.exe (which is executed everytime you load a script). Hope this helps |
|
#5
|
|||
|
|||
|
If you find this problem continues, but does not occur all the time, the cause may lie with IIS6. This Microsoft Hotfix may be of interest:
http://support.microsoft.com/default.aspx?scid=kb;EN-US;884764 |
|
#6
|
||||
|
||||
|
Has anyone found the solution to removing the headers while using PerlIS?
__________________
DasNoc |
|
#7
|
|||
|
|||
|
I too am looking for help on a related issue. I am looking for almost the exact same thing, using
Code:
<!--#include virtual="/cgi-bin/path/script.pl?info=action" --> Here is what I am trying to accomplish: I have a PHP calendar script that I wrote myself, and based on a GET or POSTed value, the month changes. The script alone works great, but I need to throw it in to a .shtm file so I can add the site's navigation around it. I have realized that I cannot use the Front Page web navigation bars in a PHP file. Again, the exec will load the script, but I have no access to the environmental variables the scripts posts. I got this to work fine in Apache by adding two lines to the htaccess file: AddType text/html .shtm AddHandler server-parsed .shtm Any ideas? |
|
#8
|
|||
|
|||
|
Actually, I just got something working, but I know it isn't the "right" way to do things. Recognizing the fact that .shtm files are "parsed" by front page to insert the navigation links and other dynamic content, I changed the server mapping for .shtm files from the SSI dll to the PHP executable. Now not only are the pages being recognized by FrontPage and inserting the navigation bar at the appropriate place, but the sever will parse them as a PHP files.
If I should not be doing this, and a better method should be used instead, someone please post so! But for now, it works! ![]() |
![]() |
| Viewing: Dev Shed Forums > System Administration > IIS > CGI Server Side Includes - IIS6 config. Perlis.dll |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|