$schemamarkup = get_post_meta(get_the_ID(), 'schemamarkup', true); if(!empty($schemamarkup)) { echo $schemamarkup; }

PHP 8.1 Lubuntu Installation – Step-by-step

October 17, 2021 | By the+gnu+linux+evangelist.

Installing PHP

  1. 2. Enabling PPA Repo

    Add PHP PPA for Ubuntu GNU/Linux

    Add PHP Repo for Ubuntu
  2. 3. Installing PHP 8.1

    Now to Install PHP 8.1 on Ubuntu
    Simply play:

    sudo apt install php8.1 php8.1-cli

    This Setup includes also the most useful Extensions and Tools.
    Then Test your new Php with:

    php -v
  3. 4. Searching PHP 8.1 Extensions

    Again to Search PHP 8.1 Extensions.

    So you can Search for the available PHP 8 Extensions running:

    sudo apt search php8.1

    And possibily refine the Result using a grep Pipe

    sudo apt search php8.1 | grep [KEYWORD]

    Like for instance:

    sudo apt search php8.1 | grep mysql
    Apt Php 8 Search Results

    Last, to Install multiple Packages at once you may use the following Syntax:

    sudo apt install php8.1-{curl,xml,imagick,mysql,fpm,bz2}
  4. 5. Setting PHP Version

    (Optional) In case to Manage Multiple PHP Versions on System
    Use the Default CLI Tool:

    sudo update-alternatives --config php

    If more than One then Simply Choose the Right PHP Release Entry.

    Managing

Contents