Jump to content

CURL + HTTP_X_FORWARDED_FOR


cyfer65

Recommended Posts

You can use the CURLOPT_HTTPHEADER option. Keep in mind that the name of the header is really X-Forwarded-For. So...

$ch = curl_init('http://dawhois.com/my_ip_address.php');$headers = array('X-Forwarded-For: ' . $_SERVER['REMOTE_ADDR']//Add additional headers here.);curl_setopt($ch, CURLOPT_HTTPHEADER, $headers);$result = curl_exec($ch); curl_close($ch);

[edit]Damn... beated to it :) [/edit]

Link to comment
Share on other sites

Shows the same thing...Perhaps the site uses a different technique to detect proxies, or it only assumes a proxy if the proxy's IP (i.e. your server's IP) is among a certain whitelist of known proxies.

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...