Hello,
I have just finished setting up my Ubuntu 16.4 server. I have installed php5.6.26 because I am going to use Wordpress and I am not sure if all plugins are compatible with php7.
I need to install some php modules like php-xmlrpc or another module. When I type
sudo apt-get install php-curl php-gd php-mbstring php-mcrypt php-xml php-xmlrpc
This command is from this article on DO [How To Install WordPress with LAMP on Ubuntu 16.04] https://www.digitalocean.com/community/tutorials/how-to-install-wordpress-with-lamp-on-ubuntu-16-04 I get this message
sudo apt-get install php-curl php-gd php-mbstring php-mcrypt php-xml php-xmlrpc
Reading package lists... Done
Building dependency tree
Reading state information... Done
php-gd is already the newest version (1:7.0+44+deb.sury.org~xenial+1).
The following additional packages will be installed:
libcurl3 libxmlrpc-epi0 php7.0-curl php7.0-mbstring php7.0-mcrypt php7.0-xml php7.0-xmlrpc
The following NEW packages will be installed:
libcurl3 libxmlrpc-epi0 php-curl php-mbstring php-mcrypt php-xml php-xmlrpc php7.0-curl php7.0-mbstring
php7.0-mcrypt php7.0-xml php7.0-xmlrpc
0 upgraded, 12 newly installed, 0 to remove and 11 not upgraded.
Need to get 869 kB of archives.
After this operation, 2,943 kB of additional disk space will be used.
Do you want to continue? [Y/n]
Honestly I don’t want to use php7 and I have already explained why. How can I install the modules of php5, not php7?
What is the difference between modules for php7 and for php5? Can I still use php5 while the modules are for php7?
Thank you very much :)
This textbox defaults to using Markdown to format your answer.
You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!
These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.
Sign up for Infrastructure as a Newsletter.
Working on improving health and education, reducing inequality, and spurring economic growth? We'd like to help.
Get paid to write technical tutorials and select a tech-focused charity to receive a matching donation.
As of Ubuntu 16.04.x default PHP version is PHP7. You should add PHP5 repository and you will be able to install it.
First of all add repository :
When it finishes update apt:
After that executing
You can also install any php package, but you need to refer as
php5.6
instead ofphp
, e.g.php5.6-mbstring
instead ofphp-mbstring
.Also note: remove all php7 packages
I have 404 error on ppa:ondrej/php ppa. Is it some other way to install php5.5 on ubuntu 16…04?