Forum Moderators: coopster
I use the below script that shows content from an affiliate address.
But due to security reasons i cant use fopen() anymore,but Curl instead.
Big question (for me) is,how do i change it in this code?
Any help please?..
<?php
$wi = 17176; // Uw affiliate website ID
$ws = WEBSITE_SUBID; // Uw affiliate SubID
// hieronder niets aanpassen
$qs = $_SERVER['QUERY_STRING'];
$ip = $_SERVER['REMOTE_ADDR'];
$domain = urlencode('http://'.$_SERVER['HTTP_HOST'].
$_SERVER['PHP_SELF']);
$file = 'http://www.example.com/whitelabel.php?'
.$qs
.'&wi='.$wi
.'&ws='.$ws
.'&bedankt='.$domain
.'&ip='.$ip;
$fp = fopen($file, 'r');
while(true) {
$content = fread($fp, 8192);
if (strlen($content) == 0) break;
$data .= $content;
} fclose ($fp);
print $data;
?>
This is all the code.
[edited by: jatar_k at 4:27 pm (utc) on May 12, 2007]
[edit reason] switched to example.com [/edit]