This is a discussion on Apache 2.0, php 5 and mysql + win xp within the Windows Web Servers forums, part of the Web Server and Related Forums category; Hi, I am trying to run and configure Apache 2.0, php 5 and mysql on win xp professional - this ...
|
|||||||
| FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
|
|||
|
Hi,
I am trying to run and configure Apache 2.0, php 5 and mysql on win xp professional - this is the first time I have tried to install and configure all three. I am having difficulty trying to configure them on my computer. Can somebody help me - this is what I have done so far. Installed Apache 2.0, it worked perfectly ( I checked with my browser - http://localhost) till the point where I started to point where I wanted to store my html files. I have named the folder html_files and have changed the DocumentRoot "C:/html_files" and <Directory "C:/html_files/htdocs"> on the configuration file. And now it does not work (http://localhost does not work). I get an error message saying "You don't have permission to access / on the server". What am I doing wrong? Also I have installed and configured php 5, renamed Rename e:\php\php.ini-dist it to php.ini and enterd the following on the apache configuration file LoadModule php5_module "c:/php/php5apache2.dll" AddType application/x-httpd-php .php PHPIniDir "c:/php" Obviously it does not work because apache is not working? Can somebody help me? And how do I install and configure mysql? Thanks, Gene |
|
|||
|
> Hi,
> > I am trying to run and configure Apache 2.0, php 5 and mysql on win xp > professional - this is the first time I have tried to install and > configure all three. I am having difficulty trying to configure them > on my computer. Can somebody help me - this is what I have done so > far. > > Installed Apache 2.0, it worked perfectly ( I checked with my browser - > http://localhost) till the point where I started to point where I > wanted to store my html files. I have named the folder html_files and > have changed the DocumentRoot "C:/html_files" and <Directory > "C:/html_files/htdocs"> on the configuration file. And now it does not > work (http://localhost does not work). I get an error message saying > "You don't have permission to access / on the server". What am I doing > wrong? > > Also I have installed and configured php 5, renamed Rename > e:\php\php.ini-dist it to php.ini and enterd the following on the > apache configuration file > > LoadModule php5_module "c:/php/php5apache2.dll" > AddType application/x-httpd-php .php > PHPIniDir "c:/php" > > Obviously it does not work because apache is not working? Can somebody > help me? And how do I install and configure mysql? > > Thanks, > Gene Hi Gene, There are also complete webserver packages, check http://www.wampserver.com/en/index.php or http://www.devside.net Good luck! André -- 73' André, PE1PQX Mijn site: http://pe1pqx.dyndns.org |
|
|||
|
genenamg@yahoo.com wrote:
> I have named the folder html_files and > have changed the DocumentRoot "C:/html_files" and <Directory > "C:/html_files/htdocs"> If you set your DocumentRoot to C:/html_files but the directory section for the htdocs folder (which permits access via "allow from all") to a sub directory, this won't work of course. So either use DocumentRoot "C:/html_files/htdocs" or change the directory section to what you have set the DocumentRoot: <Directory "C:/html_files"> > Also I have installed and configured php 5, renamed Rename > e:\php\php.ini-dist it to php.ini Why e:\? Is this just a typo? > LoadModule php5_module "c:/php/php5apache2.dll" > AddType application/x-httpd-php .php > PHPIniDir "c:/php" That looks correct. Did you check the windows event logging for any error messages? If you find there an error message like "Cannot load module...", may be some DLLs are missing. You can use a tool called FileMon [1] which can show you the dll files apache is looking for. [1] http://www.sysinternals.com/ntw2k/source/filemon.shtml -- Robert |
|
|||
|
genenamg@yahoo.com wrote:
> Hi, > > I am trying to run and configure Apache 2.0, php 5 and mysql on win xp > professional - this is the first time I have tried to install and > configure all three. I am having difficulty trying to configure them > on my computer. Can somebody help me - this is what I have done so > far. > > Installed Apache 2.0, it worked perfectly ( I checked with my browser - > http://localhost) till the point where I started to point where I > wanted to store my html files. I have named the folder html_files and > have changed the DocumentRoot "C:/html_files" and <Directory > "C:/html_files/htdocs"> on the configuration file. And now it does not > work (http://localhost does not work). I get an error message saying > "You don't have permission to access / on the server". What am I doing > wrong? > > Also I have installed and configured php 5, renamed Rename > e:\php\php.ini-dist it to php.ini and enterd the following on the > apache configuration file > > LoadModule php5_module "c:/php/php5apache2.dll" > AddType application/x-httpd-php .php > PHPIniDir "c:/php" > > Obviously it does not work because apache is not working? Can somebody > help me? And how do I install and configure mysql? > > Thanks, > Gene > from: http://www.apachelounge.com/forum/viewtopic.php?t=570 One of the biggest topics here at Apache Lounge is running PHP on Apache. It is a topic that is constant and for some reason often confused. Confused namely by varying ways to accomplish the same thing. The following has been tested numerous times, and seems (at least so far) to be easy to follow.Mr. Green ExclamationIF YOU INSTALLED APACHE USING A MSI FILE THENExclamation (otherwise skip down to CONTINUE section): I have not tested Apache Software Foundation (ASF) MSI installation applications lately, but the last time I tested the MSI FAILED to remove to some things that can cause problems later on during the Un-Install process. BEFORE you UN-INSTALL the MSI file, open a command prompt and navigate to the BIN folder of Apache. Now, uninstall the service: httpd -k uninstall Now that the service is removed, uninstall Apache and then ALL PHP entries (files [php5ts.dll and others depending on what each person has done in the past] that you copied from where ever to where ever - usually into the Windows\System32 folder). ArrowCONTINUE: Install the Microsoft VC++ Redistributable. The reason for this is because it is NOT included in the latest versions of Windows; and Steffen's builds are compiled using Microsoft Visual C++ 2005. The Redistributable can be downloaded at the link below: http://www.microsoft.com/downloads/details.aspx?familyid=32BC1BEE-A3F9-4C13-9C99-220B62A191EE&displaylang=en Download httpd-2.2.2-win32-x86-ssl.zip from http://www.apachelounge.com/download/ Unzip this ZIP file in a new folder called something like C:\Apache2. Then, read the file named Read Me First !!.txt. It will tell you how to setup the service for Apache. If you want or need ApacheMonitor you can create shortcuts however you like. Before installing ANYTHING else, ensure Apache will start. After you validate that Apache starts, stop it before proceding. If you are still with me, now download PHP 5.x from PHP.net you want this file: php-5.x.xx-Win32.zip (where x relates to the latest stable version number) Extract the contents of this file and move the contents to where you intend to use PHP such as C:\PHP5. NEXT, overwrite the php5apache2.dll with Steffen's version - READ the 'ReadMe' file for possible changes: php5apache2.dll-php5.1.x.zip from http://www.apachelounge.com/download/ Navigate to the PHP folder and edit the php.ini-recommended. FIND the extension_dir directive and change so that it properly locates the EXT folder: extension_dir = "C:\php5\ext" Save the file as php.ini. Add the folder that you put the PHP files into in the PATH ENVIRONMENT (System Properties | Advanced | Environment Variables | System variables | Path). Example: Variable name: Path Variable value: C:\php5;%SystemRoot%\system32;..... DO NOT WORRY with coping files over to the Windows folders, the reason for this to begin with is because Windows folder is already in the Path. Since you have added the PHP folder to the Path you do not need to copy or move files to the Windows folder. This will make upgrading PHP simpler as well and allows you to keep PHP all together. To upgrade PHP in the future, all you need to do is delete the contents of the PHP folder, and then extract the contents of the new version into the PHP folder. Finally, this should be the last step, edit the Apache CONF file with: LoadModule php5_module "c:/php5/php5apache2.dll" AddType application/x-httpd-php .php AddType application/x-httpd-php .php-source .phps # configure the path to php.ini PHPIniDir "c:/php5" This is how I put together WAMP, and I do it often (web application tester). I hoped this helped. |
| Thread Tools | |
| Display Modes | |
|
|