I need to upgrade php 5.4 to 5.6 to use my framework magento 2. I apply these commands :
echo "deb http://packages.dotdeb.org wheezy-php56 all" >> /etc/apt/sources.list.d/dotdeb.list echo "deb-src http://packages.dotdeb.org wheezy-php56 all" >> /etc/apt/sources.list.d/dotdeb.list wget http://www.dotdeb.org/dotdeb.gpg -O- | apt-key add - apt-get update apt-get install php5-cli php5-fpm
It works I have that now in SSH :
# php -v
PHP 5.6.30-1~dotdeb+7.1 (cli) (built: Jan 21 2017 14:50:59)
Copyright (c) 1997-2016 The PHP Group
Zend Engine v2.6.0, Copyright (c) 1998-2016 Zend Technologies
But Magento 2 does not works and when I put echo phpversion(); in the index.php, I have this version ! 5.4.45-0+deb7u5
I am on debian and I do not understand how I can have 2 other php versions on the same server
Can you help me ?
EDIT:
Content of /etc/apache2/mods-available :
actions.conf deflate.conf php5_cgi.load.dpkg-remove
actions.load deflate.load php5.conf
alias.conf dir.conf php5.conf.dpkg-new
alias.load dir.load php5.load
asis.load disk_cache.conf php5.load.dpkg-new
auth_basic.load disk_cache.load proxy_ajp.load
auth_digest.load dump_io.load proxy_balancer.conf
authn_alias.load env.load proxy_balancer.load
authn_anon.load expires.load proxy.conf
authn_dbd.load ext_filter.load proxy_connect.load
authn_dbm.load file_cache.load proxy_ftp.conf
authn_default.load filter.load proxy_ftp.load
authn_file.load headers.load proxy_http.load
authnz_ldap.load ident.load proxy.load
authz_dbm.load imagemap.load proxy_scgi.load
authz_default.load include.load reqtimeout.conf
authz_groupfile.load info.conf reqtimeout.load
authz_host.load info.load rewrite.load
authz_owner.load ldap.conf setenvif.conf
authz_user.load ldap.load setenvif.load
autoindex.conf log_forensic.load speling.load
autoindex.load mem_cache.conf ssl.conf
cache.load mem_cache.load ssl.load
cern_meta.load mime.conf status.conf
cgid.conf mime.load status.load
cgid.load mime_magic.conf substitute.load
cgi.load mime_magic.load suexec.load
charset_lite.load negotiation.conf unique_id.load
dav_fs.conf negotiation.load userdir.conf
dav_fs.load php5_cgi.conf.dpkg-new userdir.load
dav.load php5-cgi.conf.dpkg-new usertrack.load
dav_lock.load php5_cgi.conf.dpkg-remove vhost_alias.load
dbd.load php5_cgi.load.dpkg-new
Content of /etc/apache2/mods-enabled :
alias.conf autoindex.load mime.conf setenvif.conf
alias.load cgi.load mime.load setenvif.load
auth_basic.load deflate.conf negotiation.conf ssl.conf
authn_file.load deflate.load negotiation.load ssl.load
authz_default.load dir.conf php5.conf status.conf
authz_groupfile.load dir.load php5.load status.load
authz_host.load env.load reqtimeout.conf
authz_user.load expires.load reqtimeout.load
autoindex.conf headers.load rewrite.load