Hi @col_blimp,
The SEO Framework indeed filters pre_get_posts to conduct the “exclude from local search” option available to set on each page and post.
For future reference this filter can be found in /inc/classes/search.class.php
I’ll try to get your function working together with the one in The SEO Framework, expect this fix to be released in the next update (2.4.0).
If it requires a whole $wp_query backtrace rewrite I might not make it compatible, for performance reasons.
However, taking over filters and neglecting other plugins and developers of their needs is something that should be looked down upon.
I’ll notify on this post when I do not update the functionality.
I hope this helps! Thanks and have a great day 🙂
Hi @col_blimp,
Good news!
This issue has been resolved in The SEO Framework 2.4.0-RC2.
RC2 won’t be publicly available and will undergo final testing before uploading to ww.wp.xz.cn as The SEO Framework 2.4.0, this should happen within a few hours.
What I’ve done:
Merged all post__not_in queries from any filter below 999 priority, this includes the one you’ve provided :).
From one to another:
If you don’t wrap your code within is_admin() on the filter you’ve created, the posts will also be hidden within the Admin Dashboard, a small tip from one developer to another ^^.
I’m marking this topic as resolved because an update is underway, if you still have questions or notice any problems regarding this issue on 2.4.0 (when it’s released), feel free to re-open and/or reply to this topic 🙂
Thanks and have a great day!
Hi there, the topics still dont show with the latest version, commenting out: add_filter( ‘pre_get_posts’, array( $this, ‘search_filter’ ), 999, 1 ); resolves the issue.
Hi Col_Blimp,
I’ve marked this topic as unresolved.
I see you know your way around code :), that’s awesome!
Could you change the line you’ve commented out to and post the results?
add_action( 'pre_get_posts', array( $this, 'search_filter' ), 999, 1 );
I noticed I’ve mistakenly used a filter instead of an action, so it will always return void (as I don’t return anything). I’m unsure if it will affect the outcome, but it’s worth a shot!
If that doesn’t fix it, will changing the 999 to 0 help, while maintaining an action instead of an filter?
I know, it’s kind of a “try and see” situation, but WordPress’ query is so huge and complex, it’s difficult to comprehend where all pieces go, especially since I can’t reproduce your problem on my sites at the moment.
Thanks and have a great day! I await your reply 🙂
Hello Col_Blimp,
The SEO Framework 2.4.1 has just been released and fully supports bbPress topics! The discussed problem with pre_get_posts has also been altered. I’m unsure of the outcome on your website but my tests have shown it should work as intended :).
I’m marking this topic as resolved again, if however you still encounter issues feel free to re-open this topic and/or reply. I’ll be sure to check it out!
I hope you enjoy this change and wish you all the best 🙂
Thanks and have a wonderful day!
bro…..iam using sabai discuss for Q&A and bbpress for forum, as i wanted my site to have both Q&A and forum …// sabai discuss is working perfectly but the bbpress is not working and not showing in the dashboard..previously it was showing but now its not
But one thing is there i can see forum roles option in the users menu in the dashboard
pls suggest me…
Hi @siddupatil,
This is quite an outdated topic (a year old!). So in the future, please open a new topic because we’re now bothering Col_Blimp.
Also, please see if deactivating other plugins would help showing up the required menu items once more.
If that does not work, please forward this question to bbPress on their support forums.
Cheers!