postovik
Новичок
Как побороть защиту от fsockopen ?
Проблема такая.
Брал информацию с другого сайта с помощью кода:
а сейчас такое дело уже не получается , выдает:
Access forbidden!
You don't have permission to access the requested object. It is either read-protected or not readable by the server.
If you think this is a server error, please contact the webmaster.
Судя по всему сделали защиту от импортирования.
Что это может быть и как с этим бороться?
Проблема такая.
Брал информацию с другого сайта с помощью кода:
PHP:
$header = "";
$header .= "GET $p$var HTTP/1.0\r\n";
$header .= "Host: www.sait.com\r\n";
$header .="REFERER: $GLOBALS[HTTP_REFERER]\r\n";
$header .="User-Agent: $GLOBALS[HTTP_USER_AGENT]\r\n";
$header .= "Content-Type: application/x-www-form-urlencoded\r\n";
$header .= "Conection: close\r\n\r\n";
$fp = fsockopen ('www.sait.com', 80, $errno, $errstr, 30);
if (!$fp) {
// HTTP ERROR
} else {
fputs ($fp, $header);
while (!feof($fp)) {
$aa[] = fread ($fp, 150000); };};
Access forbidden!
You don't have permission to access the requested object. It is either read-protected or not readable by the server.
If you think this is a server error, please contact the webmaster.
Судя по всему сделали защиту от импортирования.
Что это может быть и как с этим бороться?