On a server I have the file some.php. I try to read the contents using file_get_content and fread. Both these don't read my content.
If I try some other URL like yahoo.com, these functions are reading the contents. Why does this happen?
$my_conetn = file_get_contents("http://example.com");
echo $my_conetn;
The above snippet is not working.
$handle = fopen($filename, "r");
$contents = fread($handle, 20);
echo $contents;
fclose($handle);
Also the above snippet is not working.
How to check my server? Is there any file read operation locked or not?
edit: I am not sure, but it is only my server file that can't be read. I can read the other server links. So I contact my hosting provider, then I get back to you guys/gals.