Submit
Improve company productivity with a Business Account.Sign Up
Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.
Have a better answer? Share it in a comment.
Please enter a first name
Please enter a last name
We will never share this with anyone. Privacy Policy
Must be at least 4 characters long.
Join and Comment
By clicking you are agreeing to Experts Exchange's Terms of Use.
From novice to tech pro — start learning today.
Premium members can enroll in this course at no extra cost.
third method can get all the data although allow url fopen false...
$lookup="http://aaa.zzzz.yyyy/country.php?ip='$ip'";
//FIRST
$firstbuffer="";
$html=fopen($lookup,"rb");
while(!feof($f)){
$firstbuffer.=fread($f,409
}
fclose($f);
//SECOND
$secondbuffer=file_get_con
//THIRD
if(preg_match("/^http:\/\/([^\/]+)(.
$response ="";
$thirbuffer = '';
$host = $matches[1];
$uri = $matches[2];
$request = "GET $uri HTTP/1.0\r\n";
$request .= "Host: $host\r\n";
$request .= "User-Agent: Mozilla \r\n";
$request .= "Connection: close\r\n\r\n";
if($http = fsockopen($host, 80, $errno, $errstr, 5)){
fwrite($http, $request);
$timeout = time() + 5;
while(time() < $timeout && !feof($http)) {
$response .= fgets($http, 4096);
}
list($header, $thirbuffer) = preg_split("/\r?\n\r?\n/",
}
}