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
Hide BBCodes/Signatures From Guests/Users Details »»
Hide BBCodes/Signatures From Guests/Users
Version: 1.8.1, by MarkFL MarkFL is offline
Developer Last Online: Jun 2020 Show Printable Version Email this Page

Category: Show Thread Enhancements - Version: 4.2.x Rating:
Released: 04-28-2015 Last Update: 02-21-2017 Installs: 42
Uses Plugins Auto-Templates
Additional Files Translations  
No support by the author.

Overview:

This product will allow you to decide what BBCode content you wish to hide from guests/users on your site. You can also choose to hide user signatures from guests/users too. Hidden content is replaced with a link to your registration page for guests, and a simple message for restricted usergroups. In posts, this link or message is placed inside a block element so that it stands out.

Guests will see the following:



Members of restricted usergroups/users that have not replied will see the following:



You are given the option to merge the defined list of BBCodes in the product "MarkFL: Enhanced View Forum Posts". This way, you may choose to define the list in one place and have both products hide the same BBCodes.

Updates:

Version 1.1:
  • Now allows usergroups to be restricted from seeing the defined list of BBCodes and signatures.

Version 1.2:
  • Posts containing the symbols "<" and/or ">" will now display correctly to those from whom BBCodes are being hidden.

Version 1.3:
  • Fixed bug where the $vbulletin array need to be global for some users.
  • Messages to guests/users now phrased to allow for translations.

Version 1.4:
  • Added setting to allow hiding of BBCodes/Signatures from users until they reply to a thread.

Version 1.5:
  • Added setting for "Active Forums" in which the product is active.
  • Added separate usergroup selection for usergroups whose members must reply to a thread before the hidden BBCodes/signatures are revealed.

Version 1.6:
  • Added setting to allow for internal links to be hidden.

Version 1.7:
  • Added settings to allow individual threads/posts to be ignored by product.

Version 1.8:
  • Fixed reported issue with inline attached images.

Version 1.8.1:
  • Moved function to external script to avoid redeclaration error.

To Install:

1.) Download and extract the attached .zip file.

Upload the contents of the "upload" folder to your forum's root directory.

Note: If you have already installed "MarkFL: Enhanced View Forum Posts" v1.1 or higher, then you may skip this step, since both products use the same external PHP script.

2.) In AdminCP go to Plugins & Products -> Manage Products -> Add/Import Product.

Click on "Choose File" and browse to the product xml file that was packaged in the .zip file.

Click "Import"

You MUST set your settings to enable the mod. Each setting has an explanation of its use.



Support for this product can be found here:

Download Now

File Type: zip MarkFL - Hide BBCodes And Signatures From Guests & Users v1.8.1.zip (8.1 KB, 164 views)

Screenshots

File Type: png hbfgpostuser.png (94.9 KB, 0 views)
File Type: png hbfgpost.png (94.2 KB, 0 views)
File Type: jpg markfl_hbfg_acp.jpg (66.1 KB, 0 views)

Show Your Support

  • This modification may not be copied, reproduced or published elsewhere without author's permission.
7 благодарности(ей) от:
akz645, Chicoynano, josedvd123, oneill, seb5594, steviewonder44, Vintum

Comments
  #102  
Old 10-01-2017, 03:07 PM
scotty's Avatar
scotty scotty is offline
 
Join Date: Oct 2001
Location: Mannheim, Germany
Posts: 70
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

same here

PHP Version 7.1.9-1+ubuntu16.04.1+deb.sury.org+1
Reply With Quote
  #103  
Old 10-02-2017, 06:42 PM
scotty's Avatar
scotty scotty is offline
 
Join Date: Oct 2001
Location: Mannheim, Germany
Posts: 70
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by MarkFL View Post
I run this on vB 4.2.5 and PHP 7.x without issue. Without more info, I'm afraid I can't help.
do you have any custom bb-codes active?
Reply With Quote
  #104  
Old 10-02-2017, 09:03 PM
MarkFL's Avatar
MarkFL MarkFL is offline
 
Join Date: Feb 2014
Location: St. Augustine, FL
Posts: 3,853
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by scotty View Post
do you have any custom bb-codes active?
Yes, quite a few actually.
Reply With Quote
  #105  
Old 10-03-2017, 04:30 AM
scotty's Avatar
scotty scotty is offline
 
Join Date: Oct 2001
Location: Mannheim, Germany
Posts: 70
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

hm.

according to the error message, there might be something in the custom_bbcodes (line #0 "append_custom_tags()"):

Code:
Call to a member function query_read_slave() on null on line 279 in /local/sites/sitehtml/includes/class_bbcode.php
#0 /local/sites/sitehtml/includes/class_bbcode.php(241): vB_BbCodeParser->append_custom_tags()
#1 /local/sites/sitehtml/includes/class_postbit.php(345) : eval()'d code(13): vB_BbCodeParser->__construct(Object(stdClass), Array)
#2 /local/sites/sitehtml/includes/class_postbit.php(345): eval()
#3 /local/sites/sitehtml/showthread.php(1097): vB_Postbit->construct_postbit(Array)
#4 {main}
any idea?
Reply With Quote
  #106  
Old 10-08-2017, 04:41 AM
Scyther's Avatar
Scyther Scyther is offline
 
Join Date: Jul 2009
Location: Planet Earth
Posts: 194
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Awesome Mod. Thanks.
Reply With Quote
Благодарность от:
MarkFL
  #107  
Old 11-01-2017, 05:59 AM
mchll9898 mchll9898 is offline
 
Join Date: Dec 2009
Location: New England
Posts: 23
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I uploaded the hidebbcodesfromguests folder to my root folder and imported the product file. I'm trying to hide IMG code from guests, but it isn't working . I have unregistered / not logged in users selected. Can you let me know if I've done anything wrong?

Reply With Quote
  #108  
Old 11-01-2017, 02:38 PM
MarkFL's Avatar
MarkFL MarkFL is offline
 
Join Date: Feb 2014
Location: St. Augustine, FL
Posts: 3,853
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Okay, try updating with the attacched .XML file and let me know if that works.
Attached Files
File Type: xml product-hidebbcodesandsigsfromque.xml (16.8 KB, 30 views)
Reply With Quote
Благодарность от:
mchll9898
  #109  
Old 11-02-2017, 02:44 AM
mchll9898 mchll9898 is offline
 
Join Date: Dec 2009
Location: New England
Posts: 23
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by MarkFL View Post
Okay, try updating with the attacched .XML file and let me know if that works.
Thank you so much! It works great now.
Reply With Quote
Благодарность от:
TheLastSuperman
  #110  
Old 12-13-2017, 11:44 AM
slash77xx's Avatar
slash77xx slash77xx is offline
 
Join Date: Dec 2015
Location: Spain
Posts: 14
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

GOOD AFTERNOON.
I HAVE INSTALLED THE product-hidebbcodesandsigsfromque.xml THE LAST VERSION, AND MY PROBLEM IS IN WHICH THE MESSAGE TO REGISTER AS IT APPEARS IN THE IMAGES YOU SHOW.
I USE VBULLETIN 4.2.5 AND PHP 7.1
SOME HELP .
Attached Images
File Type: jpg HIDE.jpg (79.8 KB, 0 views)
File Type: jpg HIDE2.jpg (63.7 KB, 0 views)
Reply With Quote
  #111  
Old 12-22-2017, 01:42 PM
Peter Walker Peter Walker is offline
 
Join Date: Oct 2005
Location: Germany
Posts: 51
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I needed this for a different reason, that a minor change to this mod made possible:

I have a premium membership system on my forum, where those that are in the Premium secondary usergroup are allowed to view videos, etc. that are displayed with custom bb codes.
Everybody else, should see a message explaining that they need to join the Premium usergroup to view the content.

As this mod does the opposite, I needed to change the code to make it work for me. With the change, it disables the named bbcodes everywhere but, for those who are members of the premium additional usergroup in the given forums.

This means that normal members see the error message, which I changed to tell them to buy a subscription, and members of the premium usergroup can now see the bbcode (videos, etc.)

After chatting with Mark about this and looking closely at the code, I was able to make this work with just a minor change to the product file and reinstalling it.

Find:
Code:
if ($vbulletin->options['markfl_hbfg_active'] AND array_intersect(explode(',', $foruminfo['parentlist']), explode(',', $vbulletin->options['markfl_hbfg_forums'])) AND !in_array($threadinfo['threadid'], array_map('trim', explode(',', $vbulletin->options['markfl_hbfg_threadsignore']))))
{
                if ($show['guest'] OR is_member_of($vbulletin->userinfo, explode(',', $vbulletin->options['markfl_hbfg_addgroups'])))
                {
                                $show['markfl_hbfg_bbcodes'] = 1;
                }
Replace with:
Code:
if ($vbulletin->options['markfl_hbfg_active'] AND array_intersect(explode(',', $foruminfo['parentlist']), explode(',', $vbulletin->options['markfl_hbfg_forums'])) AND !in_array($threadinfo['threadid'], array_map('trim', explode(',', $vbulletin->options['markfl_hbfg_threadsignore']))))
{
                if ($show['guest'] OR is_member_of($vbulletin->userinfo, explode(',', $vbulletin->options['markfl_hbfg_addgroups'])))
                {
                                $show['markfl_hbfg_bbcodes'] = 0;
                }
                else
                {
                                $show['markfl_hbfg_bbcodes'] = 1;
                }
Or simply use the attached file. Important, this changes the use of the mod, now allowing bbcodes in specific locations, it is the only way I found to do it.

Usage:
BBCode Tag Content To Hide From Guests: Give the mods that are to be activated. In my case they were the custom mods: audiop,videomp4p,videomp4vttp

Active Forums: Mark all the forums that contain premium content that use the above bbcodes.

Usergroup(s) From Which To Hide BBCodes: Set only the usergroups that are ALLOWED to use the BBCodes. e.g. Premium usergroup.

Hide BBCodes From Users Until They Reply? No Users

Usergroups Required To Reply: All

The remaining fields remain empty.

I also changed the phase displayed to:
Code:
This content is reserved for premium members only. Please obtain a premium subscription to view this content.
This is working perfectly in vb 4.2.5.
I have enclosed some images of how it works. Regular members see the blocked message while members that have Premium status can play the content - great!

Enjoy and thanks to Mark for his excellent work that just needed a little tweak.
Attached Images
File Type: jpg audioblocked.jpg (58.0 KB, 0 views)
File Type: jpg audiodisplay.jpg (42.6 KB, 0 views)
File Type: jpg audioplay.jpg (41.4 KB, 0 views)
Attached Files
File Type: xml product-hidebbcodesandsigsfromque.xml (16.8 KB, 13 views)
Reply With Quote
Благодарность от:
slash77xx
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 02:04 AM.


Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2024, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.05467 seconds
  • Memory Usage 2,389KB
  • 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
  • (4)bbcode_code
  • (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
  • (4)pagenav_pagelink
  • (11)post_thanks_box
  • (11)post_thanks_box_bit
  • (11)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (5)post_thanks_postbit
  • (11)post_thanks_postbit_info
  • (10)postbit
  • (11)postbit_attachment
  • (11)postbit_onlinestatus
  • (11)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