View Full Version : Miscellaneous Hacks - Exclude Forums From external.php
echamberlain
08-03-2007, 10:00 PM
Ever wanted to exclude some of your forums from the external.php output, without having to add and maintain a huge include list?
Now you can, this mod adds two attributes to the external.php query string.
excludeids is a comma delimited string of forums to exclude from the external.php output.
notitleids=1 will not list all the included forum ids in the RSS feed title.Why was this mod created and how is it used?
We redirect all our feed requests to feedburner and use it to serve all our forum feeds. We have a feed for each of our individual forums and a general feed for the entire site. Recently we added some commercial forums and don't want to clutter the feed with the commercial content, so we needed to exclude two forums. Our forum feed string now looks like:http://forum.voxilla.com/external.php?type=rss2&lastpost=1&excludeids=97,98¬itleids=1How does this mod work?
This mod uses the hooks in external.php to add the new settings without the need for custom code modifications.
FreshFroot
08-04-2007, 08:36 PM
pretty cool hack, thanks mate :D
tpearl5
08-05-2007, 09:42 PM
Thanks! Exactly what I needed!
pictureboarduk
08-06-2007, 08:45 PM
What does this do?
Thanks.
SBlueman
08-07-2007, 03:06 AM
Where do you edit the forums to include/exclude in the ACP?
baghdad4ever
08-07-2007, 08:47 AM
Where do you edit the forums to include/exclude in the ACP?
i wanna the same thing
ringleader
08-07-2007, 09:15 AM
Excellent stuff - perfect for me when hiding forums from RSS feeds :D
echamberlain
08-08-2007, 03:34 PM
Where do you edit the forums to include/exclude in the ACP?
I didn't add any ACP control.
The excluded forums are controlled from the external.php query string.
SBlueman
08-09-2007, 02:44 AM
Ok...let me try this....what do I edit and where do I go to edit which forums to exclude?
StarBuG
08-09-2007, 10:51 AM
Hi
Even though I have the ¬itleids=1 command in my url, for one of my forums it still shows the ids when I add more then 2 forum ids to exclude.
http://www.patientenfragen.net/external.php?type=rss2&lastpost=1&excludeids=24,25,33¬itleids=1
On my other forum, this problem does not exist even with 3 ids in the url.
http://www.elternfragen.net/external.php?type=RSS2&lastpost=1&excludeids=11,12,19,22¬itleids=1
I have no clue why this happened
Thanks for this mod. ;)
StarBuG
echamberlain
08-09-2007, 03:54 PM
Ok...let me try this....what do I edit and where do I go to edit which forums to exclude?
You add the new attributes to where ever you are using external.php.
My main RSS feed now looks like: http://forum.voxilla.com/external.php?type=rss2&lastpost=1&excludeids=97,98¬itleids=1
SBlueman
08-11-2007, 07:20 PM
So I am editing something in external.php to exclude forums now?
Antivirus
08-12-2007, 05:35 AM
interesting, i thin i can use this, need to look into it
SBlueman
08-12-2007, 05:54 AM
What I am trying to do is only include one forum in my rss feed. Any suggestions on how to do this efficiently?
echamberlain
08-12-2007, 11:31 PM
What I am trying to do is only include one forum in my rss feed. Any suggestions on how to do this efficiently?
It's documented in the vBulletin manual.
Thanks for this Mod.
I am the one who asked for this here (https://vborg.vbsupport.ru/showthread.php?t=150781) and here (http://www.vbulletin.com/forum/showthread.php?t=238008)!
This is special great if you have forums that are "feed by feeds" :)
Here is my contribution so you don't have to add or change any query string in external.php
Go to Admin CP, Plugin & Products, Plugin Manager and Add New Plugin
Product: Exclude Forums From external.php
Hook Location: external_start
Title: Anything you want
Execution Order: 4
Plugin PHP Code: $vbulletin->GPC['excludeids'] = '1,2,3';
Plugin is Active: Yes
Note: 1,2,3 are the forum id's you want to exclude.
Done!
Installed
Thanks
One more note, you can add
$vbulletin->GPC['notitleids'] = 1;
in the Plugin PHP Code to hide the ID of you forums.
NeutralizeR
09-25-2007, 01:22 PM
notitleids=1 still lists id's in the titles for me. It's the last forum created, is this the reason?
Is there a way to automatically exclude a specific forum from the feed without changing the original url?
Cybertims
10-06-2007, 08:15 PM
Is it possible to feed forums that have no guest access, I want to share a staff room on two seperate forums, so a feed to and from each seems to be the answer.....is it possible though>
Cheers
mexicanpizza
11-18-2007, 01:56 AM
echamberlain, nice work, thanks! Any idea how to write a mod to INCLUDE specific THREADS?
zmmmzz
12-19-2007, 04:15 PM
thanks!!!
Eq4bits
02-05-2008, 08:01 PM
What if I want to exclude ALL but one forum? Sort of the opposite of what this mod does...
echamberlain
02-05-2008, 08:28 PM
Instructions for creating feeds for individual forums is in the vBulletin documentation.
smestas
04-30-2008, 09:24 AM
I'm sorry if this is obvious, but will this work OK in 3.7?
SEOvB
05-03-2008, 07:52 PM
I've added the above $vbulletin->GPC['notitleids'] = 1; to the plugin code, and it is still out putting all the forum id's!
any idea?
Here is my plugin:
Hook: esternaƧ_start
$vbulletin->GPC['excludeids'] = 'X,Y,Z';
$vbulletin->GPC['notitleids'] = 1;
$vbulletin->GPC['lastpost'] = 1;
zmmmzz
08-19-2008, 10:15 PM
is this working in 3.7.2?
Ingmar
08-30-2008, 03:32 AM
Thank you echamberlain and nice contribution nfn!
*clicks installed*
ColinP
09-20-2008, 08:46 AM
Hi, I've just installed this and it works brilliantly. Just one issue - the notitleids parameter has no effect. Any ideas?
cionfs
01-18-2009, 10:38 AM
It works on vBulletin 3.8.0.
NLP-er
04-02-2009, 11:47 PM
Here is my plugin:
Hook: esterna?_start
$vbulletin->GPC['excludeids'] = 'X,Y,Z';
$vbulletin->GPC['notitleids'] = 1;
$vbulletin->GPC['lastpost'] = 1;
For me everything is working when it is explicity in link:
http://www.forum.simple-nlp.pl/external.php?type=rss2&lastpost=1¬itleids=1&excludeids=23,25,52,54
But when I set options in plugin and leave link without those params:
http://www.forum.simple-nlp.pl/external.php?type=rss2
Then code in plugin have no effect. Honestly - it have no effect at all. I don't know what I'm doing wrong. Plugin is set like it is described in some post earlier. I put my ids of forums. And still empty link shows everything.
I need to find a way to change default behaviour, bacauose I already propagated by RSS link to some sites - and I even don't remember where. So right now those pages are just spammed by welcome messages in my forum, and real content is not visible :/
NLP-er
04-03-2009, 11:43 AM
Ok I already did it :D
You have to change existing plugin: Exclude Forum From external.php
Change:
$vbulletin->input->clean_array_gpc('r', array(
'excludeids' => TYPE_STR,
'notitleids' =>TYPE_INT
));
To:
if ($vbulletin->GPC['excludeids'] != '') {
$vbulletin->input->clean_array_gpc('r', array(
'excludeids' => TYPE_STR,
'notitleids' =>TYPE_INT
));
}
Be aware that now it will not react on excludeids and notitleids from link if you set it in plugin, but I don't need it. If somebody does - You know right now where make changes.
fogjuice
05-29-2009, 01:16 AM
why the hell have ppl rated this mod up? did they not check their rss feed? it doesn't work and this mod is so temperamental. Maybe it is just my v3.8.2 but after examining the code, I can't see how this thing works.
beduino
06-23-2009, 03:33 PM
Somebody knows if other mod make this excludes?
all the best
beduino
NLP-er
06-23-2009, 11:22 PM
why the hell have ppl rated this mod up? did they not check their rss feed? it doesn't work and this mod is so temperamental. Maybe it is just my v3.8.2 but after examining the code, I can't see how this thing works.
I had it working, but after update to v3.8.2 it doesn't work anymore :/
I mean it doesn't work with params written in plugin. But with teaken from url it works. Unfortunatelly I want to dissable by default some forums...
NLP-er
06-23-2009, 11:54 PM
Ok I have solution - forget about previous changes I wrote about. Starting from original version - find plugin Exclude Forum From external.php and under
// clean our new excludeids attribute
$vbulletin->input->clean_array_gpc('r', array(
'excludeids' => TYPE_STR,
'notitleids' =>TYPE_INT
));
add
if ($vbulletin->GPC['excludeids'] == '') {
$vbulletin->GPC['excludeids'] = ',23,25,52,54';
$vbulletin->GPC['notitleids'] = 1;
$vbulletin->GPC['lastpost'] = 1;
}
Of course change ids and other options if you want. In this way if excludes ate in url then those will be used and only those. If not then default excludes will be applied. Of course if it is used forumids then excludes are ignored (last block of code in mentioned plugin). For me it is great :D
melbo
03-08-2010, 01:32 AM
Awesome NLP-er! Works great.
Is this mod working for vb 4.x?
2 NLP-er
Dosn't works with 3.8.5 :(
BamaStangGuy
05-29-2011, 08:48 PM
Anyone have a fix for this?
Brandon Sheley
02-21-2012, 12:53 AM
how about a 4.x version? :up:
djbaxter
01-27-2013, 04:47 PM
Is this mod working for vb 4.x?
how about a 4.x version? :up:
It seems to be working in 4.2.0 PL3 with the modifications to the plugin suggested by NLP-er at https://vborg.vbsupport.ru/showpost.php?p=1836020&postcount=37
bzcomputers
10-31-2013, 09:28 PM
It seems to be working in 4.2.0 PL3 with the modifications to the plugin suggested by NLP-er at https://vborg.vbsupport.ru/showpost.php?p=1836020&postcount=37
I can confirm working in 4.2.0 PL3 with the modification linked above.
vBulletin® v3.8.12 by vBS, Copyright ©2000-2025, vBulletin Solutions Inc.