// A simple example:
$fp = fopen("my.txt","r")
;
echo gettype($fp) ;
print is_resource($fp) ? "TRUE" :
"FALSE" ;
fclose($fp) ;
// Another example
$fp =
fopen("my.txt","r") ;
fclose($fp) ;
echo
gettype($fp) ;
print is_resource($fp) ? "TRUE" :
"FALSE" ;
Both return "resource" and
"TRUE".