From: Suresh S. <sur...@ya...> - 2002-02-10 20:42:06
|
On Mon, 11 Feb 2001, Jonathan Stowe wrote: JS> I'm with Dave. JS> First thing to bear in mind that SSI is only a 'de facto' JS> standard really JS> driven by the first implementations which were the NCSA httpd JS> and later JS> Apache, most other HTTP servers follow these JS> implementations but clearly ============================================================ Hi Jonathan, I tested the script with Xitami as well as Apache, the $ENV{DOCUMENT_URI} problem I mentioned only appears with Xitami. Anyway, to answer you question,Yes, I am using "exec cgi" command to call the script. As, for the script you asked me to run as a cgi, well I already ran a script on Xitami that prints out all the environment variables. Here's the script:- ================================== #!c:/perl/bin/perl.exe use CGI qw(:standard); print header(); print'<br>'; foreach $env (sort (keys %ENV) ) { print "$env => $ENV{$env}<br>"; } =================================== And here is the output when it's run as a cgi program:- ============================================== Content-Type: text/html; charset=ISO-8859-1 BLASTER : A220 I5 D1 H1 P330 T6 CGI_ROOT : C:/XITAMI/cgi-bin CGI_STDERR : cgierr.log CGI_STDOUT : C:\WINDOWS\TEMP\pipe0007.cgo CGI_URL : /cgi-bin CMDLINE : WIN COMSPEC : C:\WINDOWS\COMMAND.COM CONTENT_LENGTH : 0 CONTENT_TYPE : DOCUMENT_ROOT : C:/XITAMI/webpages GATEWAY_INTERFACE : CGI/1.1 HTTP_ACCEPT : */* HTTP_ACCEPT_ENCODING : gzip, deflate HTTP_ACCEPT_LANGUAGE : en-us HTTP_CONNECTION : Keep-Alive HTTP_CONTENT_LENGTH : 0 HTTP_HOST : localhost HTTP_USER_AGENT : Mozilla/4.0 (compatible; MSIE 6.0; Windows 98) PATH : C:\PERL\BIN;C:\PERL\BIN;C:\WINDOWS;C:\WINDOWS\COMMAND PATH_INFO : /index.shtm PATH_TRANSLATED : C:/XITAMI/webpages/index.shtm PROMPT : $p$g QUERY_METHOD : GET REMOTE_ADDR : 127.0.0.1 REMOTE_HOST : 127.0.0.1 REMOTE_USER : - REQUEST_METHOD : GET SCRIPT_NAME : /index.shtm SCRIPT_PATH : SERVER_NAME : localhost SERVER_PORT : 0 SERVER_PROTOCOL : HTTP/1.1 SERVER_SECURITY : - SERVER_SOFTWARE : Xitami SERVER_URL : http://localhost/ SERVER_VERSION : 2.5b4 TEMP : C:\WINDOWS\TEMP TMP : C:\WINDOWS\TEMP WINBOOTDIR : C:\WINDOWS WINDIR : C:\WINDOWS ============================================== Another strange thing I noticed with Xitami is when i used <!--#echo var="DOCUMENT_URI"--> to print out the variable, I get the desired output for DOCUMENT_URI, somehow as you can see from the script output above, it just doesn't get passed on to the cgi program. Another strange thing you might notice is that the content header is echoed in the script response, which normally shouldn't happen. This again is Xitami specific. :) Hope all of this helps in some way or another. -- Best regards, Suresh. mailto:sur...@ya... _________________________________________________________ Do You Yahoo!? Get your free @yahoo.com address at http://mail.yahoo.com |