Wordpress Themes - WP Forum at BFA

Wordpress Themes - WP Forum at BFA (http://forum.bytesforall.com/index.php)
-   RSS, Feeds & Subscribing (http://forum.bytesforall.com/forumdisplay.php?f=18)
-   -   [SOLVED] Exclude Category from RSS (http://forum.bytesforall.com/showthread.php?t=18510)

theadventurebite Sep 28, 2012 01:16 PM

[SOLVED] Exclude Category from RSS
 
Trying to exclude a category from the RSS feed. Not having any luck with plugins or this function in the functions.php:

Code:

function myFeedExcluder($query) {
 if ($query->is_feed) {
  $query->set('cat','-98');
 }
return $query;
}
 
add_filter('pre_get_posts','myFeedExcluder');

I don't see Atahualpa using the standard commands they are using here.

Ideas?

theadventurebite Sep 28, 2012 01:34 PM

I believe I have gotten a plugin to work. Looks like I had it setup incorrectly. Thanks!

Dani

theadventurebite Sep 28, 2012 01:39 PM

Spoke too soon it appears. The Ultimate Category Excluder does not seem to be excluding anything. Any ideas on this??

theadventurebite Sep 28, 2012 01:43 PM

I will be attempting this process: http://wordpress.org/support/topic/p...rss?replies=15

And will update you on whether or not it works.

In the meantime if you have done this would love to hear thoughts!

theadventurebite Sep 29, 2012 05:46 AM

From what I can tell the first post I put up in this thread is a super common one that is actually working for people. Can mods or Flynn help me understand why it's not working with this theme?

Perhaps I simply have in wrong location or need to change one of the commands to what our theme uses??

Thank you!

Dani

theadventurebite Sep 29, 2012 06:04 AM

Hey guys.

Figured out a workaround and potentially what the trouble was. I totally spaced that I have the Feedburner Feedsmith plugin on to redirect all my feed subscribers to my Feedburner feed. Which means all these adjustments are unnecessary.

All I have to do is go to feedburner, click on the feed you want to change, click edit feed details, and then change the feed location through feedburner from this:

Code:

http://theadventurebite.com/feed/
To this:

Code:

http://theadventurebite.com/feed?cat=-98
with the cat being the category number I want to exclude.

Works like a charm and makes the change without losing any subscribers or having to update any links, etc.

Hope that helps someone else.

~Dani


All times are GMT -6. The time now is 04:50 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.