Version 1.0.3

Download and support for PhpBB3 Error Pages
User avatar
Nully
Donator
Donator
Posts: 258
Joined: 15 Mar 2010, 00:03
BBCodes: 10
Favourite MOD: Radios
Location: France > Bulgaria
Contact:

Version 1.0.3

Post by Nully »

Ok, thanks :)
User avatar
Stoker
Site Admin
Site Admin
Posts: 3523
Joined: 12 May 2008, 23:26
BBCodes: 239
Favourite BBCode: Anipro
Favourite MOD: PrettyPhoto
Location: Denmark
Contact:

Version 1.0.3

Post by Stoker »

I added this to error.php

Code: Select all

if (!$user->data['is_bot'] && !empty( $_SERVER['HTTP_REFERER']))
{
			header('refresh:5;url= '.$_SERVER['HTTP_REFERER']);
}
just before page_footer();
It will redirect you to previous page IF there HTTP_REFERER exists.
Nothing fancy.
Board rules! No PM support
User avatar
martin123456
BBCoder VI
BBCoder VI
Posts: 765
Joined: 25 Jul 2011, 13:29
BBCodes: 34
Favourite MOD: Ban button
Location: Down south!
Contact:

Version 1.0.3

Post by martin123456 »

Stoker wrote:I added this to error.php

Code: Select all

if (!$user->data['is_bot'] && !empty( $_SERVER['HTTP_REFERER']))
{
			header('refresh:5;url= '.$_SERVER['HTTP_REFERER']);
}
just before page_footer();
It will redirect you to previous page IF there HTTP_REFERER exists.
Nothing fancy.
Works well but if you come from another site and use this link images/ the page hangs but if your on this site and use the link it works.
User avatar
Stoker
Site Admin
Site Admin
Posts: 3523
Joined: 12 May 2008, 23:26
BBCodes: 239
Favourite BBCode: Anipro
Favourite MOD: PrettyPhoto
Location: Denmark
Contact:

Version 1.0.3

Post by Stoker »

Works fine for me no matter where I come from?
Board rules! No PM support
Locked