Ir al contenido principal

Actualizar php7.2












How to Install PHP 7.2 on Ubuntu 16.04


PHP 7.2 is the latest stable version of PHP and has many new
features, improvements, and bug fixes. You should definitely use it if you want
a better, faster website/application.

Update Ubuntu


Of course, as always, first update Ubuntu: apt-get update && apt-get
upgrade

Add the PHP repository


You can use a third-party repository to install the latest
version of PHP. We’ll use the repository by Ondřej Surý.

First, make sure you have the following package installed so
you can add repositories: apt-get
install software-properties-common

Next, add the PHP repository from Ondřej: add-apt-repository
ppa:ondrej/php

And finally, update your package list: apt-get update

Install PHP 7.2


After you’ve added the repository, you can install PHP 7.2
with the following command: apt-get
install php7.2

And that’s it. To check if PHP 7.2 is installed on your
server, run the following command: php -v

Install PHP 7.2 modules


You may need additional packages and modules depending on
your applications. The most commonly used modules can be installed with the
following command:

·       
apt-get install
php-pear php7.2-curl php7.2-dev php7.2-gd php7.2-mbstring php7.2-zip
php7.2-mysql php7.2-xml

And that’s all. You can now start using PHP on your Ubuntu
server.







Comentarios