How to install PHP 5.6 (as an Apache module) on Ubuntu Server 14.04/14.10

This question was answered by Marc Deslauriers, security engineer at Canonical, and make sense since Canonical point of view about server updates are: stability, security, and updates-that-doesn’t-broken-legacy-code comes first. They don’t want to update because PHP 5.5 syntax are significantly different than 5.3.

So, what we can do if we need or want newer versions than 5.3? An option is to install by compiling the source code, which is awful to maintain. Another option is to install by some rpm found on internet, which not only is hard to maintain, but also probally won’t work without some black magic and many updates to our core system libraries.

which means that you are using the 2.4 version. If you are using a version lower than 2.2, you need to update to 2.4 (“sudo add-apt-repository ppa:ondrej/apache2”). WARNING: if you update to 2.4, be aware that you will need to review all of your configurations since the structure and syntax are not fully compatible.