How To Install php7.2 In Ubuntu 16.04
Now I am sharing how to install php7. 2 in Ubuntu 16.04. PHP is an open source programming language. Many cms using PHP language for developing purposes.
- How To Install php 7.4 on Ubuntu 16.04
- How to Install PHP 7.3 on Ubuntu 16.04
- How To Install php7.2 In Ubuntu 16.04
- How To Add illustrator Checkbox Symbol
At first server must be update & upgrade completed using below command.
[email protected]:~# apt-get update [email protected]:~# apt-get upgrade -y [email protected]:~# apt-get install apache2 [email protected]:~# systemctl start apache2 [email protected]:~# systemctl enable apache2 root[email protected]:~# apt-get install software-properties-common python-software-properties [email protected]:~# add-apt-repository -y ppa:ondrej/php [email protected]:~# apt-get update [email protected]:~# apt-get install php7.2 php7.2-cli php7.2-common php7.2-curl php7.2-gd php7.2-json php7.2-mbstring php7.2-intl php7.2-mysql php7.2-xml php7.2-zip [email protected]:~# php -v [email protected]:~# a2enmod php7.2 [email protected]:~# systemctl restart apache2
Open tech.php file or create file using touch command like touch tech.php then open it via any editor.
[email protected]:~# vi /var/www/html/tech.php
Insert below line into tech.php file.
<?php phpinfo(); ?>
Now browser your server ip address and see php info.
Example : http://server_ip_address/tech.php