mirror of
https://github.com/e107inc/e107.git
synced 2025-08-18 04:12:00 +02:00
Fixes #1486 - Download error-page redirect issue.
This commit is contained in:
@@ -75,7 +75,10 @@ if(strstr(e_QUERY, "mirror"))
|
||||
header("Location: {$gaddress}");
|
||||
exit();
|
||||
}
|
||||
header("Location: ".e_BASE."download.php?error.{$download_id}.1");
|
||||
|
||||
$goUrl = e107::getUrl()->create('download/index')."?action=error&id=".$download_id;
|
||||
e107::redirect($goUrl);
|
||||
//header("Location: ".e_BASE."download.php?error.{$download_id}.1");
|
||||
exit;
|
||||
}
|
||||
}
|
||||
@@ -246,12 +249,13 @@ if ($type == "file")
|
||||
(strpos($pref['download_denied'],"signup.php") && USER == TRUE)
|
||||
))
|
||||
{
|
||||
header("Location: ".e_BASE."download.php?error.{$id}.1");
|
||||
$goUrl = e107::getUrl()->create('download/index')."?action=error&id=".$id;
|
||||
e107::redirect($goUrl);
|
||||
exit();
|
||||
}
|
||||
else
|
||||
{
|
||||
header("Location: ".trim($pref['download_denied']));
|
||||
e107::redirect(trim($pref['download_denied']));
|
||||
exit();
|
||||
}
|
||||
}
|
||||
@@ -305,7 +309,7 @@ $image = ($table == "upload" ? $upload_ss : $download_image);
|
||||
|
||||
if (strpos($image, "http") !== FALSE)
|
||||
{
|
||||
header("Location: {$image}");
|
||||
e107::redirect($image);
|
||||
exit();
|
||||
}
|
||||
else
|
||||
@@ -379,7 +383,9 @@ function check_download_limits()
|
||||
if($row['count'] >= $limits['gen_intdata'])
|
||||
{
|
||||
// Exceeded download count limit
|
||||
header("Location: ".e_BASE."download.php?error.{$cutoff}.2");
|
||||
$goUrl = e107::getUrl()->create('download/index')."?action=error&id=".$cutoff;
|
||||
e107::redirect($goUrl);
|
||||
// e107::redirect(e_BASE."download.php?error.{$cutoff}.2");
|
||||
/* require_once(HEADERF);
|
||||
$ns->tablerender(LAN_ERROR, LAN_dl_62);
|
||||
require(FOOTERF); */
|
||||
@@ -409,7 +415,9 @@ function check_download_limits()
|
||||
|
||||
if($row['total_bw'] / 1024 > $limit['gen_user_id'])
|
||||
{ //Exceed bandwith limit
|
||||
header("Location: ".e_BASE."download.php?error.{$cutoff}.2");
|
||||
$goUrl = e107::getUrl()->create('download/index')."?action=error&id=".$cutoff;
|
||||
e107::redirect($goUrl);
|
||||
// e107::redirect(e_BASE."download.php?error.{$cutoff}.2");
|
||||
/* require(HEADERF);
|
||||
$ns->tablerender(LAN_ERROR, LAN_dl_62);
|
||||
require(FOOTERF); */
|
||||
|
Reference in New Issue
Block a user