when running “php” command in command prompt it gives an error like
‘php’ is not recognized as an internal or external command, operable program or batch file.
here is a solution of this problem in windows:
Important: It’s very important because if you didn’t restart your command prompt then changes will not be reflected.
Now you can check your php version from command prompt using this command :