Jump to content

PHP & Apache install problem (PHP can't be viewed)


Cander

Recommended Posts

Hello there,

 

I have been having problem installing PHP with Apache on Windows. When I try to open a .php file in my browser in the "htdocs" folder by typing http://localhost/filename.php, insted of let me view the .php file content it shut the browser window down and start a download of the file.

 

I'm running a Vista 32-bit

 

What I've done:

 

- Downloaded apache 2.2.11 and sucessfully installed. I can open the index.html in "htdocs" folder by typing http://localhost in my browser.

 

- Downloaded the PHP 5.9.2-1 zip-file and extracted to C:\php, set the enviroment path and got it all set up sucessfully. Also renamed the "php.ini-recommended" to "php.ini".

 

- Added these lines into the "httpd.conf" file:

LoadModule php5_module "C:/php/php5apache2_2.dll"
PHPIniDir "C:/php"
AddType application/x-httpd-php .php .phtml .html

And I'm sure that the "C:/php/php5apache2_2.dll" and the "C:/php" exist.

 

- Restarted apache server & computer.

 

Any thoughts of what have I missed?

 

Thanks in advance!

 

//Cander

Link to comment
Share on other sites

Guest
This topic is now closed to further replies.
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.