Variables under single quotes will not be parsed !
Change this
$conn=oci_connect('user','pass','$db');
to
$conn=oci_connect('user','pass',$db); //<--- Removed the single quotes around the variable!
As Alvaro G Vicario
mentioned .. you need to enable the error reporting on your PHP code.
Add this on top of your code.
ini_set('display_errors',1);
ini_set('display_startup_errors',1);
error_reporting(-1);
You need to enable the oci
extension. Go to your PHP.ini and uncomment these lines by removing the semicolon before them , save the file and restart your webserver
;extension=php_oci8.dll
;extension=php_oci8_11g.dll