I have changed arbitroweb.php to be able to click and download a pdf file link. May be extended to any kind. Original snippet was
$fp = fopen($realURL, "r");
if($fp)
{
util_writelog("arbitroweb", $realURL, "200");
while($line=fgets($fp, 4096))
{
$line = StripSlashes($line);
I have changed arbitroweb.php to be able to click and download a pdf file link. May be extended to any kind. Original snippet was
$fp = fopen($realURL, "r");
if($fp)
{
util_writelog("arbitroweb", $realURL, "200");
while($line=fgets($fp, 4096))
{
$line = StripSlashes($line);
echo adjust_all($line);
}
fclose($fp);
}
And I have changed to
if($fp)
{
util_writelog("arbitroweb", $realURL, "200");
while($line=fgets($fp, 4096))
{
if (!isset($birkerecik)) $pdfstatus= strncasecmp ($line, "%PDF", 4);
if ($pdfstatus!=0){
$line = StripSlashes($line);
echo adjust_all($line);
$birkerecik=1;
}
else
{
header("Content-type: application/pdf");
readfile($realURL);
break;
}
}
fclose($fp);
unset($birkerecik);
}