10-21-2007, 04:38 PM
|
#1 (permalink)
|
|
The Acquainted
Join Date: Sep 2007
Posts: 133
Thanks: 6
|
cURL
Hey,
Was just wondering if this little bit of code could be converted to a cURL function instead of File_get_contents, a little but stumped about how to do that with this code, was wondering if anyone could do it? thanks.
PHP Code:
function file_get_content( $url )
{
for( $i = 1; $c <= $this->conf['tries']; $c++ )
{
$file = @file_get_contents( $url );
if( $file != FALSE )
{
return array( 1 => TRUE, 2 => $file );
break;
}
}
return array( 1 => FALSE, 2 => '' );
}
|
|
|