
01-20-2012, 08:29 AM
|
|
|
Join Date: Sep 2005
Posts: 684
Благодарил(а): 0 раз(а)
Поблагодарили:
0 раз(а) в 0 сообщениях
|
|
Quote:
Originally Posted by TnT
Download fails due to missing security token when Downloads are restricted to members. If a guest tries to download he gets the Login form. After succesfull login he is redirected back to Download, but this fails due to missing security token.
My workaround is to redirect the logged in member to the download page for this file where he can start a new download of the file:
find in downloads.php around line 485:
PHP Code:
eval(standard_error(fetch_error('security_token_invalid', $vbulletin->options['contactuslink'])));
replace with:
PHP Code:
if ($permissions['downloads2permissions'] & $vbulletin->bf_ugp['downloads2permissions']['candownloadfiles'])
{
exec_header_redirect("downloads.php?" . $vbulletin->session->vars['sessionurl'] . "do=file&id=" . $file[id]);
}
else
{
eval(standard_error(fetch_error('security_token_invalid', $vbulletin->options['contactuslink'])));
}
@Jelle: Pleas add this to your repository, thanks 
|
Solved :up:
Thanks
|