How to Check Current PHP Version in Ubuntu?

 To check the current PHP version installed on your Ubuntu system, you can use the following command in your terminal:

php -v

This will display the version of PHP currently installed on your system. The output should look something like this:

PHP 7.4.16 (cli) (built: Mar 3 2021 13:12:21) ( NTS ) Copyright (c) The PHP Group Zend Engine v3.4.0, Copyright (c) Zend Technologies with Zend OPcache v7.4.16, Copyright (c), by Zend Technologies

In this example, the current PHP version installed is 7.4.16.


Most Popular

Remove Unicode Zero Width Space PHP

PhpStorm, return value is expected to be 'A', 'object' returned

Laravel file upload returns forbidden 403, file permission is 700 not 755