The following code:

    $url = "http://www.php.net/";;
    print ( implode( "", file( $url ) ));

causes my browser to sit and twiddle it's thumbs for ages and then produce:

     Warning: file("http://www.php.net/";) - Bad file descriptor in 
myfile.php on line 33

     Warning: Bad arguments to implode() in myfile.php on line 33

If, however, I explictly use the IP address:

     $url = "http://208.247.106.187/";;
     print ( implode( "", file( $url ) ));

it will successfully dump a copy of the php front page.

This says to me that PHP can't resolve names. It is not a problem
with the linux box it's running on, given that I ran "ping www.php.net"
on that particular box to find the IP address.

Can anyone tell me what I need to do to make it work?

Regs

Brian White
-------------------------
Brian White
Step Two Designs Pty Ltd - SGML, XML & HTML Consultancy
Phone: +612-93197901
Web:   http://www.steptwo.com.au/
Email: [EMAIL PROTECTED]


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]

Reply via email to