is_readable(http://.... text file) says not, but I can in browser

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi

I'm sure this is simple for yous all but I'm not sure I know the answer.

       $myFileLast = "http://www.myDomain.com/text.txt";;
       if (is_readable($myFileLast))
       {
           $fh = fopen($myFileLast, 'r');
           $theDataLast = fread($fh, 200);
           fclose($fh);
           echo ("The dataLast: ".$theDataLast."<br>\n");
       } else
       {
           echo ("Last fix file unavailable: $myFileLast<br>\n");
       }

returns Last fix file unavailable even for a file that my browser can read. All I want to do is skip over files

This could be a very simple error, I'd appreciate a pointer. Is it permissions being different for PHP versus the browser or something? PHP is running on a different server.

Cheers
J



--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux