Category: PHP7

Added: 3rd of December 2020

Viewed: 479 times

What version of .php are my hosts running

If you want to check what version of PHP your host is running on their servers, you can use the phpinfo() function. Some webhosts block this for security reasons.

If this doesn't work you can use the phpversion() function in your .php scripts.

Please look at the code examples below.

<?php
// Show phpinfo file
phpinfo();
?>


Click here to view a phpinfo file.

<?php
// Print PHP Version
echo "PHP Version: " . phpversion();
?>

Other Tips & Tutorials

PHP7

What version of .php are my hosts running

Posted: 3rd of December 2020

Views: 479

PHP7

Running .php scripts from the terminal using Ubuntu

Posted: 23rd of October 2020

Views: 703