Uninstall libapache2-mod-php5
To remove just libapache2-mod-php5 package itself from Ubuntu 14.04 (Trusty Tahr) execute on terminal:
sudo apt-get remove libapache2-mod-php5
Uninstall libapache2-mod-php5 and it's dependent packages
To remove the libapache2-mod-php5 package and any other dependant package which are no longer needed from Ubuntu Trusty.
sudo apt-get remove --auto-remove libapache2-mod-php5
Purging libapache2-mod-php5
If you also want to delete configuration and/or data files of libapache2-mod-php5 from Ubuntu Trusty then this will work:
sudo apt-get purge libapache2-mod-php5
To delete configuration and/or data files of libapache2-mod-php5 and it's dependencies from Ubuntu Trusty then execute:
sudo apt-get purge --auto-remove libapache2-mod-php5
See Also
How to remove libapache2-mod-php5 package from Ubuntu 14.04 (Trusty Tahr)