Instructions on how to check the PHP version
- Instructions for how to use Gmail offline do not need a network
- Instructions on how to compile and execute Java using Command Prompt
- Instructions on how to create 3D effects and objects in Photoshop
If you are interested in adding new features on your site or trying to identify a programming error, you may have to check the PHP version that the server is currently using. You can check the version by running a simple PHP file on the server. Or you can check the PHP version being installed on the local computer using the Command Prompt command line interpreter application or Terminal emulator. Join TipsMake.com to consult the article on how to check the PHP version below!
Method 1: Server
1. Open the text editor or code.
You can use Notepad or TextEdit but don't use text editing software like Microsoft Word.
2. Enter the following code.
When running on your server, this code will return the PHP version information.
3. Save as PHP file.
Click " File " → " Save as " and give the file a name. Add the .php extension to the end of the name. Choose a simple name, such as version.php.
4. Create a more detailed report (optional).
The above file will tell you what the current version of PHP is. However, if you want more information, such as system information, release date, available commands, API information or more, you can use the phpinfo () command. Please save the file as info.php.
5. Upload your file (s) to the server.
You may have to use the FTP client program or download it via the server's administrative control panel. Leave the file in the root directory on your server.
6. Open the file on your browser.
Once the file has been uploaded to the server, you can use the browser to download them. Find the file location on the server. For example, if you leave them in the root directory of the domain, go to www.yourdomain.com/version.php .
- To see all the data, visit www.yourdomain.com/info.php .
Method 2: Local PHP version
1. Open Command Prompt or Terminal.
If PHP is installed locally, you can use Command Prompt or Terminal to check the version. Besides, you can also do this if you use SSH to create a remote connection to the server via the command line.
- Windows - Press
⌘ Win
+R
and typecmd
. - Mac - Open the Terminal from the Utilities folder.
- Linux - Open Terminal from the screen or by pressing
Ctrl
+Alt
+T
2. Enter the command to check the version of PHP.
When running the command, the installed PHP version will be displayed.
- Windows, Mac, Linux -
php -v
3. Fix the version number error that does not appear on Windows.
A common problem with Windows users is that PHP is not in the system path, so the message 'php.exe' is not recognized as an internal or external command, operable program or batch file
(cannot Specifies 'php.exe' as internal or external commands, executable programs or batch processing files).
- Find your php.exe file location. That's usually C: phpphp.exe, but you may have changed it during the installation.
- Type
set PATH=%PATH%;C:phpphp.exe
and pressEnter
. Change the actual position if it is not currently in this position. - Rerun
php -v
. Now you will be able to see the version number.
Refer to some more articles:
- Guide the most simple and effective way to write easy-to-read code
- Instructions for uninstalling software on Ubuntu
- Instructions on how to install Ubuntu on VirtualBox virtual machine
Having fun!
You should read it
- How to view the version of Word in use
- How to check the version of macOS in use
- How to check the current Driver version of the computer
- How to Check PHP Version on Server
- How to Check PHP Version
- How to check TPM version before upgrading to Windows 11
- How to accurately check the lock or international version for iPhone
- How to check your Linux version
May be interested
- How to check your Linux versionif you need to find the actual linux version or even the linux kernel version, please read the following article.
- How to accurately check the lock or international version for iPhoneiphone international version or normal lock version has the same configuration and settings. however, the international version is always more expensive than the lock version. so how to distinguish iphone version lock from international version.
- How to check the version of Chrome browser, Coc Coc, Firefox is using is how many versionsto check if you have been upgraded to the latest version, you need to check your browser version. today, the software tips will guide you how to check the version of chrome browser, coc coc, firefox is using is how many version.
- How to check the version of Microsoft Office you are using is 32-bit or 64-bitnot only you but also many other users who are using microsoft office programs do not know the version of office you are using is 32-bit or 64-bit. if you want to know or need to know which version of office you are using is 32-bit or 64-bit, please refer to the steps in the following article of network administrator.
- How to check the Java version on Windows and macOSusers often want to check the java version before installing the latest version. in this article, tipsmake will check with you the java version easily on windows and macos.
- How to check .NET Framework version on Windows 10some software requires you to install the appropriate version of the .net framework to run, here are the two simplest and most common ways to check the .net framework version.
- Android App Version Checkschecking the application version on android will help you know if you need to upgrade the application or not, when tracking information about the new version of the application.
- How to Check PHP Versionif you're interested in implementing new features on your website, or are trying to pinpoint a bug, you may need to check the version of php that your server is currently running. you can check the version by running a simple php file on...
- How to check what version of DirectX you are usinghow to check what version of directx you are using. if you use windows operating system and play games, directx is a very familiar name. directx supports users to handle multimedia related tasks, especially graphics processing of game and video on windows platform.
- How to check the Bluetooth version on a Windows 10 computerthe article guides how to check the bluetooth version in use on computers, laptops, windows 10. click to see details!