You need to run yum in order to use PHP after setup your CentOS 7. Even though you have httpd, PHP may need to be installed manually. For compatibility with various applications like PHPMyAdmin, PHP-based server management, you will need to install additional libraries.
First of all, you need to check if you have httpd on your CentOS 7 server as following:
If it does not exist, you can install it simple as following:
If everything is okay, please run below commands to install PHP packages you need.
You may need to enable some servers just in case
Once you install above, ssh connection will be blocked by firewall in some cases. If you want to stop firewalld, you should run:
To enable external connection,
Regarding PHP settings, please refer PHP configuration I commonly use
In the PHP, error_reporting does not need to be detail necessarily for security purpose, and short_open_tag could cause coding error easily, but needs to be used for backward compatibility in some cases.
Below is what I am using for developing/operating PHP application in my servers: