title: Apache with passenger and php modules, not executing php
body: <p>I have a rails setup which is served by Apache Passenger, there are 2 apps on the server which are served by passenger and all was working fine. I then wanted to install wordpress on the same server and so I installed the required packages &quot;php5 php5-mysql libapache2-mod-php&quot; and setup a separate vhost for wordpress, when I try to run the wordpress index.php file, apache doesn't execute but rather offers me to download.</p>
  <p>I have googled this to no resolution, this problem is pretty common but none of the solutions have worked for me. Solutions that I have tried:</p>
  <ul>
  <li><p>Adding &quot;AddType application/x-httpd-php .php&quot; in apache2.conf</p>
  </li>
  <li><p>making the wordpress directory executable, also changed the owner of the directory to www-data</p>
  </li>
  <li><p>In the vhost of wordpress, disabled Passenger by setting PassengerEnabled Off in the Directory directive.</p>
  </li>
  <li><p>Verified that php module is loaded by apache2ctl -M</p>
  </li>
  <li><p>Checked error log and nothing there, enabled error log for that vhost but nothing there.</p>
  <p>any pointers, help appreciated thanks. BTW, the same setup works on local development box, its just this instance being painful can't recreate things from scratch.</p>
  </li>
  </ul>