.htaccess file inside of public_html or an appropriate subdirectory should contain the following line:
AddHandler cgi-script .phpThen, you must make sure that only PHP scripts (and all PHP scripts) end in
.php and are in the same directory as the .htaccess file or a subdirectory of it.
See also: