I have been working on this over a couple of days and have not succeeded.
I recently upgraded Ubuntu from 12.04 to 14.04. Had some problems with apache2 going from 2.2 to 2.4 over config file naming and permissions, but got that resolved.
Now I am stuck and floundering installing php5.
I get this error for the install:
dpkg: error processing package libapache2-mod-php5 (--configure):
subprocess installed post-installation script returned error exit status 1
Errors were encountered while processing:
libapache2-mod-php5
E: Sub-process /usr/bin/dpkg returned an error code (1)