Hello,
I had a redirect script working, but lately it has stopped and the page in the browser just has: "The URL has moved here." I'm not sure where this is coming from or why it isn't redirecting.
$ch = curl_init();
$fp = fopen("redirecting.html", "w");
curl_setopt($ch, CURLOPT_URL, $url);
curl_setopt($ch, CURLOPT_REFERER, $referer);
#curl_setopt($ch, CURLOPT_FILE, $fp);
curl_exec ($ch);
curl_close($ch);
fclose($fp);
I added the line curl_setopt($ch, CURLOPT_FOLLOWLOCATION, 1); and it redirects fine but the original url is kept in the address bar which is not desirable.
It would be great if someone knew how to fix this.
Josh