Register Members List Search Today's Posts Mark Forums Read

Reply
 
Mod Options
Custom HTTP Error Pages Details »
Custom HTTP Error Pages
Mod Version: 2.1.3, by JJR512 (Member) JJR512 is offline
Developer Last Online: Jun 2006 I like it Show Printable Version Email this Page

This modification is in the archives.
vB Version: 3.5.0 Rating: (4 votes - 4.50 average) Installs: 60
Released: 12 Oct 2005 Last Update: 28 Oct 2005 Downloads: 179
Not Supported Uses Plugins Template Edits Additional Files  

This is a re-write of a hack I made for vBulletin 2.x.

What this hack does is use vBulletin to generate HTTP error pages (such as the 404 - Not Found error). For those of you trying to get an all-vB-based-site, this addition will help complete your quest. Also for anyone who wants a nicer looking HTTP error message than the standard blah.

Note: Your website needs to be on a server that uses a .htaccess file, a file located in your root public directory. This may only be servers using the Apache HTTP server, I'm not sure if any other HTTP server, like Microsoft IIS, uses that or not. Some more notes on this are included in the instructions.txt file.

There are no vB files to modify. There is one file to upload, and one product to install, which will install several new templates and two plugins. The plugins are for Who's Online display. The templates contain the actual messages. No existing templates are modified.

Special thanks to KirbyDE for showing me how to group templates using a plugin rather than a code modification.

This hack has now been re-written to use phrases. If you have a previous version, here's what you can do to upgrade.
1. Upload the new httperror.php file.
2. Add the product-jjr512_httperr.xml, overwriting the existing. (All old non-used templates should be removed automatically. This version uses only two templates: HTTP_ERROR and http_error_bit.)

Download Now

Only licensed members can download files, Click Here for more information.

Supporters / CoAuthors

Show Your Support

  • To receive notifications regarding updates -> Click to Mark as Installed.
  • This modification may not be copied, reproduced or published elsewhere without author's permission.
Similar Mod
Mod Developer Type Replies Last Post
Custom HTTP Error Documents JJR512 vBulletin 2.x Full Releases 43 19 Apr 2004 07:08

  #31  
Old 14 Oct 2005, 22:32
JJR512's Avatar
JJR512 JJR512 is offline
 
Join Date: Oct 2001
Real name: Justin J. Rebbert
The first thing I originally tried, which is the bit of code you said is wrong, does actually work.

Well, let me rephrase that.

It works without using the construct_phrase function.

This is what I'm using, and it works, and is about to be uploaded:

Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.


__________________
-Justin J. "JJR512" Rebbert
www.JJR512.com: Chat about anything!

Last edited by JJR512; 14 Oct 2005 at 22:34.
Reply With Quote
  #32  
Old 14 Oct 2005, 22:41
JJR512's Avatar
JJR512 JJR512 is offline
 
Join Date: Oct 2001
Real name: Justin J. Rebbert
The hack is now updated to use phrases for, I believe, all text displayed.

If you have an earlier version, upgrade instructions are now in the hack description above.
__________________
-Justin J. "JJR512" Rebbert
www.JJR512.com: Chat about anything!
Reply With Quote
  #33  
Old 15 Oct 2005, 05:45
Andreas's Avatar
Andreas Andreas is offline
 
Join Date: Jan 2004
Real name: Andreas
Originally Posted by Dark Visor
$error['title'] = construct_phrase($vbphrase['error_title_' . $e]);
Is wrong. Try:


Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.
Hmm, why should it be wrong?

@JJR512
Wasn't the previous version a product as well?
Then you don't have to worry about old templates or such; product management will take care of that.
The User just has to reimport the XML

Last edited by KirbyDE; 15 Oct 2005 at 05:50.
Reply With Quote
  #34  
Old 17 Oct 2005, 16:40
JJR512's Avatar
JJR512 JJR512 is offline
 
Join Date: Oct 2001
Real name: Justin J. Rebbert
I didn't realize that. So when you import a product, using the overwrite, it will also remove any templates with that product's name that are not in the new version of the product? Wow. Great stuff!
__________________
-Justin J. "JJR512" Rebbert
www.JJR512.com: Chat about anything!
Reply With Quote
  #35  
Old 17 Oct 2005, 18:10
JJR512's Avatar
JJR512 JJR512 is offline
 
Join Date: Oct 2001
Real name: Justin J. Rebbert
Note: The product file has been updated to correct the "refresh" and "back" messages be actual links that will refresh the page or go back to the previous page. The links were accidentally converted to text when I was converting the original templates into phrases.

If you had the 2.1.0 version, you only need to re-add the product file, overwriting the previous version. For any other earlier version, download the new httperrors211.zip file and follow the same instructions already posted for upgrading to 2.1.0.
__________________
-Justin J. "JJR512" Rebbert
www.JJR512.com: Chat about anything!
Reply With Quote
  #36  
Old 26 Oct 2005, 15:39
oglsmm's Avatar
oglsmm oglsmm is offline
 
Join Date: May 2004
I also am getting a lot of people reported as "Viewing HTTP Error" on the Who's Online page, when i know they are not seeing an error. I don't have anything in my .httaccess file either.
__________________
vBulletin - 3.6.1
Reply With Quote
  #37  
Old 26 Oct 2005, 19:45
Snake's Avatar
Snake Snake is offline
 
Join Date: Mar 2005
Location: Cleveland, OH
Real name: Josh
Same here!
Reply With Quote
  #38  
Old 26 Oct 2005, 22:00
Delphiprogrammi Delphiprogrammi is offline
 
Join Date: Feb 2004
Real name: Erik
installed no problem found so far
Reply With Quote
  #39  
Old 26 Oct 2005, 22:04
Snake's Avatar
Snake Snake is offline
 
Join Date: Mar 2005
Location: Cleveland, OH
Real name: Josh
It's working all fine now. Thanks again.
Reply With Quote
  #40  
Old 27 Oct 2005, 13:09
JJR512's Avatar
JJR512 JJR512 is offline
 
Join Date: Oct 2001
Real name: Justin J. Rebbert
Originally Posted by Aftermath
It's working all fine now. Thanks again.
Did you do anything to fix the problem?
__________________
-Justin J. "JJR512" Rebbert
www.JJR512.com: Chat about anything!
Reply With Quote
  #41  
Old 27 Oct 2005, 13:24
JJR512's Avatar
JJR512 JJR512 is offline
 
Join Date: Oct 2001
Real name: Justin J. Rebbert
Originally Posted by Avalon111
update!

when i remove the changes in the .htaccess the problem is gone!
Originally Posted by oglsmm
I also am getting a lot of people reported as "Viewing HTTP Error" on the Who's Online page, when i know they are not seeing an error. I don't have anything in my .httaccess file either.
If you don't have anthing in your .htaccess file, how is the hack working at all? Sure, if you go to www.yourdomain.com/forums/httperror.php?e=404 you'll see the error page, but what if you go to www.yourdomain.com/xkaooe3991.html, a file which probably doesn't exist on your server, do you get the error page from my hack then? Because as far as I'm aware, custom error pages need to be "pointed" to by the .htaccess file, otherwise you get the generic error page. And if I'm wrong about that, then I guess I need to be re-educated.
__________________
-Justin J. "JJR512" Rebbert
www.JJR512.com: Chat about anything!
Reply With Quote
  #42  
Old 27 Oct 2005, 14:54
Delphiprogrammi Delphiprogrammi is offline
 
Join Date: Feb 2004
Real name: Erik
hi people,

it looks like this is not working for error code 401 (autorization requirerd) the screen that comes up if you try to login to restricted area with the wrong login information.My apache error_log shows this


Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

for this error code it must be a local document so ......


Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

should do it but nope ...
Reply With Quote
  #43  
Old 27 Oct 2005, 17:57
JJR512's Avatar
JJR512 JJR512 is offline
 
Join Date: Oct 2001
Real name: Justin J. Rebbert
Assuming that your httperror.php is in the web root (meaning not in a forums subfolder), did you try it without the beginning slash? Try it using a path name instead of a URL?
__________________
-Justin J. "JJR512" Rebbert
www.JJR512.com: Chat about anything!
Reply With Quote
  #44  
Old 27 Oct 2005, 19:52
Delphiprogrammi Delphiprogrammi is offline
 
Join Date: Feb 2004
Real name: Erik
hi,

Yes the httperror.php is in the "webroot" i didn't tryed that yet (using an aboslute pathname or remoing the slash) will give that a shot and get back to you
Reply With Quote
  #45  
Old 27 Oct 2005, 19:54
Snake's Avatar
Snake Snake is offline
 
Join Date: Mar 2005
Location: Cleveland, OH
Real name: Josh
Originally Posted by JJR512
Did you do anything to fix the problem?
Nah actually it was just a silly mistake I've made. I forgot to upload the product XML file via the admincp. The hack's working just fine!
Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Mod Options

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off


New To Site? Need Help?

All times are GMT. The time now is 23:16.

Layout Options | Width: Wide Color: