Go Back   vb.org Archive > vBulletin Modifications > vBulletin 4.x Modifications > vBulletin 4.x Add-ons
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools
HTTP Error Response Codes by BOP5 (Soft 404 Solution) Details »»
HTTP Error Response Codes by BOP5 (Soft 404 Solution)
Version: 2.2.1, by BirdOPrey5 (Senior Member) BirdOPrey5 is offline
Developer Last Online: Aug 2023 Show Printable Version Email this Page

Category: Mini Mods - Version: 4.x.x Rating:
Released: 03-10-2014 Last Update: 05-26-2014 Installs: 92
Supported Uses Plugins
Re-useable Code  

Brought to you by BirdOPrey5 / Qapla.com

This issue was brought to my attention by Sherrie at TAZ in this thread.

The issue is that when Google crawls a site and runs into the vBulletin No Permission message or other standard vBulletin error pages vBulletin gives the standard "200" HTTP response code which means everything is OK, even though there is no real content on these pages. Therefore Google considers these "soft errors" and they can damage overall SEO of your site if there are too many of them.

What this does is make vBulletin return standard HTTP "Error" responses- by default 403 (Not Authorized) for No Permission pages and 404 (Not Found) for general error messages. When Google sees these responses (as opposed to 200) it knows not to bother indexing the page and everyone is happy.

As of version 2.2 new options have been added to return custom response codes when the forum is closed or when the forum is busy. It will also send a retry header telling the crawler they can try again later. As of version 2.0 there is also a separate response code for search.php errors.

A limitation of this mod is it works best with PHP 5.4.0 or higher. As of version 2.0 If you are on an older version of PHP it may not work, but it should not cause any errors, so it is worth trying.

There are no instructions, once installed it is enabled by default. In Admin CP -> Settings -> Options -> HTTP Error Responses by BOP5 you can enable/disable the mod and choose the response codes you want for the different error types. You can use any standard HTTP response code available from this list at wikipedia.

The mod works fine on VB 3.x or 4.x including VB 3.8.8 (still in Beta) and VB 4.2.2.

To test that it is working use a free online status checker such as: http://httpstatus.io/
(Note the site will cache your result for a while so test with a unique URL each time.)

Before you install the mod any URL that will show a no-permission or other vBulletin error will show a status code of 200. After installing the same page will show a 403, 404, or other code that you have configured.

Added Boothby as a "co-author" as thanks for his contribution of code and ideas. :up:

------------------------------------------------------

Please "Mark as Installed" if you use this.
Donations always appreciated. :up:
[s]Nominate MOTM if you LOVE it! [/s] (You did, Thanks!)

Download Now

File Type: xml product-httpserrorresponsesbop5-v2.2.1.xml (7.4 KB, 238 views)

Screenshots

File Type: jpg http_codes_ss_settings-v2.jpg (107.6 KB, 0 views)

Supporters / CoAuthors

Show Your Support

  • This modification may not be copied, reproduced or published elsewhere without author's permission.
10 благодарности(ей) от:
dandanch, DemOnstar, djbaxter, Max Taxable, Mecho, Mickie D, RichieBoy67, SaN-DeeP, tbworld, TheLastSuperman

Comments
  #132  
Old 05-12-2016, 02:49 AM
hilaryl hilaryl is offline
 
Join Date: Jan 2006
Location: Brisbane, Australia
Posts: 110
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

We have had this mod installed for a good while now. The only concerning thing is the number of pages we have reported in Search Console as Access Denied.

This is the purpose of the mod - so nothing is wrong.

I'm interested though, is 403 response better than 401 response? Would 401 still report as Access Denied in Search Console?
Reply With Quote
  #133  
Old 05-14-2016, 07:13 AM
BirdOPrey5's Avatar
BirdOPrey5 BirdOPrey5 is offline
Senior Member
 
Join Date: Jun 2008
Location: New York
Posts: 10,610
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

403 is forbidden, Google might think forbidden is better than 401 but I can't say for any certainty.

What I read was that 401 is preferred when the entire site should not be accessible and 403 is prefered when it's a specific page that is not accessible.
Reply With Quote
  #134  
Old 05-15-2016, 11:16 PM
hilaryl hilaryl is offline
 
Join Date: Jan 2006
Location: Brisbane, Australia
Posts: 110
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Hi BOP5 - I've been trying to find a definitive answer too.

Surely there is a right or wrong, not just a preferred response. Obviously neither 401 or 403 are wrong, but there must be some standard. It's not as if forum pages that require a login are a new thing on web.

I will keep searching, and hopefully find something definitive.

Cheers
Reply With Quote
  #135  
Old 01-09-2017, 07:54 AM
Stratis's Avatar
Stratis Stratis is offline
 
Join Date: Jan 2010
Posts: 738
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Joe, a question. I have changed my forum to https, do I must change in plugins the code (http) to (https) ?

Thank you
Reply With Quote
  #136  
Old 01-11-2017, 11:43 AM
BirdOPrey5's Avatar
BirdOPrey5 BirdOPrey5 is offline
Senior Member
 
Join Date: Jun 2008
Location: New York
Posts: 10,610
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Nothing that I can see should have to change for https.
Reply With Quote
Благодарность от:
Stratis
  #137  
Old 01-13-2017, 09:18 AM
BadgerDog BadgerDog is offline
 
Join Date: Oct 2006
Location: Toronto
Posts: 1,789
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Installed (twice) for testing....

We use vBulletin 4.1.3 pl8...

Works great, except we have a conflict with Paul's "Display Unread Posts" mod v4.1.7.

https://vborg.vbsupport.ru/showthread.php?t=231060

When the HTTP mod is installed, Paul's mod shows the unread post count (top right corner of web site) as it should, however, when one clicks on the post number to view them, vBulletin shows page saying there are no unread posts, even though there are. You can click the "What's New" tab and the new posts show fine there.

Tried to diagnose as follows:

1. Turned HTTP mod OFF (still a conflict)
2. Disabled HTTP mod (still a conflict)
3. Uninstalled HTTP mod and Paul's "Display Unread Posts" mod v4.1.7 began to work fine again.
4. Re-insalled HTTP mod and problem returned.
5. Finally uninstalled HTTP mod and left things alone.

Hope this helps someone else ..

Regards,
Doug
Reply With Quote
Благодарность от:
djbaxter
  #138  
Old 01-14-2017, 10:06 AM
djbaxter djbaxter is offline
 
Join Date: Aug 2006
Location: Ottawa, Canada
Posts: 2,601
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by BadgerDog View Post
Installed (twice) for testing....

We use vBulletin 4.1.3 pl8...

Works great, except we have a conflict with Paul's "Display Unread Posts" mod v4.1.7.

https://vborg.vbsupport.ru/showthread.php?t=231060

When the HTTP mod is installed, Paul's mod shows the unread post count (top right corner of web site) as it should, however, when one clicks on the post number to view them, vBulletin shows page saying there are no unread posts, even though there are. You can click the "What's New" tab and the new posts show fine there.

Tried to diagnose as follows:

1. Turned HTTP mod OFF (still a conflict)
2. Disabled HTTP mod (still a conflict)
3. Uninstalled HTTP mod and Paul's "Display Unread Posts" mod v4.1.7 began to work fine again.
4. Re-insalled HTTP mod and problem returned.
5. Finally uninstalled HTTP mod and left things alone.

Hope this helps someone else ..

Regards,
Doug
Thank you. I have a similar problem with at least one forum and was unable to solve it. I thought it might have something to do with post counts not synching unread posts correctly. I am going to try your solution.

BOP5: If it is confirmed as a conflict between the two add-ons, can it be resolved?
Reply With Quote
  #139  
Old 01-14-2017, 05:50 PM
BirdOPrey5's Avatar
BirdOPrey5 BirdOPrey5 is offline
Senior Member
 
Join Date: Jun 2008
Location: New York
Posts: 10,610
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by BadgerDog View Post
Installed (twice) for testing....

We use vBulletin 4.1.3 pl8...

Works great, except we have a conflict with Paul's "Display Unread Posts" mod v4.1.7.

https://vborg.vbsupport.ru/showthread.php?t=231060

When the HTTP mod is installed, Paul's mod shows the unread post count (top right corner of web site) as it should, however, when one clicks on the post number to view them, vBulletin shows page saying there are no unread posts, even though there are. You can click the "What's New" tab and the new posts show fine there.

Tried to diagnose as follows:

1. Turned HTTP mod OFF (still a conflict)
2. Disabled HTTP mod (still a conflict)
3. Uninstalled HTTP mod and Paul's "Display Unread Posts" mod v4.1.7 began to work fine again.
4. Re-insalled HTTP mod and problem returned.
5. Finally uninstalled HTTP mod and left things alone.

Hope this helps someone else ..

Regards,
Doug
I'm sorry but that makes no sense, if the mod is disabled from Product Manager it is basically the same as being uninstalled, there are no files to upload. If you need to remove the mod for Paul's mod to work I suspect any mod removed would fix it, it may be some sort of product cache issue.

In any case only the 4.2.0 version of Paul's mod is available for download at this time. Looking at the code for that I don't see any places they would conflict.
Reply With Quote
  #140  
Old 01-14-2017, 05:57 PM
BadgerDog BadgerDog is offline
 
Join Date: Oct 2006
Location: Toronto
Posts: 1,789
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by BirdOPrey5 View Post
I'm sorry but that makes no sense, if the mod is disabled from Product Manager it is basically the same as being uninstalled, there are no files to upload. If you need to remove the mod for Paul's mod to work I suspect any mod removed would fix it, it may be some sort of product cache issue.

In any case only the 4.2.0 version of Paul's mod is available for download at this time. Looking at the code for that I don't see any places they would conflict.
The sequence is repeatable and I've installed and uninstalled the HTTP mode 3 times to validate the steps and the same results occur every time. I have left the HTTP mod uninstalled and moved on, but thank you for your efforts.... much appreciated ...

I do use Sucuri's firewall protection system, which caches our site around the world, so perhaps it's having an affect only with this mod, although I don't know why.

https://sucuri.net/

Thanks again....

Regards,
Doug
Reply With Quote
Reply


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

Forum Jump


All times are GMT. The time now is 11:13 AM.


Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.05247 seconds
  • Memory Usage 2,353KB
  • Queries Executed 28 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)ad_showthread_beforeqr
  • (3)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)modsystem_post
  • (1)navbar
  • (4)navbar_link
  • (120)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (2)pagenav_pagelink
  • (1)pagenav_pagelinkrel
  • (10)post_thanks_box
  • (12)post_thanks_box_bit
  • (10)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (3)post_thanks_postbit
  • (10)post_thanks_postbit_info
  • (9)postbit
  • (2)postbit_attachment
  • (10)postbit_onlinestatus
  • (10)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open
  • (1)tagbit_wrapper 

Phrase Groups Available:
  • global
  • inlinemod
  • postbit
  • posting
  • reputationlevel
  • showthread
Included Files:
  • ./showthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_post_thanks.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_postinfo_query
  • fetch_postinfo
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • showthread_start
  • showthread_getinfo
  • forumjump
  • showthread_post_start
  • showthread_query_postids
  • showthread_query
  • bbcode_fetch_tags
  • bbcode_create
  • showthread_postbit_create
  • postbit_factory
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • fetch_musername
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • post_thanks_function_fetch_thanks_bit_start
  • post_thanks_function_show_thanks_date_start
  • post_thanks_function_show_thanks_date_end
  • post_thanks_function_fetch_thanks_bit_end
  • post_thanks_function_fetch_post_thanks_template_start
  • post_thanks_function_fetch_post_thanks_template_end
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_attachment
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • pagenav_page
  • pagenav_complete
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete