Forum Replies Created
-
EDTI: it seems that something went wrong, my last answer has not been registered. So I past it again. (sorry)
Hi!
Sorry, didn’t see your answers.
So after few hours, I did it.
Simply use the plugin https://wordpress.org/plugins/external-group-blogs/ (thx @mercime)
Then use a RSS parser http://simplepie.org/
The plugin structure is mainly the same, I use the admin area as base, then add a new tab if the group meta “feed-url” is not empty, an finaly load my rss parser function into the groups/single/plugins.phpAdd some php to fetch image in feeds thumbnail (if exists) or in enclosure link (if exists) or feeds content.
The result is I expected. Largely copied on feedly 😉Here is what it looks for the moment: http://www.gumdust.com/groups/bsp-team/blog-rss-feed/
Hope this help!
Hi,
I’m not sure if it can help you but the following may resolve your problem :function my_bp_nav_adder() { bp_core_new_nav_item( array( 'name' => __('New Tab Button', 'buddypress'), 'slug' => 'all-conversations', 'position' => 75, 'show_for_displayed_user' => true, 'screen_function' => 'all_conversations_link', 'item_css_id' => 'all-conversations' )); print_r($wp_filter); } function all_conversations_link () { //add title and content here - last is to call the members plugin.php template add_action( 'bp_template_title', 'my_groups_page_function_to_show_screen_title' ); add_action( 'bp_template_content', 'my_groups_page_function_to_show_screen_content' ); bp_core_load_template( apply_filters( 'bp_core_template_plugin', 'members/single/plugins' ) ); } function my_groups_page_function_to_show_screen_title() { echo 'My new Page Title'; } function my_groups_page_function_to_show_screen_content() { echo 'My Tab content here'; } add_action( 'bp_setup_nav', 'my_bp_nav_adder' );
source: http://codex.themedelta.com/how-to-create-a-new-tab-in-buddypress-member-page/
You have to change “members/single/plugins” by the path to your new template file without the .php extention.
If you need to check if the action already existe for different purpose (I already need to do something similar) you can use something like this:
if(has_action('name_of_action_to_check_for')) { // action exists so execute it do_action('name_of_action_to_check_for'); } else { // action has not been registered }
Hope this help 😉
Hi!
Sorry, didn’t see your answers.
So after few hours, I did it.
Simply use the plugin https://wordpress.org/plugins/external-group-blogs/ (thx @mercime)
Then use a RSS parser http://simplepie.org/
The plugin structure is mainly the same, I use the admin area as base, then add a new tab if the group meta “feed-url” is not empty, an finaly load my rss parser function into the groups/single/plugins.phpAdd some php to fetch image in feeds thumbnail (if exists) or in enclosure link (if exists) or feeds content.
The result is I expected. Largely copied on feedly 😉Here is what it looks for the moment: http://www.gumdust.com/groups/bsp-team/blog-rss-feed/
Hope this help!
Hi Guys,
@shanebp proposition was correct, hi just missed some quotes.
I personnaly use it like this (in my own activity-loop.php) with somme custom actions.$user_id = bp_loggedin_user_id(); $friends = array(); if ( bp_is_active( 'friends') ) $friends = friends_get_friend_user_ids( $user_id ); $me = array( $user_id ); $wall = array_merge($friends, $me ); $wall = array_unique( $wall ); $user_ids = implode( ',', $wall ); $get_users = "user_id=" . $user_ids; $stream_filter = '&'.$get_users.'&action=activity_update,rtmedia_update,new_blog_post,joined_group,created_group';
then
<?php if ( bp_has_activities( bp_ajax_querystring( 'activity' ).$stream_filter ) ) : ?>
cheers and thanks for your help 😉
OK, thanks…
I will see later if I can do something by my owne.
And by the way, i will share it 😉Buddypress rocks!!!
Thks @mercime,
I didn’t know for the theme directory, good to know now 😉
For the RSS feed, this is not exactly what I’m looking for.
This is difficult for me to explain exactly what I want because of my poor english…
I would like a sort of RSS aggregator in a new tab of profil user or groups, to display external RSS feeds (like the solution à mention above) and theire RSS URL would be entered by the user/group admin in the profil/groupd admin area…
hope i’m clear :/cheerse