Re: Apache + PHP on Win2K

From: Date: Tue, 08 May 2001 10:56:24 +0000
Subject: Re: Apache + PHP on Win2K
References: 1  Groups: php.windows 
Request: Send a blank email to php-windows+get-7348@lists.php.net to get a copy of this message
"macky" <macky@edsamail.com> wrote in message news:9d8dn8$mre$1@toye.p.sourceforge.net... > Im new to APACHE > > I already installed APACHE on Win2K and it works well.... > > Can anyone tell how to enable.. PHP on Win2K? > meaning able to execute .php pages... > > > <%php > echo "FOO VAR"; > %> did you download the manual as well? The instructions say General Installation Steps 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. Copy the file, 'php.ini-dist' to your '%WINDOWS%' directory and rename it to 'php.ini'. Your '%WINDOWS%' directory is typically: c:\windows for Windows 95/98 c:\winnt or c:\winnt40 for NT servers Edit your 'php.ini' file: You will need to change the 'extension_dir' setting to point to your php-install-dir, or where you have placed your 'php_*.dll' files. ex: c:\php If you are using Omni Httpd, do not follow the next step. Set the 'doc_root' to point to your webservers document_root. ex: c:\apache\htdocs or c:\webroot Choose which modules you would like to load when PHP starts. You can uncomment the: 'extension=php_*.dll' lines to load these modules. Some modules require you to have additional libraries installed on your system for the module to work correctly. The PHP FAQ has more information on where to get supporting libraries. You can also load a module dynamically in your script using: dl("php_*.dll"); On PWS and IIS, you can set the browscap.ini to point to: 'c:\windows\system\inetsrv\browscap.ini' on Windows 95/98 and 'c:\winnt\system32\inetsrv\browscap.ini' on NT Server. Additional information on using the browscap functionality in PHP can be found at this mirror, select the "source" button to see it in action. The DLLs for PHP extensions are prefixed with 'php_'. This prevents confusion between PHP extensions and their supporting libraries. Windows 9x/NT and Apache 1.3.x You must edit your srm.conf or httpd.conf to configure Apache to work with the PHP CGI binary. Although there can be a few variations of configuring PHP under Apache, this one is simple enough to be used by the newcomer. Please consult the Apache Docs for further configuration directives. ScriptAlias /php/ "c:/path-to-php-dir/" AddType application/x-httpd-php .php AddType application/x-httpd-php .phtml Action application/x-httpd-php "/php/php.exe" 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 only one way of doing it). Note: On Win-Apache all back slashes in a path statement such as: "c:\directory\file.ext", must be converted to forward slashes. I followed these and it still didn't work as a dll was missing. However i installed pws and mysql too then apach worked again this time with php

« previous php.windows (#7348) next »