Home » Php » installation – can't install php 7.1

installation – can't install php 7.1

Posted by: admin February 25, 2020 Leave a comment

Questions:
[email protected]:~$ sudo apt-get install php7.1 
Reading package lists... Done
Building dependency tree       
Reading state information... Done
E: Unable to locate package php7.1
E: Couldn't find any package by glob 'php7.1'
E: Couldn't find any package by regex 'php7.1'

I am trying to install php 7.1 , tried almost everything…

sudo apt-add-repository ppa:ondrej/php
sudo apt-get update

reinstalled ubuntu twice.. still same error. #help

How to&Answers:

try with software-properties-common

sudo apt install software-properties-common
sudo add-apt-repository ppa:ondrej/php
sudo apt update
sudo apt search php7
sudo apt install php7.1
php -v