opening htaccess-protected remote files
[email protected] (Michael Schüller)
| Newsgroups | php.general |
|---|---|
| Message-ID | <[email protected]> |
Hi, I tried to open (and read) htaccess-protected files with 1.file() and 2.fread() like this: 1. $url = "http://user:[email protected]"; $string = implode("\n", file($url)); 2. $url = "http://user:[email protected]"; $fd = fopen ($url, "r"); $contents = fread ($fd, 1000000); fclose ($fd); Both give me "unknown error". Can anybody help? Michael