From:             [EMAIL PROTECTED]
Operating system: Windows 2000
PHP version:      4.1.0
PHP Bug Type:     HTTP related
Bug description:  fopen does not work with password-protected URLs

  I am trying to fetch the web page from my Linksys ADSL router, which is
password-protected, but fopen does not seem to understand the URL format
where a user/password is provided (like with FTP). See below.

<?php

$linksys_info_url = "http://user:[EMAIL PROTECTED]/Status.htm";;
$f_page = @fopen ($linksys_info_url, "r");
if ($f_page) {
        $page_contents = fread ($f_page, 1024);
        fclose ($f_page);
        print ($page_contents);
} else {
        echo "Can't fetch the page ($linksys_info_url), so I am giving up !!";
}
?>
-- 
Edit bug report at http://bugs.php.net/?id=15432&edit=1
-- 
Fixed in CVS:        http://bugs.php.net/fix.php?id=15432&r=fixedcvs
Fixed in release:    http://bugs.php.net/fix.php?id=15432&r=alreadyfixed
Need backtrace:      http://bugs.php.net/fix.php?id=15432&r=needtrace
Try newer version:   http://bugs.php.net/fix.php?id=15432&r=oldversion
Not developer issue: http://bugs.php.net/fix.php?id=15432&r=support
Expected behavior:   http://bugs.php.net/fix.php?id=15432&r=notwrong
Not enough info:     http://bugs.php.net/fix.php?id=15432&r=notenoughinfo


-- 
PHP Development Mailing List <http://www.php.net/>
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to