Difference between revisions of "Upgrade to PHP 8.1"
Jump to navigation
Jump to search
Line 21: | Line 21: | ||
sudo a2enmod php8.1 | sudo a2enmod php8.1 | ||
sudo systemctl restart apache2 | sudo systemctl restart apache2 | ||
=== Install commonly used php-extensions === | |||
sudo apt install php8.1-common php8.1-mysql php8.1-xml php8.1-xmlrpc php8.1-curl php8.1-gd php8.1-imagick php8.1-cli php8.1-dev | |||
php8.1-imap php8.1-mbstring php8.1-opcache php8.1-soap php8.1-zip php8.1-redis php8.1-intl -y |
Latest revision as of 18:17, 29 November 2022
sudo apt install software-properties-common sudo apt update
Add the Repository
sudo add-apt-repository ppa:ondrej/php
Next, update the system repositories to start using the PPA
$ sudo apt update
$ sudo apt install php8.1 libapache2-mod-php8.1
$ sudo systemctl restart apache2
sudo nano /etc/php/8.1/apache2/php.ini
upload_max_filesize = 32M post_max_size = 48M
Replace the current enabled PHP version with your version.
sudo a2dismod php7.4 sudo a2enmod php8.1 sudo systemctl restart apache2
Install commonly used php-extensions
sudo apt install php8.1-common php8.1-mysql php8.1-xml php8.1-xmlrpc php8.1-curl php8.1-gd php8.1-imagick php8.1-cli php8.1-dev php8.1-imap php8.1-mbstring php8.1-opcache php8.1-soap php8.1-zip php8.1-redis php8.1-intl -y