noscript-img
HomeAboutLinux NewsResourcesPrivacy
My Computer Tips Home

How do I check what version of .php my webhosts are running

ID: 223

Category: PHP7

Added: 3rd of December 2020

Views: 2,188

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();
?>


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

FacebookSitemap Valid CSS!