I created a php script:
#!/usr/local/bin/php
<html><head><title>PHP Test</title></head>
<body>
<?php print( "Hello World<br />"); ?>
</body></html>
created an htacces file
AddHandler cgi-script .php
DirectoryIndex index.html index.php
changed the permission
chmod 711 hello.php
chmod 644 htaccess
This does not work:
http://xyz/~username/hello.php
By making the hello.php to hello.txt the file content can be viewed on the browser. I am not sure what can be done about it?
Thanks