How to install PHP7.3 on Ubuntu 18.04 - Chamrong Tutorial
Table of Contents
In this tutorial, we will show you how to install PHP7.3 on Ubuntu 18.04. Why we have to install PHP version 7.3 on Ubuntu 18.04? because we want to use PHP programming to develop our web application or for other purposes. Why PHP version 7. 3 is the most stable version? because most of the other framework has built with this version. So if you install this version your server will support most of the PHP framework such as the Laravel framework, Codeigniter, OpenCart, WordPress, Joomla, etc. And why we should choose Ubuntu 18.04? because this version has used by many websites for hosting and it works well perfectly.
Prerequisites
- Ubuntu 18.04 doesn't have install PHP before
Getting Started
Run these commands below to make sure your Ubuntu server is having the latest packages.
sudo apt update
sudo apt upgrade
After running these commands your Ubuntu server's package will update to the latest packages.
Add PPA for PHP 7.3
To add PHP package and other required PHP extensions we have to add ondrej/php.
sudo apt install software-properties-common
sudo add-apt-repository ppa:ondrej/php
sudo apt update
Install PHP 7.3 for Apache
To install PHP7.3 for Apache2, you have to execute the following command below.
sudo apt install php7.3
To check your PHP installation successfully or not, please check it by running this command below.
php -v
Install PHP7.3 extensions
To install PHP extensions, we will use this syntax to installing PHP extensions.
sudo apt install php7.3-extension_name
These PHP extensions have commonly used, may you want to install them now.
sudo apt install php7.3-common php7.3-mysql php7.3-xml php7.3-xmlrpc php7.3-curl php7.3-gd php7.3-imagick php7.3-cli php7.3-dev php7.3-imap php7.3-mbstring php7.3-opcache php7.3-soap php7.3-zip php7.3-intl -y
Reconfigure php.ini file
Sometimes when you try to import SQL files via RDBMS such as phpMyAdmin, you will get an error related to the maximum size or import data issues same to the picture below.
sudo nano /etc/php/7.3/apache2/php.ini
You can readjust them by following the structure below.
upload_max_filesize = 32M
post_max_size = 48M
memory_limit = 256M
max_execution_time = 600
max_input_vars = 3000
max_input_time = 1000
Press F6 To search any text and you can press ctrl + x then press Y and hit key Enter to save this file.
Conclusion
Now, you have learned how to install PHP7.3 on Ubuntu 18.04 server. If you want to know more about how to uninstall PHP7.3 from your Ubuntu server you should read this article "How to uninstall PHP7.3 on Ubuntu 18.04 - Chamrong Tutorial".
Thank you for your time, if you have any issues or get any errors, feel free to leave the comment below. I will help you as soon as possible.


Asian Bookies | Best Online Bookies For Punters ボンズ カジノ ボンズ カジノ leovegas leovegas 839nba bets today - FBCasino
ReplyDelete