Hi all,

The problem: index.php downloads instead of actually executing the script. I used to have my machine setup with php/apache/mysql/WinXP and it worked. I downloaded the newest release of php 4 and now it won't work.

What happened?

Windows XP SP 1
PHP 4.3.10
Apache 1.3.33
mySQL 4.1.8

Any and all help is appreciated.

-Derek Parnell

13 Years
Discussion Span
Last Post by derekparnell

I can only think of two things,
Either you forgot to put the start/end of the script by usign the brackets/questionmarks

  //some code goes here

Or worse yet you forgot to configure php as an extension to apache, installing apache and then installing php is not enough to get php running in apache. You must configure apache to recognize php in a windows envioroment.

How to Install and Configure PHP4 to run with Apache on Windows


Not sure if it works the same in Windows as in Linux, but the .php file must have executable permissions.


Thanks for the responses, but I found a post somewhere (I can't remember where) that mentioned problems on the local box if you use localhost. Their suggestion was to use and when I do that, it works fine. It wasn't mentioned on the other post, but is this a known bug/issue/technique?

Anyway, it works now.

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.