Forum Replies Created
-
BUMP
yes that im aware of but my question is how does it display the bar chart and what code is used to pull data from somewhere
@xberserker would really like to test that, + could this work with the buddypress gifts? when you send a gift it deducts points..sort of like your paying for the gift with your points…any thoughts?
but then again you could use the BP-SEO plugin for that i think

@bpisimone , yes you only need to change the EXAMPLE in BP_EXAMPLE_SLUG and the title “Example”..is the second page a new page you created without a title?
this is what i did to add 3 page titles to 3 pages i created, in the same code:
function page_titles( $title, $b ) {
global $bp;if ( $bp->current_component == BP_EXAMPLE_SLUG && $bp->current_action == ” ) {
$title = __( ‘Example 1’, ‘buddypress’ );
}
if ( $bp->current_component == BP_EXAMPLE2_SLUG && $bp->current_action == ” ) {
$title = __( ‘Example 2’, ‘buddypress’ );
}
if ( $bp->current_component == BP_EXAMPLE3_SLUG && $bp->current_action == ” ) {
$title = __( ‘Example 3’, ‘buddypress’ );
}
return $title;
}
add_filter( ‘bp_page_title’, ‘page_titles’, 10, 2 );@stwc as i stated above, i did not know how to do it through wp, i tried using the wp codex for creating a page template but it didnt seem to be working for me, so instead i used the code above which was provided by john james jacoby in a previous forum topic
as the question above that he asked was: “is they’re any way you can edit it through a text editor rather than dashboard. Or is there any known way of how to solve this problem”add this to your bp-custom.php or functions.php file:
/*Define slugs*/
define(‘BP_EXAMPLE_SLUG’, ‘example’); /* this will show up as http://yourdomain.com/example *//*Add slug as a root component*/
function page_setup_root_component()
{
bp_core_add_root_component( BP_EXAMPLE_SLUG );
}
add_action( ‘plugins_loaded’, ‘page_setup_root_component’, 2 );/*Show defined slug*/
function bp_show_page() {
global $bp, $current_blog;if ( $bp->current_component == BP_EXAMPLE_SLUG && $bp->current_action == ” ) {
bp_core_load_template( ‘example’, true ); /*replace example with the name that of the template you upload*/
}
}
add_action( ‘wp’, ‘bp_show_page’, 2 );/*For extra functionality you can add a title for that page*/
function page_titles( $title, $b ) {
global $bp;if ( $bp->current_component == BP_Example_SLUG && $bp->current_action == ” ) {
$title = __( ‘Example’, ‘buddypress’ ); /*change Example with what you want the title of your page to be*/
}
return $title;
}
add_filter( ‘bp_page_title’, ‘page_titles’, 10, 2 );now create an example.php file and add this to it:
get the header with the get_header() bp function
Hello im an example page
testing to see if this works
get the footer with the get_footer() bp function
then upload it to the root of the bp-default theme, it should be at the same level as where the header.php, footer.php files etc.. are
now go to http://yourdomain.com/example and see if it shows..remember to replace ‘example’ throughout the code with what you want your slug/page to be, the template (example.php or whatever you will call it) that you upload to the theme should be the same as what you call on this line above>> bp_core_load_template( ‘example’, true );
if its working, go ahead and customize as ud like
hope this helps, it works for me, dont know a way to do it through wordpress though as wordpress will load page.php for every page you create so you cant really customize it..okay figured it out, had to call current_action on the screen function for my root component
is there a away to do it through buddypress?
1) i’d like a mobile theme for buddypress and a mobile plugin that detects when you are on a buddypress site from a mobile..when you post an update using a mobile the plugin then adds a “via mobile” or “via site_name mobile” into the activity meta of the site on a pc browser..basically similar to facebook mobile or how twitter mobile works..it could also be able to detect the mobile type, BlackBerry or iPhone or a Samsung etc..
2) also a plugin which detects a user’s location in the world or gives the user an option if he wants to enter his location to be included with his update..so that the user’s friends can see where he is posting the update from..as it could be related to the subject of the update..for example an update: “i just saw Andy Peatling” / WP Camp ..WP Camp being the location..the /WP Camp would turn into a link and when a user clicks this link he sees all the updates that have /WP Camp and can also find locations with the most updates
3) a plugin that gives users points and works similar to cubepoints plugin..5points added for posting updates, 2points for posting comments, 20points adding a friend etc.. the site admin would then choose which extra features he would like to be unlocked for a user when he reaches a certain number of points and how many points for each achievement..for example: 100points>create a blog, 10points>send a gift…once a user creates a blog or sends a gift, his total points decrease by 100points and 10points respectively..
would also like to know how to do this
@warut thats great! possible feature request: extend the profile badge maker to work with groups as well and create group badges to get more members in a group..is this possible?
Could this possibly be extended to also have a contacts importer..??
users just enter their Gmail, Yahoo or Windows Live email address and password and it finds if their friends are already on the site, if not it will give an option to send invites to the email addresses you want..
it could be tedious for some people to enter an email address again and again..just to make it simple for the user..
link to a loggedin users profile <?php bp_loggedin_user_domain() ?>
displayed user: <?php bp_displayed_user_domain() ?>
check:
https://codex.buddypress.org/developer-discussions/buddypress-template-tags/
thanks warut! yes that is true..profile image is the default mystery man not uploaded an image yet..wil do so and see how it works.. thanks
thanks warut! yes that is true..profile image is the default mystery man not uploaded an image yet..wil do so and see how it works.. thanks
i get this error on my badge page:
Warning: imagecreatefromjpeg() [function.imagecreatefromjpeg]: Cannot read image data in …public_html/wp-content/plugins/buddypress-badge/includes/bp-badge-core.php on line 340
Warning: imagesx(): supplied argument is not a valid Image resource in …public_html/wp-content/plugins/buddypress-badge/includes/bp-badge-core.php on line 341
Warning: imagesy(): supplied argument is not a valid Image resource in …public_html/wp-content/plugins/buddypress-badge/includes/bp-badge-core.php on line 342
Warning: imagecopy(): supplied argument is not a valid Image resource in …public_html/wp-content/plugins/buddypress-badge/includes/bp-badge-core.php on line 386
Warning: imagedestroy(): supplied argument is not a valid Image resource in …public_html/wp-content/plugins/buddypress-badge/includes/bp-badge-core.php on line 407
i get this error on my badge page:
Warning: imagecreatefromjpeg() [function.imagecreatefromjpeg]: Cannot read image data in …public_html/wp-content/plugins/buddypress-badge/includes/bp-badge-core.php on line 340
Warning: imagesx(): supplied argument is not a valid Image resource in …public_html/wp-content/plugins/buddypress-badge/includes/bp-badge-core.php on line 341
Warning: imagesy(): supplied argument is not a valid Image resource in …public_html/wp-content/plugins/buddypress-badge/includes/bp-badge-core.php on line 342
Warning: imagecopy(): supplied argument is not a valid Image resource in …public_html/wp-content/plugins/buddypress-badge/includes/bp-badge-core.php on line 386
Warning: imagedestroy(): supplied argument is not a valid Image resource in …public_html/wp-content/plugins/buddypress-badge/includes/bp-badge-core.php on line 407
got this thanks to Boones Gorges..
insert this in your bp-custom.php to get the total count of activity posts of a user:
function get_activity_count_by_user( $user_id ) {
$args = array(
‘per_page’ => 10000,
‘show_hidden’ => true,
‘user_id’ => $user_id
);
if ( bp_has_activities( $args ) ) {
global $activities_template;
$count = $activities_template->total_activity_count;
} else {
$count = 0;
}
return $count;
}
then use this template tag in your theme <?php echo get_activity_count_by_user( $user_id ) ?>
followed all the steps cant seem to get this working, it comes up blank…any idea why?
thanks
could you use this to show activity update posts count?? if so, how?
i would also like to know how to do this
lol greeat…i hope you manage..please do letme know how it turns out..
thanks
im not much of a coder so do you know of any example code i could use to pull out the meta on the track information?
the link to point to a page which has all the updates in which users have used #artist for that particular artist, for example you click on #artist in an update, it takes you to a page which has all the updates that have #artist in them, you click on #ARTIST2 in an update it takes you to a page which has all the updates that have #ARTIST2 in them, n so on..