Blogs connected to groups didn’t have their posts show up in Recent Blog Posts
- This topic has 14 replies, 4 voices, and was last updated 10 years, 3 months ago by Christian Wach.
-
AuthorPosts
-
May 31, 2014 at 4:44 pm #4778Iurie MalaiParticipant
I have a similar question as here. In the Homepage Right sidebar of my CBOX multi-site I have two widgets: ‘Recent Networkwide Blog Posts’ and ‘(BuddyPress) Recent Networkwide Posts’. Both of them don’t show anything, even if there is at least one network blog, connected to a group, with at list one new post. Is there a way to force the Recent Networkwide Blog Posts widget to show the new posts of blogs connected to a group?
June 1, 2014 at 6:15 am #4779Iurie MalaiParticipantTo @ebrown2600 and others –
I hope, the Recent Networkwide Blog Posts widget incapacity to display posts of blogs connected to a group will be solved sooner or later. Temporarily, I solved this problem by using the Network Latest Posts plugin with a similar widget and some CSS formating. I kept even the Recent Networkwide Blog Posts widget for the More Blogs link. The result you can see here.
- This reply was modified 10 years, 4 months ago by Iurie Malai.
June 1, 2014 at 8:52 pm #4781Liz BrownParticipantHi, <span class=”user-nicename”>@iurie</span>, thanks for sharing this! I don’t know anything about CSS—-I would have to get someone else to help me with that—but perhaps I’ll give this a try and see if it might work for me. I need to keep some of my network blogs connected to the groups, so I made the decision to just not worry that people in the groups wouldn’t see recent posts in the recent networkwide blog posts—-although it would be ideal for them to be able to.
I had trouble with “‘(BuddyPress) Recent Networkwide Posts” (can’t remember now what the problem was) but everything has been okay except the groupblogs with the recent networkwide posts widget.
June 7, 2014 at 6:19 pm #4790RayKeymasterThe problem appears to be that the BP Groupblog plugin explicitly sets its activity type to “new_groupblog_post”. BuddyPress looks for the “new_blog_post” activity type when fetching posts for the Recent Networkwide Posts widget.
Looks like a workaround will need to be written for this case either in BP Groupblog or CBOX.
June 8, 2014 at 3:53 am #4793Iurie MalaiParticipant@r-a-y, can you tell where to look for both “new_groupblog_post” and “new_blog_post” filters? I’d like to test your assumption, but I cannot find them, nor in BP Groupblog plugin, nor in CBOX theme.
- This reply was modified 10 years, 4 months ago by Iurie Malai.
June 8, 2014 at 5:58 pm #4795Christian WachParticipant@iurie You won’t find filters in code by those names – Ray is referring to different the activity types that BuddyPress and BP Groupblog create. However, you will find entries in the dropdown on the activity stream that allows you to filter the stream by activity type.
@r-a-y it seems to me that the Recent Networkwide Posts widget could do with a couple of actions and filters so that other plugins can hook into it. BP Groupblog (and other plugins that intercept the ‘new_blog_post’ activity type) could then offer a checkbox in the widget to allow their activity types to be included. Seeing as you’ve just given the widget some love, doesn’t it deserve a little bit more? 🙂June 11, 2014 at 5:43 am #4804Iurie MalaiParticipantHowever, you will find entries in the dropdown on the activity stream that allows you to filter the stream by activity type.
@haystack – Yes, I know, but this doesn’t solve the described problem.- This reply was modified 10 years, 4 months ago by Iurie Malai.
June 11, 2014 at 6:04 am #4807Christian WachParticipant@iurie one solution would be to clone the BP widget in a separate plugin, then change the argument to read
'action' => 'new_blog_post,new_groupblog_post'
.June 11, 2014 at 10:20 pm #4816RayKeymasterit seems to me that the Recent Networkwide Posts widget could do with a couple of actions and filters so that other plugins can hook into it. BP Groupblog (and other plugins that intercept the ‘new_blog_post’ activity type) could then offer a checkbox in the widget to allow their activity types to be included. Seeing as you’ve just given the widget some love, doesn’t it deserve a little bit more?
🙂 The groups widget was a bug. The issue being described here is more of an enhancement.
It’s already possible to write a small plugin to override the Recent Networkwide Posts widget’s activity filter:
https://gist.github.com/r-a-y/0a00109db5065e00f192Untested. Feel free to test by pasting this into /wp-content/plugins/bp-custom.php.
I’ll probably post this code snippet as a pull request to the BP Groupblog repo once someone verifies it works.
June 12, 2014 at 1:15 am #4817Iurie MalaiParticipant@haystack,
Excellent, @r-a-y! Thank you very much! But how blog articles that will be displayed are selected? In my three blogs were published a total of 7 articles. I noticed that from the root blog no posts was displayed (there is only one – Hello world!, one of the oldest), from a second blog was displayed only the latest one (even 2 posts are the newest out of the total 7), from the third blog – all 3 posts (even all 3 are not the newest out of all 7). The widget is set to display 10 posts, but was displayed only 4 out of 7. I do not see a logic. My CBOX multi-site: upsic.org.June 12, 2014 at 7:04 am #4818Christian WachParticipant@r-a-y Your filter seems to work, but it also merges posts and groupblog posts on the activity stream when selecting “posts” in the dropdown, which may or may not be expected behaviour depending on your point of view 🙂
June 15, 2014 at 11:00 am #4823Iurie MalaiParticipant@iurie one solution would be to clone the BP widget in a separate plugin, then change the argument to read ‘action’ => ‘new_blog_post,new_groupblog_post’.
@haystack – Christian, I found the ‘(BuddyPress) Recent Networkwide Posts’ widget (in my public_html/wp-content/plugins/buddypress/bp-blogs/bp-blogs-widgets.php) but can’t find the ‘Recent Networkwide Posts’ widget (without (BuddyPress)). Can you suggest where to look for it?June 16, 2014 at 11:06 am #4828Christian WachParticipantDo you mean “Recent Networkwide Blog Posts”? That’s a CBOX Theme widget. Look in:
/wp-content/themes/cbox-theme/engine/includes/buddypress/bp-widgets.php
June 17, 2014 at 4:08 pm #4839Iurie MalaiParticipant@haystack, thank you for your help! I tested your solution and it works similarly as the @r-a-y filter. But I do not understand your comment that the @r-a-y’s filter …’merges posts and groupblog posts on the activity stream when selecting “posts” in the dropdown‘. I do not observe any changes in the activity stream when “posts” are selected with the @r-a-y’s filter activated. I want to avoid aberrant behaviors, so I whant to understand what you mean.
- This reply was modified 10 years, 4 months ago by Iurie Malai.
- This reply was modified 10 years, 4 months ago by Iurie Malai.
June 18, 2014 at 5:52 am #4843Christian WachParticipant@iurie What I mean is that Ray’s code includes ‘new_groupblog_post’ activities when requesting activities of type ‘new_blog_post’. Try going to your activity stream (when logged out) and using the dropdown – you’ll find both types shown when selecting “Posts”. Now in your case, that’s what you want. But (depending on how they’re using the Groupblog plugin) not everyone will want that.
-
AuthorPosts
- You must be logged in to reply to this topic.