Forum Replies Created
-
@djpaul — are you saying that existing sites with transactional email systems will continue to work if they upgrade to 2.5 (we have clients using both SendGrid and Mandrill – via their recommended WP plugins)?
I’ve not encountered any issues locally.
My preferred setup is Chassis to provide local WordPress environment on vagrant; then adding BuddyPress however you prefer (from wp-admin or manually). Works great on OSX (although there are some general config changes with VirtualBox on El Capitan).
Hi Ollie,
if you provide contact details on your post, will be happy to send through some details on reference sites.
Cheers, Roger
Hi Ollie,
this is all achievable with a custom build on top of BuddyPress and WordPress.
We’ve built similar marketplace type sites on the platform in the past. BP is a useful base for the profiles in this scenario, but also the messaging, and the activity items (which can help with audit trails and transaction history).
However, 50 hours is not a lot for a site build — a basic well designed & written portfolio site can take that in excess of that. Once you add custom functionality, the multiple screens, the security and transactional aspects of a marketplace site — you’ll be considerably more.
When looking to engage a developer bear in mind you will get a better quality site in less time from expert developers. Of course, you’ll also be paying higher hourly rates for their expertise. An expert should also advise you at the start whether what you want to achieve is reasonable within your budget.
Suggest you should post this on the job board along with contact details.
Roger
The default BuddyPress site setup only supports a single activity, members, groups directory page.
One solution is to create your own custom page templates, and embed the code for the activity, member and group loops in the template. You’d then assign it to your duplicate pages. You can read more about coding your own loops in the documentation section of this site.
You could also look to see if it’s possible to use the language files — dynamically loading the appropriate text domain translations of the BuddyPress text depending which language the user has selected. In this scenario, you’d work with the default ‘single’ page setup.
Perhaps too late for your site (if you’ve gone down the polylang route), but for all our multi language solutions, we go the multisite approach and using the Multilingual Press Pro plugin. It gives a really clean solution. Remember to enable bp multiblog if you switch to this approach.
For point 3 — make sure you are deleting your users from the network admin panel, and not just removing them from a specific site using the site’s dashboard.
For point 4 — members will typically show once they have logged into the site
For point 2 — you need to be more specific about the problem you are seeing – rather than just saying “it isn’t working”. Have a search on the forums (including general WP ones) for this type of problem.
Please see https://buddypress.trac.wordpress.org/ticket/6360 and associated tickets for a fix for point 1. It’s a known problem.
We’ve worked with the Premium version of WP-FB-Autoconnect on a number of sites. It does the job.
You could also take a look at the WordPress-Social-Login project on GitHub, which looks interesting.
Have you got pretty permalinks enabled? Do your other pages all load correctly (posts / pages / archives) with the correct permalinks?
You can add the following template to your theme to override how members profile are displayed: /buddypress/members/single/index.php
In that index.php you can include different template parts to display the user based on their role.
So, you’d have a template part to display writers, and a different template part to display subscribers.
You can read more on the template hierarchy here: https://codex.buddypress.org/themes/theme-compatibility-1-7/template-hierarchy/
Changing these titles isn’t the easiest thing, but BuddyPress does provide 2 ways you can do it. However, hacking core files like bp-activity-loader.php is definitely not one of them. [Never hack core files — have a Google if it’s not obvious to you why you shouldn’t]
Ok the 2 solutions are:
- Use a language / translation file
- Use the template hierarchy
The string “Site-Wide Activity” is translatable — all the strings are. You can implement a language file that translates ‘Site-Wide Activity’ into whatever string you’d like. Have a search for translating BuddyPress strings / POT files / poedit. There’s also a documentation (they call it the Codex) page on it: https://codex.buddypress.org/getting-started/customizing/customizing-labels-messages-and-urls/
The second solution is to use the template hierarchy. If you don’t provide a specific template for your activity directory, BuddyPress will use the page.php file from your theme and ‘inject’ the title “Site-Wide Activity” where page.php makes a call to the_title().
You can override this by implementing your own template — create a file called index-directory.php inside /buddypress/activity in your site’s theme. Copy the basics of page.php into that file, and replace the_title() with your hardcoded title for the page.
You can read more about the template hierarchy here: https://codex.buddypress.org/themes/theme-compatibility-1-7/template-hierarchy/
Neither solution is simple, you’ll either have to get your head around using poedit, or need some basic PHP coding skills and an understanding of the principles of templates and themes in WordPress. In the future, it would be nice to see a settings panel in wp-admin to configure these basic strings.
[p.s. if you don’t want to use poedit, you could take a look at plugin solutions for string translation, e.g. codestyling localisation]
Correction — you can also use bp_group_name() by passing a group to it as its argument.
Take your group_id, instantiate a group, and pass it to bp_group_name():
$args = array( 'group_id' => $my_id ); $group = groups_get_group( $args ); .. bp_group_name( $group);
For a loop like that you can use bp_has_groups() instead of groups_get_user_groups(). Is there a reason why you rejected that approach?
Then a my groups widget can have a simple core like this:
<?php if ( bp_has_groups( 'type=alphabetical&user_id=' . bp_loggedin_user_id() ) ) : ?> <ul id="my-groups-list"> <?php while ( bp_groups() ) : bp_the_group(); ?> <li class="row collapse"> <div class="item-avatar small-3 columns"> <a href="<?php bp_group_permalink() ?>"><?php bp_group_avatar_thumb() ?></a> </div> <div class="item small-9 columns"> <div class="item-title"><a href="<?php bp_group_permalink() ?>" title="<?php bp_group_name() ?>"><?php bp_group_name() ?></a></div> </div> </li> <?php endwhile; ?> </ul> <?php else: ?> <div class="widget-error"><?php _e( 'No current groups.', 'my-groups-widget' ); ?></div> <?php endif; ?>
Note: If you want to use functions like bp_group_name(), you need to be inside a bp_has_groups() loop. The loop and bp_the_group() instantiate structures in the group template that are then used by bp_group_name.
If you want to use groups_get_user_groups() and setup your own loop, you’ll need to use different functions to access the name, permalink, etc. Look in bp-groups-functions.php, bp-groups-template.php and in bp-group-classes.php to get an idea what’s available.
or even easier for the displayed user id:
bp_displayed_user_id();
That’s more of an s2member question than a BuddyPress one – so, better asked on their forums.
Anyway:
In your PHP template for displaying the user, you can add the following code:
echo get_user_field('s2member_access_label', $user_id);
and to get the $user_id for the displayed user, you can use:
global $bp; $user_id = $bp->displayed_user->id;
@strangechild — there is some documentation here: https://codex.buddypress.org/themes/theme-compatibility-1-7/theme-compatibility-2/
The intro is confusing, but if you jump to the second section, it tells you where to find files and where they need to be added to your theme, if you want to override them.
ok.. props to @hnla
Defining the constant BP_ENABLE_MULTIBLOG in bp-custom.php fixed the problem.
@boone – any thoughts on this vs. enabling BP on a site by site basis (as suggested as preferable in your in file comments)? Is activity / members / groups, etc. shared when BP is activated separately for each site?If you look in the implementation bp_has_activities(), you’ll see if no user id is supplied as an argument it will default to the displayed_user id on a member page.
See lines 316 and 382 of bp-activity-template.php
If you’re on a non member page it will show activity relative to the logged in user (line 382).
Try passing the logged in user id as an argument to your bp_has_activities() call, that should override the displayed user default on a member page.
Duplicate of other thread: https://buddypress.org/support/topic/hide-the-followingfollowers-tabs-from-non-profile-owners/
We’ve used WP FB Autoconnect on a lot of BuddyPress sites – https://wordpress.org/plugins/wp-fb-autoconnect/
There’s a functional free version, and just a few dollars extra for the pro version
Sounds like you are using an old / outdated plugin with a recent version of BuddyPress.
Looks like called wp-cache might be the problem — see if this link helps you https://wordpress.org/support/topic/advanced-cachephp-problems-on-upgrade
Maybe I’m just confused by the naming:
I know I can do this by creating my own class named BP_Legacy in my theme and customising, but this doesn’t seem a correct approach.
Is the BP_Legacy class supposed to behave like a pluggable function? i.e. you are expected to redeclare the class with the same name?
—
On a separate but related matter — if I want to create a completely bespoke theme (not theme compat), how do I stop an instance of BP_Legacy being created and registering its actions?
I’ve tried declaring add_theme_support(‘buddypress’) hooked on to ‘after_setup_theme’, but that doesn’t stop an instance of BP_Legacy being constructed and registering its actions.
Looking at the BP_Theme_Compat constructor, it would appear that add_theme_support(‘buddypress’) should stop it — does it need to be hooked on to something earlier than ‘after_setup_theme’?
You shouldn’t be using Genesis Connect with current versions of BuddyPress.
From the Genesis Connect developer:
As of BP 1.7 you do not need to have GenesisConnect. We are currently maintaining it for customers who had BP installs prior to BP 1.7.
Hi R-a-y,
Yes, had looked at the implementation in the default BP components, and ‘gotten’ my head around it.
Good to get confirmation that this is the right approach for 3rd party as well.
Thanks, Roger
Hey Dan,
thanks, yes, BuddyDrive looks to have the ‘correct’ solution.
It creates a BP_Theme_Compat class for the component – the same approach that the internal components (Groups, Activity, etc.) do.
@boone, @r-a-y … is that the recommended approach for 3rd party components going forward?Cheers,
Roger