How To Install PHP 7 on Ubuntu 15.04

Install PHP 7 on Ubuntu 15.04

In this tutorial, we will show you how to install and configuration of PHP 7 on your Ubuntu 15.04 server. For those of you who didn’t know, PHP (PHP: Hypertext Preprocessor) is a server-side scripting language designed for web development but also used as a general-purpose programming language. PHP code is interpreted by a web server with a PHP processor module, which generates the resulting web page: PHP commands can be embedded directly into an HTML source document rather than calling an external file to process data. PHP 7 comes with numerous new and improved features. One of the most noticeable is the new Zend Engine version. Also, other important improvements are enhanced performance and significantly reduced memory usage. Thus, PHP 7 can be up to twice as fast as PHP 5.6.

This article assumes you have at least basic knowledge of Linux, know how to use the shell, and most importantly, you host your site on your own VPS. The installation is quite simple. I will show you through the step by step installation PHP 7 in Ubuntu 15.04 server.

Install PHP 7 on Ubuntu 15.04

Step 1. First of all, make sure that all packages are up to date.

Step 2. Add the PPA (Personal Package Archive) repository for PHP 7 in your system.

Now, install PHP 7 using the following command:

Your server should restart Apache automatically after the installation of PHP. If it doesn’t, execute this command:

Step 3. Verify the Install PHP version.

Once it is completed, you can ensure that the latest stable release of PHP 7 is installed on your system by using the command:

Step 4. Install PHP modules.

If you like to search all the available PHP 7 modules you can use to command:

You may want to install some other PHP extensions required by your applications. Here is the list:

Step 5. Testing PHP 7 on Ubuntu 15.04

To test PHP, create a test file named info.php with the content below. Save the file, then browse to it to see if PHP is working:

Congratulations! You have successfully installed PHP 7. Thanks for using this tutorial for installing PHP 7 on your Ubuntu 15.04 system. For additional help or useful information, we recommend you to check the official PHP website.

VPS Manage Service Offer
If you don’t have time to do all of this stuff, or if this is not your area of expertise, we offer a service to do “VPS Manage Service Offer”, starting from $10 (Paypal payment). Please contact us to get the best deal!