vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 3.6 Add-ons (https://vborg.vbsupport.ru/forumdisplay.php?f=194)
-   -   End-User Options - Selective Forum Filter (https://vborg.vbsupport.ru/showthread.php?t=132279)

akanevsky 11-22-2006 10:00 PM

Selective Forum Filter
 
I no longer support my hacks. Please feel free to update them and release new versions elsewhere as long as I get the credit for the original modification.

/*================================================= =====================*\
|| Selective Forum Filter
||
|| Author : Anton Kanevsky
|| Co-Author(s) : Andreas
|| Works on : vBulletin 3.5.x - 3.8.x
|| Released : May 31, 2009
||
|| Time required to install: 30 seconds
|| Difficulty: easy
\*================================================ ======================*/

DESCRIPTION

Ever came across large boards with a huge number of sub forums? Couldn't find your info? Wanted to run away from that huge load of stupid threads? This hack is intended to save your users from having such a horrible experience. It provides them with an opportunity to exclude any number of forums from the forums list (as well as from "get new"/"get daily" searches), which still letting them to access those forums directly and search within them, too.

STATISTICS

Products to Install: 1


INTRODUCTION

To enable "can be excluded" in all forums, run this query:
UPDATE PFXforum SET excludable = 1
To disable "can be excluded" in all forums, run this query:
UPDATE PFXforum SET excludable = 0
In both cases, PFX must be replaced with the actual table prefix that you have defined in config.php.
If you have not defined a prefix, remove PFX from the queries.
After you run either one of these queries, you must then open and save any one forum for the forum cache to be updated.

VERSION HISTORY

1.1.0
[+] The hack is now compatible with vBulletin 3.5.x - 3.8.x.
[+] Eliminated all template edits.

1.0.2
[+] The hack is now compatible with vBulletin 3.6.
[+] Corrected a couple of mistakes in the installation manual.

1.0.1
[+] Added option to set forums as excludable. By default, excludability of all forums is disabled.

1.0.0
First Public Release

The installation manual is contained within the attached file.

IF YOU LIKE MY HACK, PLEASE CLICK INSTALL

akanevsky 11-23-2006 03:28 PM

First Post Reserved

Q: I have a lot of forums that I need to be able to hide, but I cannot hide them all. Help!
A: Yes, there is a limitation due to the properties of the mysql field. It is intended to hold up to 64 forums. If you need more than that, please run the following query:

[SQL]ALTER TABLE PFXusertextfield CHANGE excludeforumids excludeforumids MEDIUMTEXT NOT NULL[/SQL]

Make sure to replace PFX with your TABLE_PREFIX (it is found in config.php).

projectego 11-23-2006 03:39 PM

Thanks.

[high]* projectego clicks install :)[/high]

JD45 11-24-2006 04:17 PM

Ok, I know I must be doing something wrong, so if someone can point me in the right direction, I'd appreciate it. I went in to phpmyadmin and tried running the sql command, but I get this in return:

Code:

#1146 - Table 'justpres_forumtest.vb1_forum' doesn't exist
'vb1' is what is listed in my config.php

akanevsky 11-24-2006 04:20 PM

Quote:

Originally Posted by JD45 (Post 1124323)
Ok, I know I must be doing something wrong, so if someone can point me in the right direction, I'd appreciate it. I went in to phpmyadmin and tried running the sql command, but I get this in return:

Code:

#1146 - Table 'justpres_forumtest.vb1_forum' doesn't exist
'vb1' is what is listed in my config.php

If vb1 is listed in config.php then in query, you would use vb1forum, not vb1_forum.

JD45 11-24-2006 04:34 PM

Quote:

Originally Posted by Psionic Vision (Post 1124329)
If vb1 is listed in config.php then in query, you would use vb1forum, not vb1_forum.

That worked perfectly, thank you.

I went back in to my options and only reset exclusion shows. I followed the instructions to clear it, but nothing else shows up. Any ideas? I re-ran the installer with overwrite on just to be sure, and still no luck.

akanevsky 11-24-2006 04:42 PM

Quote:

Originally Posted by JD45 (Post 1124339)
That worked perfectly, thank you.

I went back in to my options and only reset exclusion shows. I followed the instructions to clear it, but nothing else shows up. Any ideas? I re-ran the installer with overwrite on just to be sure, and still no luck.

What exactly are you trying to do?

JD45 11-24-2006 04:43 PM

Quote:

Originally Posted by Psionic Vision (Post 1124347)
What exactly are you trying to do?

Trying to get the list of forums to show so I can select which ones not to show up when I hit new posts.

akanevsky 11-24-2006 06:52 PM

Quote:

Originally Posted by JD45 (Post 1124348)
Trying to get the list of forums to show so I can select which ones not to show up when I hit new posts.

You need to set those forums (and all of their parents) as excludable.

JD45 11-24-2006 07:10 PM

Quote:

Originally Posted by Psionic Vision (Post 1124416)
You need to set those forums (and all of their parents) as excludable.

All I had to do was save one forums setting to enable excludability and then they showed up in the user options.

Thanks for your help. :D

Kungfu 11-24-2006 08:14 PM

i cant seem to get this working even after setting the exclusions

sunnycher 11-24-2006 11:17 PM

This is the one where the members can filter forums, correct? I am using it, love it.

Isn't there one somewhere that the admin can filter the forum also?

TheEDIGuy 11-24-2006 11:52 PM

This works well. After running the query to allow all as excludable, I did have to re-save one of the forums manually to get them to show up on the list, but all else works great. The users have been asking for this one. Thanks!

nix 11-25-2006 04:11 AM

Is there a way to remove the forum from the search function but leave it on the index?

Kungfu 11-25-2006 05:24 AM

Quote:

Originally Posted by TheEDIGuy (Post 1124525)
This works well. After running the query to allow all as excludable, I did have to re-save one of the forums manually to get them to show up on the list, but all else works great. The users have been asking for this one. Thanks!

uh ok, works now. thats wierd. Thanks.

akanevsky 11-25-2006 12:01 PM

Yeah. Simply disable the plugin at cache_ordered_forums hook.

nix 11-25-2006 05:06 PM

Quote:

Originally Posted by Psionic Vision (Post 1124779)
Yeah. Simply disable the plugin at cache_ordered_forums hook.

Thanks. I thought of this last night but I forgot to run the query again. Thanks again!

nix 11-26-2006 05:06 PM

When you this there seems to be a limit with how many forums you can select. No matter how yo do it you can't select all the forums you want.

akanevsky 11-26-2006 05:18 PM

Quote:

Originally Posted by nix (Post 1125688)
When you this there seems to be a limit with how many forums you can select. No matter how yo do it you can't select all the forums you want.

Yeah, you can select a maximum of 128 forums due to the limitation of the varchar database field. However, the hack is not intended to hide all forums. It is intended to hide a selection of forums only, otherwise there is no point to visit the site at all.

nix 11-26-2006 05:19 PM

Yea I don't want it to hid all of them. But its seems we are limited to 64.

akanevsky 11-26-2006 05:49 PM

Yeah, 128 assuming forumids are all single-digits.
You can run the following query to lift the limitation:
[sQL]ALTER TABLE usertextfield CHANGE excludeforumids excludeforumids MEDIUMTEXT NOT NULL[/SQL]
Make sure to replace "usertextfield" with YOUR_TABLE_PREFIXusertextfield

nix 11-26-2006 05:53 PM

that did it. thanks.

kafi 11-28-2006 02:12 PM

wow this satsify my needs for "let user customize forum and forumhome" Currently I run 3.5 and use Opt-out forums hack but that one doesnt hid forums on forumhome...

GREAT. ASAP my vb turns 3.6 I will be back .-)

akanevsky 11-28-2006 06:14 PM

Quote:

Originally Posted by kafi (Post 1127272)
wow this satsify my needs for "let user customize forum and forumhome" Currently I run 3.5 and use Opt-out forums hack but that one doesnt hid forums on forumhome...

GREAT. ASAP my vb turns 3.6 I will be back .-)

This works on 3.5.4.

4yBak 12-10-2006 04:23 PM

I'm use version 1.0.0 of this hack and want to update it to 1.0.2: what I need to do for that? I need just install xml file or do template changes also?

Thanks.

vbreal 12-14-2006 10:23 PM

need this thanks

Ramsesx 12-15-2006 10:02 AM

Seems not to work on 3.6.4, did the template change, the querie, product import, but only showing [Reset exclusion] but no forums. Thanks.

akanevsky 12-15-2006 05:54 PM

Quote:

Originally Posted by Ramsesx (Post 1139054)
Seems not to work on 3.6.4, did the template change, the querie, product import, but only showing [Reset exclusion] but no forums. Thanks.

Forums must be set as excludable in order to be excluded.

Ramsesx 12-15-2006 07:48 PM

Got it, thanks.

Greek Wizard 12-26-2006 01:54 AM

Psionic Vision

This is a great hack, one of your best IMO.

It works great for large forums, for those users that do not want everything.

One question though... I have a user that has blocked out a catagory, however vbAdvanced still shows those threads/forum in the recent news block.

if there anything that can be added on to exclude those from there also?

Thanks

akanevsky 12-26-2006 11:20 AM

Quote:

Originally Posted by Greek Wizard (Post 1145130)
Psionic Vision

This is a great hack, one of your best IMO.

It works great for large forums, for those users that do not want everything.

One question though... I have a user that has blocked out a catagory, however vbAdvanced still shows those threads/forum in the recent news block.

if there anything that can be added on to exclude those from there also?

Thanks

Please contact the developer of vBAdvanced and ask them to respect the visibility settings of forums in the vBulletin forumcache.

Greek Wizard 12-27-2006 12:07 PM

Quote:

Originally Posted by Psionic Vision (Post 1145245)
Please contact the developer of vBAdvanced and ask them to respect the visibility settings of forums in the vBulletin forumcache.

OK, Thanks anyways,

I am sure I won't get much help over there so I might bother, it's only a minor issue right now.

I will probably be switching to vBonjour soon anyways, hopefully that one will be better.

telc 01-10-2007 06:20 PM

What exactly does "enable excludability" and "disable excludability" do? Is it needed to run this query?

Also I have around 250+ forums, is the xml file going to be updated to change the varchar to mediumtext to support larger forums.

Thanks.

Bellinis 01-14-2007 02:39 PM

First of all: thank you for this great hack!

Ok, I installed it, but don't see any forums listed in my CP options, only 'reset exclusion'.


I followed the instructions, run the query set alle forums to be excludable. Also I disabled the cache-part. Switched the exclusion option in some forums on- and off, but still no luck. Anything else I could try ? :(

Thanks. :)

Bellinis 01-14-2007 03:06 PM

I just discovered why it's not working. The problem is VBSeo. After disabling VBSeo, all worked fine. Nice, but now what?

What can I do to make it working even with VBSeo activated?

akanevsky 01-14-2007 05:39 PM

I don't know. I am not familiar with vBSEO.

telc 01-14-2007 06:12 PM

Is the xml file going to be updated to change the varchar to mediumtext to support larger forums.

Bellinis 01-15-2007 08:05 AM

Quote:

Originally Posted by Psionic Vision (Post 1159079)
I don't know. I am not familiar with vBSEO.

I asked at vbseo, and the suggested using Andreas' mod. That mod worked fine for me. :) Anyhow, thank you for your help. Too bad this mod didn't work out for me....

akanevsky 01-15-2007 12:31 PM

Quote:

Originally Posted by Bellinis (Post 1159650)
I asked at vbseo, and the suggested using Andreas' mod. That mod worked fine for me. :) Anyhow, thank you for your help. Too bad this mod didn't work out for me....

This mod is the same as that mod, except that mod only hides stuff from "get new posts", and this one also hide stuff from forums. They are both based on the same code...

RoughOcean 01-16-2007 03:37 AM

Quote:

Originally Posted by Psionic Vision (Post 1159079)
I don't know. I am not familiar with vBSEO.

I am having the same problem with a conflict with vBSEO. I really like this mod and would rather not switch to the other one. vBSEO is a mod that makes search engine friendly URLs using mod rewrite.

I hope this is a minor conflict that can be resolved someday since it seems vBSEO is getting more popular.


All times are GMT. The time now is 03:53 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.01362 seconds
  • Memory Usage 1,829KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (2)bbcode_code_printable
  • (16)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (2)pagenav_pagelink
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (40)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.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/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • printthread_start
  • pagenav_page
  • pagenav_complete
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete