PDA

View Full Version : End-User Options - Selective Forum Filter


akanevsky
05-30-2009, 10:00 PM
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 (https://vborg.vbsupport.ru/vborg_miscactions.php?do=installhack&threadid=215001)

akanevsky
05-31-2009, 03:41 PM
~~~~~~~~~~~~~~
~~~~~ Translations ~~~~~
~~~~~~~~~~~~~~~~

Russian (RU) (https://vborg.vbsupport.ru/showpost.php?p=1825561&postcount=24) - by TAIFUN_T

Biker_GA
05-31-2009, 03:44 PM
You've permission from the original author? https://vborg.vbsupport.ru/showthread.php?t=91025

marshal_ramdev
05-31-2009, 03:54 PM
will check it out :)

Stifmeister2
05-31-2009, 04:32 PM
Damn I don't fully understand this:

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


Do I need to run one of these queries in order to make this work???

akanevsky
05-31-2009, 04:36 PM
Damn I don't fully understand this:




Do I need to run one of these queries in order to make this work???

You do not. The hack, by default, sets all of the forums as excludable. You only need to run the queries if you want to set everything to "not excludable" or back again.

puertoblack2003
05-31-2009, 06:43 PM
You've permission from the original author? https://vborg.vbsupport.ru/showthread.php?t=91025

i guess so buddy if his name is included in the supported slot.

akanevsky
05-31-2009, 08:57 PM
You've permission from the original author? https://vborg.vbsupport.ru/showthread.php?t=91025

I certainly do. Thanks for asking, though. :)

Stifmeister2
06-01-2009, 04:08 PM
You do not. The hack, by default, sets all of the forums as excludable. You only need to run the queries if you want to set everything to "not excludable" or back again.
Ohh ok thanks. :)


I'll probably install this as soon as I have time, nice hack! ;)

W!cKeD
06-01-2009, 06:53 PM
This Hack is very nice, but i have a Feature Request:

Usergroup-Permission "Usergroup can exclude forums?"

Thanks in Advance :)

Trek
06-02-2009, 06:08 PM
I'd been tossing around this idea in my head for a while now and just happened upon this today. Excellent work, installed and rated!

One thing that I'd like to see is support for VBA on this. The Recent Threads module that I use on my front page still shows all threads that are new (of course). I'd like to make it so that this module also used the settings the users have selected using your mod. Probably not very hard if I pick apart your mod and grab the correct SQL query, but... you probably know how to best go about it. Any chance you'd modify the VBA recent threads module to support this?

Trek
06-02-2009, 06:21 PM
Another suggestion. As already mentioned, the usergroup perm allowing someone to exclude forums would be awesome.

At the very least though, a way to edit the forum exclusions the way you have them now. I just edited the database directly right now, but in the future a menu that will quickly allow you to edit which you can exclude or not at once would be awesome.

EagleNick
06-03-2009, 09:57 PM
Do I have to upgrade if using the 3.6.x version (https://vborg.vbsupport.ru/showthread.php?t=132279)? Or are there no major changes?

akanevsky
06-03-2009, 11:43 PM
If everything is working properly, you don't need to upgrade. However, if you want to get rid of template edits, you may still consider it. :)

TalkVirginia
06-04-2009, 08:19 AM
Thanks for bringing this one back! I've been waiting for this one. :)

Raug
06-04-2009, 02:34 PM
While I like the idea of this, would it be possible to make it that only some forums can't be excluded instead of all or nothing?

Trek
06-04-2009, 03:44 PM
While I like the idea of this, would it be possible to make it that only some forums can't be excluded instead of all or nothing?

Edit the database manually is what I did.

Trek
06-04-2009, 04:09 PM
Would it be possible to add a checkbox in the user CP for "Do not display forums in forum list"?

Basically, I'd like to still be able to see the forums in the forum list, but only report new posts in the forums I've selected. Would be nice if it was a global setting and then allowed users to change it to what they would like to see for each person.

akanevsky
06-04-2009, 05:15 PM
While I like the idea of this, would it be possible to make it that only some forums can't be excluded instead of all or nothing?

There is a forum setting to do that.

Walter
06-06-2009, 02:39 PM
Thank you for the hack!

A small bug occured: the settings in the user control panel work only in IE and Firefox, in Opera the list of the forums is scrollable but the forums actually don't scroll so the feature is not usable in Opera....

KrisP
06-06-2009, 04:18 PM
Great mod. Would it be possible to make a small modification so posts and threads dosent pop up in search results at all?

akanevsky
06-06-2009, 07:33 PM
Thank you for the hack!

A small bug occured: the settings in the user control panel work only in IE and Firefox, in Opera the list of the forums is scrollable but the forums actually don't scroll so the feature is not usable in Opera....

That's weird. Can you please link me to your site so that I can see what is going on?

Great mod. Would it be possible to make a small modification so posts and threads dosent pop up in search results at all?

Are you talking about posts and threads from the hidden forums? The hidden forums are searchable so that users can still access them directly if they want to. However, results from those forums should not appear during a regular search.

KrisP
06-07-2009, 12:11 PM
Well, if I do a "quick search" in the top of the screen, regular search results for hidden threads and posts do pop up. I am using "Selective Forum Filter v1.1.0 for vBulletin v3.5.x - 3.8.x ".

TAIFUN_T
06-08-2009, 10:40 AM
Anton Kanevsky, hello :)
I respect you as a Coder.

You plan to introduce a SQL query to the option? To not ever manually run queries
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

===
Russian Version

YISRAEL
06-08-2009, 10:45 AM
תודההההה

akanevsky
06-08-2009, 12:19 PM
Anton Kanevsky, hello :)
I respect you as a Coder.

You plan to introduce a SQL query to the option? To not ever manually run queries


===
Russian Version

Sorry, I was not planning on adding such a feature.

Thank you for the Russian translation.

TWood
06-13-2009, 12:10 PM
Is there a way to set the forum so that it is pre-filtered depending on the incoming link to the forum? For example, let's say I have a website front page with three hyperlinks labeled 1,2 and 3. The master list of forums are also 1,2 and 3. But when a user clicks on 2 on the website front page for example, vBulletin only shows forum 2 to that user.

Robbed
06-16-2009, 03:01 PM
Psionic is it possible to add an option in the usercp to check off if they want to exclude the forums or just from new posts and search.

Right now i have this disabled cache_ordered_forums

mattdonders
06-24-2009, 01:32 PM
Thanks for this!

Installed!

woostar
06-24-2009, 03:58 PM
This doesn't seem to work with vBSEO. Can anyone confirm this or is it just me?

Merjawy
06-30-2009, 09:54 AM
Is there a limit to how many forums you can exclude?.. I marked alot and when I go back to the forum some are not excluded..

otherwise its a great mod.. thanks... installin

EDIT: Nevermind,, I was marking subforums main forums.. I don't see them now.. its new test board so I don't know about the posts ... Thanks

Keesa
07-06-2009, 09:59 AM
Psionic is it possible to add an option in the usercp to check off if they want to exclude the forums or just from new posts and search.

Right now i have this disabled cache_ordered_forums

I would like to know this as well. I only want to use this for "new posts"

@ Robbed... what does this mean you have cache_ordered_forums disabled?

Sal Collaziano
07-10-2009, 02:13 PM
For some reason I cannot get this file to unarchive on my desktop. Is there another way to download it?

Hostboard
07-10-2009, 03:31 PM
I only use WinRAR and just waws able to unarchive it. If you PM me your email address I'll send you the XML and TXT file.

akanevsky
07-11-2009, 09:19 PM
You should try to unpack the file using WinRar or WinZip on Windows, or 7-Zip if you are running linux.

Robbed
07-16-2009, 12:50 AM
I would like to know this as well. I only want to use this for "new posts"

@ Robbed... what does this mean you have cache_ordered_forums disabled?

under the pluggins in admincp you can disable this and it will still show the forums but will exclude them from search and new posts.

It would be nice to have the user choose which option they like.

MacHack
07-21-2009, 02:55 PM
I'd been tossing around this idea in my head for a while now and just happened upon this today. Excellent work, installed and rated!

One thing that I'd like to see is support for VBA on this. The Recent Threads module that I use on my front page still shows all threads that are new (of course). I'd like to make it so that this module also used the settings the users have selected using your mod. Probably not very hard if I pick apart your mod and grab the correct SQL query, but... you probably know how to best go about it. Any chance you'd modify the VBA recent threads module to support this?

I agree great mod!

I am wondering the same thing about the "Recent Threads" option as well, any way of doing this myself??

Ov3rrun
07-29-2009, 04:38 AM
What to fix to work with vbadvanced last posts module????

DC Staff
07-31-2009, 12:24 AM
Great mod.

Only thing would be nice to have can be excluded and can not be excluded in the admincp.

nascartr
07-31-2009, 03:19 AM
Great mod.

Only thing would be nice to have can be excluded and can not be excluded in the admincp.


In each forum in the forum manager via your admincp there is the option Yes/No for "Can Be Excluded"

Freesteyelz
08-03-2009, 11:56 AM
Cool mod, Psionic Vision and Andreas. :)



Would it be possible to add a checkbox in the user CP for "Do not display forums in forum list"?

Basically, I'd like to still be able to see the forums in the forum list, but only report new posts in the forums I've selected. Would be nice if it was a global setting and then allowed users to change it to what they would like to see for each person.

I'd like to also be able to see the forums displayed without editing the product file. I was able to suppress New Posts searches and have the forums still display by removing roughly 13 lines of codes from the product XML:


<plugin active="1" executionorder="5">
<title>SFF: Suppress Display of Excluded Forums</title>

code bits...

</plugin>



I can't say that it's efficient or if it's upsetting vBulletin protocol but the tests so far seem to work.

paintballer.ie
08-13-2009, 12:30 AM
I am also using the 'unread post hacks'
https://vborg.vbsupport.ru/showthread.php?t=197485&highlight=unread+posts

Event though I have selected some forums to be excluded, this other hack still says I have x posts unread in those hidden forums.

Any work around for this, or will I just have to live with it?

akanevsky
08-15-2009, 12:50 PM
Cool mod, Psionic Vision and Andreas. :)





I'd like to also be able to see the forums displayed without editing the product file. I was able to suppress New Posts searches and have the forums still display by removing roughly 13 lines of codes from the product XML:


<plugin active="1" executionorder="5">
<title>SFF: Suppress Display of Excluded Forums</title>

code bits...

</plugin>



I can't say that it's efficient or if it's upsetting vBulletin protocol but the tests so far seem to work.

I have written plugin titles that are pretty much self explanatory. They do not perform any unexpected actions, as far as I am concerned... So if you disable the plugins that say that they disable display of excluded forums, that should do the trick for you.

I am also using the 'unread post hacks'
https://vborg.vbsupport.ru/showthread.php?t=197485&highlight=unread+posts

Event though I have selected some forums to be excluded, this other hack still says I have x posts unread in those hidden forums.

Any work around for this, or will I just have to live with it?



The thread for that modification says "Version 3.8.001 adds support for forums excluded if you have the "Get New/Get Daily Opt Out Modification" installed (by Andreas).". Maybe Paul also supports this hack? Please ask him, it should be pretty much the same piece of code to support either hack.

Freesteyelz
08-18-2009, 08:50 PM
I have written plugin titles that are pretty much self explanatory. They do not perform any unexpected actions, as far as I am concerned... So if you disable the plugins that say that they disable display of excluded forums, that should do the trick for you.



:o I have no idea why I didn't think of disabling the plugin. :p That did the trick and is more practical than my work around. Thanks, Psionic! :)

Saint_ago
08-26-2009, 01:52 PM
Thank you for the hack!

A small bug occured: the settings in the user control panel work only in IE and Firefox, in Opera the list of the forums is scrollable but the forums actually don't scroll so the feature is not usable in Opera....

That's weird. Can you please link me to your site so that I can see what is going on?

Same here!

http://www.battlecentral.xpg.com.br/forum/

Works fine on IE and FF, but in Opera don't.. :/

djvj
09-05-2009, 05:12 AM
Awesome, awesome! Thanks for this great hack, exactly what I needed.

glennybee
10-06-2009, 05:09 PM
This doesn't seem to work with vBSEO. Can anyone confirm this or is it just me?

When I install the product it says "Importing Product, Please Wait.." but it never installs.

I also have vBSEO installed and it would be great if this mod could be altered to work with vBSEO. I guess it has something to do with the urls.

CristianoDiaz
10-08-2009, 02:29 PM
I am having a problem with this hack - it previously has worked fine, but now, the list of forums to filter in User CP is blank - it only has Reset Exclusions at the top. There are multiple forums set to be excludable, and it was fine in the past Any ideas what might be causing this to happen?

guvner
10-08-2009, 08:08 PM
Excellent mod - many thanks!

Mike :)

Crazy-Achmet
10-16-2009, 12:23 PM
I am having a problem with this hack - it previously has worked fine, but now, the list of forums to filter in User CP is blank - it only has Reset Exclusions at the top. There are multiple forums set to be excludable, and it was fine in the past Any ideas what might be causing this to happen?

I'm having the same problem! :(

paintballer.ie
10-17-2009, 07:07 PM
What to fix to work with vbadvanced last posts module????

I am too am looking for a fix for this. The recent threads block is literally constantly blocked with threads that are filtered out.

akanevsky
10-25-2009, 05:11 PM
I am too am looking for a fix for this. The recent threads block is literally constantly blocked with threads that are filtered out.

What's the problem with it?

Rickeo
10-25-2009, 07:49 PM
Amazing addition just what I needed :)

yesfans
11-09-2009, 12:14 AM
I can still see the forums blocked in my NEW POSTS and LAST 3 DAYS POSTS feature on my site. Is it supposed to do that?

yesfans
11-09-2009, 12:18 AM
evermind

MoMan
11-13-2009, 05:03 PM
I'd just like to say that this is probably one of the most elegant modifications I've seen in a while. Installed and 5/5!

autje
11-23-2009, 03:39 PM
I importd the product file, but I see no change? I'm under the impression something should appear in my User CP under 'Miscellaneous', but... nothing?

CarlitoBrigante
11-23-2009, 07:29 PM
I am having a problem with this hack - it previously has worked fine, but now, the list of forums to filter in User CP is blank - it only has Reset Exclusions at the top. There are multiple forums set to be excludable, and it was fine in the past Any ideas what might be causing this to happen?

Found out this issue occurs if you have vBSEO installed. At that stage of the processing of the page, vBSEO has added links to the forumcache array, so the check done in the plugin SFF: User Options won't work as it should and will effectively make the forum select box empty, since all forums have been assigned a link by vBSEO

A simple solution is to change the "Direct Category Links" option in your vBSEO Control Panel to "No". Otherwise, you could modify the code of the plugin build the forum list before vBSEO intercepts it, but I have not tried.

MrD
11-25-2009, 09:50 PM
Hi,
will this Addon ported for vb4?

StarFire
11-26-2009, 04:51 AM
Thanx a lot! Quite a few of my users were begging for this.

SledgeHead
12-21-2009, 10:58 PM
Will this be available for 4.0?

al_rhar
01-08-2010, 11:03 AM
Excellent thanks. My users have been moaning about having this option for ages. works fine on 3.8.4

CyberRanger
01-12-2010, 03:25 PM
Will this be available for 4.0?
I would be ever so grateful! I stupidly updated my forum to vb4 without realizing I'd break this product.

Fiel
01-25-2010, 06:47 AM
I was able to get this to work with vB4. The plugin "SFF: User Options" has to be changed to work with the new template engine used with vB4. Learning a little PHP never hurt, right?

Fiel
01-28-2010, 04:32 PM
Since I've been getting a steady stream of questions regarding the update to vB4, here's how you update to vB4:

The only problem with this hack in vB4 is that it doesn't appear correctly in the UserCP. This is due to vB4 using a new template creation engine (which is much, much easier to use - makes it obvious which variables are available to templates and which are not). As of right now, the templates are using variables that they don't have access to, so it doesn't work. These modifications fixes it to work with vB4:

AdminCP --> Products & Plugins --> Plugin Manager --> "SFF: User Options"

Replace this:


else
{
$optionselected = '';
}
eval('$optoutforumbits .= "' . fetch_template('option') . '";');
}

$find_string = '$customfields[other]';
$add_string = fetch_template('modifyoptions_excludeforums');
$vbulletin->templatecache['modifyoptions'] = str_replace($find_string, $find_string . $add_string, $vbulletin->templatecache['modifyoptions']);



With this:


else
{
$optionselected = '';
}
$templater = vB_Template::create('option');
$templater->register('optionvalue', $optionvalue);
$templater->register('optiontitle', $optiontitle);
$templater->register('optionclass', $optionclass);
$templater->register('optionselected', $optionselected);
$optoutforumbits .= $templater->render();
}

$templater = vB_Template::create('modifyoptions_excludeforums') ;
$templater->register('optoutforumbits', $optoutforumbits);
$template_hook['usercp_options_other'] .= $templater->render();


Make sure you save it.

Then go back into the plugin manager and edit "SFF: Cache Templates". This plugin is trying to access a variable which doesn't exist in vB4.

Change this:


if (THIS_SCRIPT == 'profile')
{
$globaltemplates = array_merge($globaltemplates, array(
'modifyoptions_excludeforums',
));
}


To this:


if (THIS_SCRIPT == 'profile')
{
$cache = array_merge($cache, array(
'modifyoptions_excludeforums',
));
}


Now you need to change user options to allow the user to select it. For this hack, the creator included his own template (modifyoptions_excludeforums), but that works with vB3 and needs updating for vB4.

So, go to Styles & Templates --> Style Manager --> YOUR_STYLE_HERE --> "Modify User Template Options" --> "modifyoptions_excludeforums"

Replace the entire template contents with this:


<div class="blockrow">
<legend>{vb:rawphrase exclude_forums_title}</legend>
<p class="description">{vb:rawphrase exclude_forums_desc_1} <br /> <br />{vb:rawphrase exclude_forums_desc_2}</p>
<div class="group">
<select style="width: 50%" size="13" name="excludeforumids[]" id="sel_excludeforumids" multiple="multiple">
<option value="">{vb:rawphrase exclude_none}</option>
{vb:raw optoutforumbits}
</select>
</div>
</div>


And you're done. It should work fine and dandy now.

CyberRanger
01-28-2010, 05:14 PM
Thanks!

But I'm still getting

Warning: array_merge() [function.array-merge]: Argument #1 is not an array in [path]/includes/class_bootstrap.php(1146) : eval()'d code on line 5

at the top of the user profile pages.

In SFF: Cache Templates, do you still have -

if (THIS_SCRIPT == 'profile')
{
$globaltemplates = array_merge($globaltemplates, array(
'modifyoptions_excludeforums',
));
}

Fiel
01-28-2010, 06:20 PM
Ah, my bad. Forgot to say that I did correct that error too.

At that point in the script, $globaltemplates is not defined (nor is it ever). Change it to this:


if (THIS_SCRIPT == 'profile')
{
$cache = array_merge($cache, array(
'modifyoptions_excludeforums',
));
}

CyberRanger
01-28-2010, 06:34 PM
At that point in the script, $globaltemplates is not defined ...
Awesome! That made the error go away but (always a but!) the template modifyoptions_excludeforums isn't showing up anywhere in the user profile.

Should it still display on the profile.php?do=editoptions page?

Fiel
01-28-2010, 06:39 PM
Yes, that's where it displays for me. I know that we've been PMing each other. Make sure you're using the version of the script I posted, not the one I PMed (they are different versions).

CyberRanger
01-28-2010, 07:03 PM
.. not the one I PMed (they are different versions). duh! I didn't notice that. Now I have the forum listing under profile.php?do=editoptions. I've successfully tested modifying the forums selected and seeing that the changes are saved ...

but ...

when I do "New Posts", new posts from the exclude forums are still showing. :eek:

Fiel
01-28-2010, 07:38 PM
Thanks for catching that. Now we've got a serious problem on our hands.

If you click on the "SFF: Exclude Forums From Search" you'll notice in the combo box that there is no hook location. I looked in the PHP files and the hook location needed for this plugin to work in vB4 is non-existant. So in order for it to work, you're going to have to submit a ticket to vBulletin or add in your own hook.

I filed a vB4 bug report. Hopefully this hook will be included with 4.0.2:

http://www.vbulletin.com/forum/project.php?issueid=35758

Thanks for catching that bug. Sharp eye.

EDIT: The bug has been accepted and will be fixed in 4.0.3.

CyberRanger
01-29-2010, 12:32 AM
Thanks for posting the bug report. I tried sticking ($hook = vBulletinHook::fetch_hook('search_getnew_start')) ? eval($hook) : false; at line 1115 in search.php but that didn't work. Given how the old search.php is 3761 lines vs 1155 lines in the new search.php, I guess I shouldn't be surprised that didn't work.

I'll look some more in the morning but I think this requires a vb god with much greater knowledge than I have!

rwoscott
03-13-2010, 03:28 AM
Will this be available for 4.0?

+1, please

scottct1
03-15-2010, 01:34 PM
This is the only mod which is holding me back from switching to VB4. I need this one!

TheChaosFactor
03-16-2010, 02:40 AM
@Fiel -

Thanks a million man. People were going to be upset if I had to tell them this one wouldn't make the jump with us...

mandingo
03-16-2010, 06:30 AM
So this works for 4+ if we edit all that stuff up there?^^ or is there going to be a legit release?

Tettinntil
03-29-2010, 01:43 PM
We have a modified "new posts" search on the forum; http://myforum/search.php?do=getnew&f=xx , where xx is a forum with many sub forums. The members choices for which forums to filter from new posts search do not work on this modified search. Is there anything I could do to make it work?

stevebullman
04-04-2010, 09:11 AM
ive installed this and it seems to be working fine, very good mod......

is there a way to set my off topic forums so as default they dont appear in todays posts/unread posts, and members and choose to include them if they want?

scottct1
04-21-2010, 07:43 PM
EDIT: The bug has been accepted and will be fixed in 4.0.3.
4.0.3 is out... is this fully working yet on vB4?

profanitytalker
04-28-2010, 06:53 PM
This is just the hack I was looking for! Thank you!

Artes_Marciales
04-29-2010, 06:47 PM
Nice mod!
THANKS!!!!

Artes_Marciales
05-03-2010, 04:27 PM
Is strange, not work for my : S
https://vborg.vbsupport.ru/
Any idea?

MjrNuT
05-13-2010, 03:04 PM
Hi, would someone kindly explain this in crayons?

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.

I just don't understand what it's saying!

AngelBlue
05-23-2010, 03:31 AM
Is strange, not work for my : S
https://vborg.vbsupport.ru/
Any idea?

Are all your top-level forums set to be categories, with sub-forums underneath them?

If so, try opening the plugin "SPF: User Options", and replacing:

if (trim($forum['link']))
{
return false;
}

With:

if (($forum['options'] & $vbulletin->bf_misc_forumoptions['cancontainthreads']) AND trim($forum['link']))

Samish
05-23-2010, 09:58 AM
How can you make it so that some Forums do not show up in the list so 'have to be viewed'?

Artes_Marciales
05-23-2010, 01:44 PM
Are all your top-level forums set to be categories, with sub-forums underneath them?
Yes.

Are all your top-level forums set to be categories, with sub-forums underneath them?

If so, try opening the plugin "SPF: User Options", and replacing:

if (trim($forum['link']))
{
return false;
}

With:

if (($forum['options'] & $vbulletin->bf_misc_forumoptions['cancontainthreads']) AND trim($forum['link']))

THANKS for reply, but d?ont wok for my :confused:
Any idea?

Tettinntil
05-23-2010, 02:20 PM
We have a modified "new posts" search on the forum; http://myforum/search.php?do=getnew&f=xx , where xx is a forum with many sub forums. The members choices for which forums to filter from new posts search do not work on this modified search. Is there anything I could do to make it work?
Any help on this?

AngelBlue
06-02-2010, 06:46 AM
Here's how I got this working with vb4:

Import attached version of the product, allowing overwrite. (this is the standard product, but with Fiel's changes included)
Edit your 'navbar' template. Add: "&exclude={vb:raw bbuserinfo.excludeforumids}" to the end of all links which go to search.php, and which contain both "do=getnew" and "contenttype=vBForum_Post" in the URL.

thefnool
06-04-2010, 11:40 AM
Hey — love the look of this, but is there any way to get it to apply to forums that aren't listed on the index? I have a few boards that are linked to through unconventional means and aren't present on the index at all, and as such they don't turn up on the menu in the user control panel. My goal is to allow people to filter certain forums/sections out and prevent them from appearing on areas like the "new posts" page.

Cheers.

Trek
07-04-2010, 05:33 AM
Here's how I got this working with vb4:
Import attached version of the product, allowing overwrite. (this is the standard product, but with Fiel's changes included)
Edit your 'navbar' template. Add: "&exclude={vb:raw bbuserinfo.excludeforumids}" to the end of all links which go to search.php, and which contain both "do=getnew" and "contenttype=vBForum_Post" in the URL.

Works perfectly, excellent work, thank you!

Trek
07-04-2010, 06:33 AM
So I installed this, then realized it wasn't working with PaulM's Unread Posts mod.

There is probably a better way to get this to work with it, but this is what I did.

Open Plugin: Unread Posts and Reputation, Hook: Parse Templates

Find:

$eforums = unserialize($vbulletin->options['dupexcl']);

Add under it:

$eforums2 = explode(",", $vbulletin->userinfo['excludeforumids']);


Find:

in_array($xid,$eforums)

Add under it:

OR in_array($xid,$eforums2)

That should be it!

Hopefully this helps someone else using the same mod. =) Keep in mind though if/when Paul updates his mod, you'll have to make these changes again.

Robbed
07-11-2010, 07:25 PM
Here's how I got this working with vb4:

Import attached version of the product, allowing overwrite. (this is the standard product, but with Fiel's changes included)
Edit your 'navbar' template. Add: "&exclude={vb:raw bbuserinfo.excludeforumids}" to the end of all links which go to search.php, and which contain both "do=getnew" and "contenttype=vBForum_Post" in the URL.

Thanks, it's working now.

Fraxter
07-18-2010, 02:49 PM
An update for vB4 would be the best and easiest way. I hope Psionic Vision will do it soon.

mikexxx
07-21-2010, 02:14 PM
If i use this mod in vb4 the layout is not good.

El Orans
07-27-2010, 06:12 PM
If i use this mod in vb4 the layout is not good.Template modifyoptions_excludeforums is easily changed. :)

benstillman
10-13-2010, 07:45 PM
Same here!

http://www.battlecentral.xpg.com.br/forum/

Works fine on IE and FF, but in Opera don't.. :/

Same problem here.

scottct1
10-29-2010, 03:29 PM
I am running this on vBulletin 4 and it has been working fine but I have a few issues

1) I added a new forum and its not being displayed in the list to be able to block it. How do I get the new forum to show?

2) People are upset they are seeing results in excluded forums in their searches, how do I get this to work with all searches?

Thank you for your help!

onealien
10-29-2010, 09:37 PM
geez...large board...huge forums...huge load of threads...

wat a great problem to have...lolll...ill save this until i can get on yur level...thanks

scottct1
10-29-2010, 09:53 PM
I have problem #1 fixed. Didnt set the forum to be allowed to be excluded. (DOH!)

BirdOPrey5
10-30-2010, 05:04 PM
They need to install this here on vbulletin.org!

wmlvb
12-05-2010, 10:16 AM
keep trying to download but getting a download failed message.

BirdOPrey5
12-05-2010, 12:57 PM
Maybe try another web browser because it's working for me...

Artes_Marciales
12-06-2010, 06:53 AM
VB 3.8.6
Is strange, not work for my : S
https://vborg.vbsupport.ru/
Any idea?

blue6995
12-29-2010, 07:55 AM
Here's how I got this working with vb4:

Import attached version of the product, allowing overwrite. (this is the standard product, but with Fiel's changes included)
Edit your 'navbar' template. Add: "&exclude={vb:raw bbuserinfo.excludeforumids}" to the end of all links which go to search.php, and which contain both "do=getnew" and "contenttype=vBForum_Post" in the URL.

Where would I insert "&exclude={vb:raw bbuserinfo.excludeforumids}" and do I need to include the quotes "at each end"

I have this line for instance - <li><a href="search.php?{vb:raw session.sessionurl}
do=getnew&amp;contenttype=vBForum_Post">{vb:rawphrase new_posts_nav}</a></li>

Where in it would I insert "&exclude={vb:raw bbuserinfo.excludeforumids}"

Thanks

BirdOPrey5
12-29-2010, 12:51 PM
Where would I insert "&exclude={vb:raw bbuserinfo.excludeforumids}" and do I need to include the quotes "at each end"

I have this line for instance - <li><a href="search.php?{vb:raw session.sessionurl}
do=getnew&amp;contenttype=vBForum_Post">{vb:rawphrase new_posts_nav}</a></li>

Where in it would I insert "&exclude={vb:raw bbuserinfo.excludeforumids}"

Thanks

You'd make it:


<li><a href="search.php?{vb:raw session.sessionurl}
do=getnew&exclude={vb:raw bbuserinfo.excludeforumids}&amp;contenttype=vBForum_Po st">{vb:rawphrase new_posts_nav}</a></li>

blue6995
12-29-2010, 01:52 PM
You'd make it:


<li><a href="search.php?{vb:raw session.sessionurl}
do=getnew&exclude={vb:raw bbuserinfo.excludeforumids}&amp;contenttype=vBForum_Po st">{vb:rawphrase new_posts_nav}</a></li>


Very many thanks. That worked

Mellow
12-30-2010, 01:00 PM
So I installed this, then realized it wasn't working with PaulM's Unread Posts mod.

There is probably a better way to get this to work with it, but this is what I did.

Open Plugin: Unread Posts and Reputation, Hook: Parse Templates

Find:

$eforums = unserialize($vbulletin->options['dupexcl']);

Add under it:

$eforums2 = explode(",", $vbulletin->userinfo['excludeforumids']);


Find:

in_array($xid,$eforums)

Add under it:

OR in_array($xid,$eforums2)

That should be it!

Hopefully this helps someone else using the same mod. =) Keep in mind though if/when Paul updates his mod, you'll have to make these changes again.

That didn't work for me for some reason..

The rest of the product is working just not Paul's mod w/your changes.

I'm also on 4.1 so that might have something to do with it.

Mellow
12-30-2010, 09:55 PM
You'd make it:


<li><a href="search.php?{vb:raw session.sessionurl}
do=getnew&exclude={vb:raw bbuserinfo.excludeforumids}&amp;contenttype=vBForum_Po st">{vb:rawphrase new_posts_nav}</a></li>


For this to work with Paul's unread post mod there's 3 phrases that also need to be modified I believe.

dup_no_posts
dup_unread_posts
dup_x_unread_posts

But, I'm not sure how to do that as editing the phrases and inserting the above won't work. Any ideas?

BirdOPrey5
12-31-2010, 03:58 AM
I'm not familiar with Paul's mod- the best place to ask would be in the mod thread.

Mellow
12-31-2010, 10:49 AM
I'm not familiar with Paul's mod- the best place to ask would be in the mod thread.

You're right, my bad, will do it now.

Mellow
12-31-2010, 11:02 AM
So I installed this, then realized it wasn't working with PaulM's Unread Posts mod.

There is probably a better way to get this to work with it, but this is what I did.

Open Plugin: Unread Posts and Reputation, Hook: Parse Templates

Find:

$eforums = unserialize($vbulletin->options['dupexcl']);

Add under it:

$eforums2 = explode(",", $vbulletin->userinfo['excludeforumids']);


Find:

in_array($xid,$eforums)

Add under it:

OR in_array($xid,$eforums2)

That should be it!

Hopefully this helps someone else using the same mod. =) Keep in mind though if/when Paul updates his mod, you'll have to make these changes again.

What did you do about the phrases in the plugin? What version of vb are you running?

dutchbb
01-06-2011, 01:36 PM
It doesn't seem to be working correctly, it just shows an empty box. And I have run the query to enable every forum...

sticky
01-17-2011, 05:35 AM
Any chance of getting this updated for VB4?

Trek
01-17-2011, 05:51 AM
Any chance of getting this updated for VB4?

It already works actually. There's a post somewhere in this thread where someone made a couple updates, but overall it works, I've been using it on my forum for a long time now.

sticky
01-23-2011, 07:58 AM
It already works actually. There's a post somewhere in this thread where someone made a couple updates, but overall it works, I've been using it on my forum for a long time now.
Yes, but from what I read there are some issues? What version are you running on? Does it work well for you?

Trek
01-23-2011, 08:54 PM
Yes, but from what I read there are some issues? What version are you running on? Does it work well for you?

I'm running vB 4.1.0 at the moment and it works fine. The best thing I can tell you is to try it if it doesn't work, just remove it. =)

sticky
01-26-2011, 03:52 AM
I'm running vB 4.1.0 at the moment and it works fine. The best thing I can tell you is to try it if it doesn't work, just remove it. =)
Thanks, I saw all the changes necessary to make it work and I have so many different styles and such it just would be a pain in the butt to make all the edits. I'm also using Paul's mod so I will wait until someone gets a VB 4 version up.

Braincrusher
02-09-2011, 07:30 PM
You'd make it:


<li><a href="search.php?{vb:raw session.sessionurl}
do=getnew&exclude={vb:raw bbuserinfo.excludeforumids}&amp;contenttype=vBForum_Po st">{vb:rawphrase new_posts_nav}</a></li>


Works fine thanx

LoveStream
02-13-2011, 09:07 PM
I like this hack too.

But I want another feature that I need Usergroup based filter than user based.
So, how could I modify it?

Could you teach how the code should be included?

Every usergroup can select exclude or include.
Every forum can be exclude or include

This two option is necessary.

Thank you.

TalkVirginia
04-09-2011, 05:09 AM
Here's how I got this working with vb4:

Import attached version of the product, allowing overwrite. (this is the standard product, but with Fiel's changes included)
Edit your 'navbar' template. Add: "&exclude={vb:raw bbuserinfo.excludeforumids}" to the end of all links which go to search.php, and which contain both "do=getnew" and "contenttype=vBForum_Post" in the URL.

The second part of this doesn't work when you have the mod
Tabs Add System for vBulletin 4 (sstab advanced) installed.

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

Not sure how to fix this.

ldma
04-28-2011, 07:21 AM
Just got this working on VB4 thanks to AngelBlue

Silmarillion
10-03-2011, 10:49 AM
Does this actually work with vbseo enabled?

scottct1
10-03-2011, 11:50 AM
Yes I use it at www.satelliteguys.us with no issues between it and vbSEO.

Silmarillion
10-03-2011, 12:25 PM
Thx for the quick reply, scottct1! :)

Did you have to un- and reinstall vbseo like some others?

And did you notice some higher serverload or errors?

Best regards,
Silmarillion

Silmarillion
10-03-2011, 06:48 PM
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.



Is this necessary to get the prodct run? All i have to do is running "UPDATE forum SET excludable = 1" as a query? Before or after installing?

akanevsky
10-03-2011, 07:09 PM
Is this necessary to get the prodct run? All i have to do is running "UPDATE forum SET excludable = 1" as a query? Before or after installing?

Run this after the product is installed. Otherwise there will be no forums in the "exclude forums" list.

Artes_Marciales
10-04-2011, 07:58 AM
vBulletin 3.8.7 Patch Level 2
not work for my :confused:
https://vborg.vbsupport.ru/
Any idea?

Silmarillion
10-04-2011, 08:55 PM
Run this after the product is installed. Otherwise there will be no forums in the "exclude forums" list.Thx, PV. :)

One Question: we also use the addon Opt-Out Forums from Get New/Get Daily (https://vborg.vbsupport.ru/showthread.php?t=91025) as German-Version (http://www.vbulletin-germany.org/showthread.php?36-Foren-von-Neue-Beitr?ge-zeigen-ausschlie?en) by your co-author Andreas. Unfortunately, the two great addons doesn't work together correct. Is there a solution?

Best regards,
Silmarillion

tr0ll
10-07-2011, 10:08 PM
Its dont work with vBulletin 3.8.7 and vBSEO.
https://vborg.vbsupport.ru/

Could anyone help?

Silmarillion
10-24-2011, 10:44 AM
I've just installed a new subforum. Unfortunately it is not possible to choose the forum. I've run the query again ("UPDATE forum SET excludable = 1"). With no success. What should I do?

Best regards,
Silmarillion

Silmarillion
10-25-2011, 08:53 AM
I've just installed a new subforum. Unfortunately it is not possible to choose the forum. I've run the query again ("UPDATE forum SET excludable = 1"). With no success. What should I do?

Best regards,
SilmarillionDo i have to uninstall and reinstall the product? No other way?

Pocket Aces
10-28-2011, 08:08 AM
Is this applicable to user-specific search?

User-specific search are as follows:
Find all threads started by username - search.php?do=finduser&u=1&starteronly=1
Find all post by username - search.php?do=finduser&u=1

tr0ll
12-05-2011, 08:40 AM
ive tried everything but it doesnt work, its always like this;
https://vborg.vbsupport.ru/
please help, i need this product.

i run query over and over and still doesnt work.

Artes_Marciales
12-06-2011, 08:40 AM
I have the same problem :(
I have 4 Vbulletin forums and 2 works well, but in other 2 I have that problem. All are the same version of VB.
I think it may be a mod, but I compared the mods and find no differences :confused:

umitaykut
02-08-2012, 12:45 AM
ive tried everything but it doesnt work, its always like this;
http://img35.imageshack.us/img35/4802/capturet.gif
please help, i need this product.

i run query over and over and still doesnt work.

I have the same problem

Deimos
04-04-2012, 08:24 AM
I had a similiar problem, I think, it's been a while

How many forums do you have? I found the default size of the usertextfield in the database, was to small (varchar(255))

So I changed it to mediumtext.

If the forums don't show in the list still, try going into the forum manager, editing a forum, then saving without making changes?

I do have a problem as well though, despite the default entry being YES for excludable (database entry of Default: As defined: 1), it still doesn't check the "Yes" box when I add a forum

Andreasmax
04-07-2012, 04:39 PM
thanks for this mod

Robert Waanders
05-25-2013, 08:10 AM
I had a similiar problem, I think, it's been a while

How many forums do you have? I found the default size of the usertextfield in the database, was to small (varchar(255))

So I changed it to mediumtext.

If the forums don't show in the list still, try going into the forum manager, editing a forum, then saving without making changes?

I do have a problem as well though, despite the default entry being YES for excludable (database entry of Default: As defined: 1), it still doesn't check the "Yes" box when I add a forum

How and where can you change this?

edit: found it!

Robert Waanders
05-28-2013, 07:39 AM
the resolution above didn't help me.. Anyone having an idea how to fix this, or does anyone knows an alternative..

Meler
05-19-2014, 04:06 PM
I have Your submission could not be processed because a security token was missing.
if i add too many forums. Anybody know what fix it? Templates is ok

Dave-ahfb
06-29-2015, 12:10 PM
Those having problems in 4.2 with the "new posts" in the navbar

Go to your navigation manager

replace entire contents of "Target URL" with
search.php?{session.sessionurl}do=getnew&amp;contentty pe=vBForum_Post&amp;exclude={bbuserinfo.excludeforumid s}

3DSJFH
02-21-2016, 06:54 PM
Is there any way to make this mod only hide subforums from the "New Posts" feature, leaving the main forum sections visible?

blind-eddie
02-21-2016, 07:43 PM
In your navbar template find:

<td class="vbmenu_control"><a href="search.php?$session[sessionurl]do=getnew" accesskey="2">$vbphrase[new_posts_nav]</a></td>

Replace with:

<td class="vbmenu_control"><a href="search.php?$session[sessionurl]do=getdaily&exclude=1,2,3,4,5,6,7,8,9" accesskey="2">$vbphrase[new_posts_nav]</a></td>

Changing 1,2,3,4,5,6,7,8,9 to the sub forum id's you wish to hide.

3DSJFH
02-22-2016, 06:41 PM
Thanks, I should have clarified that I meant modify in a way so that users can choose which forum sections to hide on a user by user case.

But your tip is great, I notified my users of it so they can make a "favorites" shortcut in their browser themselves if they want this functionality, simplicity at it's best! :)