I installed php5 on ubuntu lucid lynx 10.04 by following the instructions at
https://help.ubuntu.com/community/ApacheMySQLPHP
I already had apache2 server running on my machine, so I installed only PHP5 and mySQL 5 using
Code:
sudo apt-get install php5-mysql libapache2-mod-php5 mysql-server
(During the installation, the apache2 server I already had on my machine was stopped and re-started.)
I faced the same issue with my php files - they were downloading, instead of being parsed by apache. Googled around and found your post.
Then I followed the guidelines at
https://help.ubuntu.com/community/ApacheMySQL under section titled '
Checking PHP 5 installation' and did all the testing recommended there.
I tried this command suggested there:
and it said "Module php5 already enabled".
Finally I tried re-starting apache2 with the following command:
Code:
sudo apache2ctl restart
and PHP started parsing and working fine after that.
So most likely your apache server needs a re-start too!