From f868097bdbda58cf352d9ce51b6848de18ab4ee1 Mon Sep 17 00:00:00 2001 From: James Cox Date: Tue, 8 Jan 2002 08:21:50 +0000 Subject: [PATCH] a number of changes: - removed the sapi warning now that the module is safe - tidied up a number of comments in the Apache-Win section. - moved some para type tags to simpara, - removed some completely ridiculous statements - reworked some grammer errors. git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@67273 c90b9560-bf6c-de11-be94-00142212c4b1 --- chapters/install.xml | 111 +++++++++++++++++++++++-------------------- 1 file changed, 60 insertions(+), 51 deletions(-) diff --git a/chapters/install.xml b/chapters/install.xml index 3d7dcbe46b..a134b6bbb8 100644 --- a/chapters/install.xml +++ b/chapters/install.xml @@ -1,5 +1,5 @@ - + Installation @@ -2685,27 +2685,13 @@ $ /usr/local/sbin/php4-enable some new functionality. - - However, please note that the SAPI modules are NOT - yet considered to be production quality. In particular, with the - ISAPI module, you are likely to encounter serious reliability - problems especially on platforms older than W2K - you may witness - a lot of server 500 errors and suffer from other server modules - such as ASP also failing. You have been warned! - - - The reason for this is that the PHP SAPI modules are using the - thread-safe version of the PHP code, which is new to PHP 4, and has - not yet been tested and pounded enough to be considered completely - stable, and there are actually a few known bugs. On the other hand, - some people have reported very good results with the SAPI modules, - even though we're not aware of anyone actually running it on a - production site. In short - your mileage may vary; If you need - absolute stability, trade the performance of the SAPI modules - with the stability of the CGI executable. - + + The SAPI modules have been significantly improved in the 4.1 release, + however, you may find that you encounter possible server errors or + other server modules such as ASP failing, in older systems. + - + If you choose one of the SAPI modules and use Windows 95, be sure to download the DCOM update from the Microsoft DCOM pages. For the @@ -2714,19 +2700,19 @@ $ /usr/local/sbin/php4-enable NOT supported. You should download and install the Windows NT 4.0 Option Pack with IIS 4.0 if you want native PHP support. - + The following steps should be performed on all installations before the server specific instructions. - + Extract the distribution file to a directory of your choice. c:\php\ is a good start. - + - + You need to ensure that the dlls which PHP uses can be found. The precise DLLs involved depend on which web server you use and whether you want to run PHP as a CGI or as a server module. @@ -2741,7 +2727,7 @@ $ /usr/local/sbin/php4-enable that they live in the same directory as the main PHP executable or DLL your web server will use (e.g. php.exe, php4apache.dll). - + The PHP binary, the SAPI modules, and some extensions rely on external DLLs for execution. Make sure that these DLLs in the @@ -3581,6 +3567,11 @@ stop and start: srm.conf or httpd.conf to configure Apache to work with PHP. + + It is worth noting here that now the sapi module has been + made more stable under windows, we recommend it's use above + the CGI binary, since it is more transparent and secure. + Although there can be a few variations of configuring PHP under Apache, these are simple enough to be used by the @@ -3619,16 +3610,16 @@ stop and start: Note that the second line in the list above can be found in the actual versions of httpd.conf, - but it is commented out. - - + but it is commented out. Remember also to substitute the + c:/php/ for your actual path to PHP. + + - By using this CGI setup, your server are open - to several possible attacks. Please also read - our security section - about CGI setups to get some - ideas, about how to defend yourself from attacks. + By using the CGI setup, your server is open + to several possible attacks. Please read + our CGI security + section to learn how to defend yourself from attacks. @@ -3657,34 +3648,52 @@ stop and start: - + After changing the configuration file, remember to restart the server, for example, NET STOP APACHE followed by NET START APACHE, if you run Apache as a Windows Service, or use your regular shortcuts. - + - In Apache 1.3.22 for Windows, the default configuration file - (httpd.conf-dist-win) has - a ClearModuleList directive included - by default. If this directive is used, it is required - to put an AddModule mod_php4.c to - the AddModule list, as else PHP will - not be registered as an Apache module. + You may find after using the windows installer for Apache + that you need to define the AddModule + directive for mod_php4.c in the + configuration file (httpd.conf). + This is done by adding AddModule mod_php4.c + to the AddModule list, near the beginning + of the configuration file. This is especially important if + the ClearModuleList directive is defined. + Failure to do this may mean PHP will not be registered as an + Apache module. - - 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 this, as there is no .phps like feature on Windows). - + + There are 2 ways you can use the source code highlighting feature, + however their ability to work depends on your installation. + If you have configured Apache to use PHP as an isapi module, then by + adding the following line to your configuration file you can use + this feature: + + + + + AddType application/x-httpd-php-source .phps + + + + + If you chose to configure Apache to use PHP as a CGI binary, you + will need to use the show_source function. To + do this simply create a PHP script file and add this code: + <?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. + + On Win-Apache all backslashes in a path statement such