cvs: php4 /win32 install.txt

From: Date: Mon, 07 Jan 2002 18:31:19 +0000
Subject: cvs: php4 /win32 install.txt
Groups: php.cvs 
Request: Send a blank email to php-cvs+get-8974@lists.php.net to get a copy of this message
imajes Mon Jan 7 13:31:19 2002 EDT Modified files: /php4/win32 install.txt Log: changed the instructions for php with win32 + apache. Recommending using sapi over cgi binary, since cgi binary and apache don't mix well security wise. Index: php4/win32/install.txt diff -u php4/win32/install.txt:1.8 php4/win32/install.txt:1.9 --- php4/win32/install.txt:1.8 Sun Dec 23 14:48:25 2001 +++ php4/win32/install.txt Mon Jan 7 13:31:18 2002 @@ -210,40 +210,47 @@ newcomer. Please consult the Apache Docs for further configuration directives. - If you unzipped the PHP package to C:\PHP\ as desribed - above, you need to insert these lines to your Apache conf - file to set up the CGI binary: - - ScriptAlias /php/ "c:/php/" - AddType application/x-httpd-php .php - Action application/x-httpd-php "/php/php.exe" - - Remember to restart the server, for example, - NET STOP APACHE - followed by - NET START APACHE - - If you would like to use PHP as a module in Apache, - you should move php4ts.dll to the windows/system (for Windows 9x/Me) + Now that version 4.1 introduces a safer sapi module, we recommend^M + that you configure PHP as a module in Apache.^M +^M + To do this, you should move php4ts.dll to the windows/system (for Windows 9x/Me) or winnt/system32 (for Windows NT/2000) directory, overwriting any older file. Then you should add the following three lines to your Apache - conf file: + conf file: (swap c:/php/ for your PHP install path) - LoadModule php4_module c:/php/sapi/php4apache.dll + LoadModule php4_module c:/php/sapi/php4apache.dll^M AddModule mod_php4.c AddType application/x-httpd-php .php - Remember to restart the server, for example, + If you wish to install PHP as a CGI binary, read this first:^M +^M + http://www.cert.org/advisories/CA-1996-11.html^M +^M + and then if you are really sure, insert these lines to your conf file: ^M +^M + ScriptAlias /php/ "c:/php/"^M + AddType application/x-httpd-php .php^M + Action application/x-httpd-php "/php/php.exe"^M +^M + Note, we consider installing PHP like this suicidal.^M +^M + As a further precaution, we recommend you change the "/php/"^M + ScriptAlias to something more random, to prevent the binary being^M + called directly, which is a security risk.^M +^M + Remember when you have finished to restart the server, for example, NET STOP APACHE followed by NET START APACHE - To use the source code highlighting feature, simply create a PHP - script file and stick this code in: - <?php show_source("original_php_script.php"); ?> - Substitute original_php_script.php with the name of the - file you wish to show the source of. (This is the only way of - doing so). + To use the source code highlighting feature, add the following + line to your apache httpd.conf file:^M +^M + AddType application/x-httpd-php-source .phps^M +^M + Note, this will only work when you install php as a sapi module.^M + If you wish to use this feature with the cgi binary, create a new^M + file, and use the show_source("path/to/original_file.php"); function.^M On Win-Apache all backslashes in a path statement such as: "c:\directory\file.ext", must be converted to

« previous php.cvs (#8974) next »