400 & 500 Error Pages
400 & 500 Error Pages
I added the 400 & 500 Error Pages to the mod the other day on my install, if anyone wants these edits, let me know and I'll go dig them out for you
- Stoker
- Site Admin
- Posts: 3536
- Joined: 12 May 2008, 23:26
- BBCodes: 239
- Favourite BBCode: Anipro
- Favourite MOD: PrettyPhoto
- Location: Denmark
- Contact:
Re: 400 & 500 Error Pages
Some of the error pages cant be controlled by phpBB.
I am not 100% sure about the 400 bad request, but the 500 internal server error page will not be displayed because it is impossible to display any phpBB page when there is an internal server error.
I am not 100% sure about the 400 bad request, but the 500 internal server error page will not be displayed because it is impossible to display any phpBB page when there is an internal server error.
Board rules! No PM support
Re: 400 & 500 Error Pages
Previously when my host were doing a lot of upgrades, all php sites got 500 internal server errors, and it ran the error page fine, it just would'nt let you go anywhere else, lolStoker wrote:Some of the error pages cant be controlled by phpBB.
I am not 100% sure about the 400 bad request, but the 500 internal server error page will not be displayed because it is impossible to display any phpBB page when there is an internal server error.
- darkonia
- BBCoder II
- Posts: 57
- Joined: 23 May 2011, 19:40
- BBCodes: 35
- Favourite BBCode: hs bbcode
- Favourite MOD: dm video
- Location: Munich
Re: 400 & 500 Error Pages
pls post it ashley!
Re: 400 & 500 Error Pages
open up: .htaccess
Find:
Add Before:
Find:
Add After:
open up: error.php
Find:
Add Before:
Find:
Add After:
open up: language/en/mods/error.php
Find:
Add Before:
Find:
Add After:
Find:
Add Before:
Find:
Add After:
Last but no means least, upload the zip package below to styles/prosilver/template/error/
Enjoy!
Find:
Code: Select all
ErrorDocument 401 /error.php?mode=401
Code: Select all
ErrorDocument 400 /error.php?mode=400
Code: Select all
ErrorDocument 404 /error.php?mode=404
Code: Select all
ErrorDocument 500 /error.php?mode=500
Find:
Code: Select all
case '401':
page_header($user->lang['ERROR_TITLE401']);
$template->set_filenames(array(
'body' => 'error/401_body.html')
);
break;
Code: Select all
case '400':
page_header($user->lang['ERROR_TITLE400']);
$template->set_filenames(array(
'body' => 'error/400_body.html')
);
break;
Code: Select all
case '404':
page_header($user->lang['ERROR_TITLE404']);
$template->set_filenames(array(
'body' => 'error/404_body.html')
);
break;
Code: Select all
case '500':
page_header($user->lang['ERROR_TITLE500']);
$template->set_filenames(array(
'body' => 'error/500_body.html')
);
break;
Find:
Code: Select all
'ERROR_TITLE401' => '401 Authorization Required',
Code: Select all
'ERROR_TITLE400' => '400 Bad Request',
Code: Select all
'ERROR_TITLE404' => '404 Not Found',
Code: Select all
'ERROR_TITLE500' => '500 Internal Server Error',
Code: Select all
'ERROR_AUTH_REQUIRED' => 'This server could not verify that you are authorized to access the document requested.',
Code: Select all
'ERROR_BAD_REQUEST' => 'Your browser sent a request that it could not understand.',
Code: Select all
'ERROR_NOT_FOUND' => 'The requested resource could not be found but may be available again in the future.',
Code: Select all
'ERROR_SEVER_ERROR' => 'The server encountered an internal error or misconfiguration and was unable to complete your request.',
Last edited by Ashley.S. on 06 Jun 2011, 23:22, edited 1 time in total.
- Stoker
- Site Admin
- Posts: 3536
- Joined: 12 May 2008, 23:26
- BBCodes: 239
- Favourite BBCode: Anipro
- Favourite MOD: PrettyPhoto
- Location: Denmark
- Contact:
Re: 400 & 500 Error Pages
Thanks, I will check it out.
Maybe the "problem" at my server is that it is set up to use custom error pages.
Maybe the "problem" at my server is that it is set up to use custom error pages.
Board rules! No PM support
Re: 400 & 500 Error Pages
maybe, and oops I forgot that edit will add that nowStoker wrote:Thanks, I will check it out.
Maybe the "problem" at my server is that it is set up to use custom error pages.
- Stoker
- Site Admin
- Posts: 3536
- Joined: 12 May 2008, 23:26
- BBCodes: 239
- Favourite BBCode: Anipro
- Favourite MOD: PrettyPhoto
- Location: Denmark
- Contact:
Re: 400 & 500 Error Pages
I have checked this. 500 internal doesnt work on my server.
But since it is working for you I will include it in next version.
But since it is working for you I will include it in next version.
Board rules! No PM support
- darkonia
- BBCoder II
- Posts: 57
- Joined: 23 May 2011, 19:40
- BBCodes: 35
- Favourite BBCode: hs bbcode
- Favourite MOD: dm video
- Location: Munich
Re: 400 & 500 Error Pages
thx stoker and ashley!
Re: 400 & 500 Error Pages
No Problemdarkonia wrote:thx stoker and ashley!