Forum Replies Created
-
In reply to: Uploaded Avatar Quality
>I set the full size of all new avatars to 650×250
That’s huge.What image type are you testing with? I’m guessing jpg
Try a png – won’t solve your problem but might narrow it down.
And make it bigger than your default sizealso – post your bp-custom code for this.
In reply to: [Resolved] Profile fields visible even to anonymousYou want to not show profile fields on the profile pages for non-members ?
Try this – it should not show profile fields for users who are not logged-inIn /your-theme/members/single/profile/profile-loop.php
At the very top, replace this:
`
`with this:
`
`At the very bottom, replace this:
`
`with this
`
`
Why is your banner in an h1 tag ?
In reply to: [Resolved] Disable responsive layoutPerhaps you are confusing wp_dequeue_style and wp_deregister_style ?
Try
`wp_dequeue_style( ‘bp-default-responsive’ );`You may need to deregister after dequeue.
In reply to: HTML in button fields>You cannot use PHP in the button url field, only HTML.
You mean the onClick parameter?
Why not? Something like
`
global $bp;
$this_url = $bp->loggedin_user->domain . ‘profile/edit/group/1’;
<input type=button onClick="location.href=''” value=’edit profile’>
`I prefer to use this approach
`<a id="some-other-value" href="” title=””>`
If you want to include a nonce, it’s a bit more complicated.
In reply to: [Resolved] Changing Member Profile Submenu OrderPut this
define(“BP_DEFAULT_COMPONENT”,”profile”);in your bp-custom file
https://codex.buddypress.org/extending-buddypress/bp-custom-php/Search is broken.
I believe the fix is ‘coming soon’ as part of a larger site update.
It will be nice when search is working.
Yours were frequent questions.In reply to: how to show friendsSee this for use and parameters re members loop
https://codex.buddypress.org/developer-docs/custom-buddypress-loops/the-members-loop/if ( bp_is_my_profile() )
In reply to: how to show friendsProbably :
bp_member_avatar(‘type=full’)In reply to: Dumb Newb question!You mean where does it appear in custom theme files?
Various places, here is one:wp-content/themes/your-theme/members/single/profile/profile-loop.php
In reply to: Full BP Avatar URLTry this:
`
global $post; // probably don’t need this
$author_id=$post->post_author;$avatar = bp_core_fetch_avatar( array( ‘item_id’ => $author_id, ‘type’ => ‘full’ ) );
echo $avatar;
`If you want to specify the height / width you can do this:
`
$avatar = bp_core_fetch_avatar( array( ‘item_id’ => $author_id, ‘type’ => ‘full’, ‘height’=>105,’width’=>105 ) );
`In reply to: how to show friendsThis is a widget
https://wordpress.org/extend/plugins/bp-show-friends/I haven’t used this and don’t know if it’s compatible with BP 1.5 as is.
If you don’t want a widget and don’t know how to write your own query, you could do something like this – untested by me:
<?php $user_id = $bp->loggedin_user->id; $args = 'user_id='.$user_id.'&per_page=10&populate_extras=0'; if ( bp_has_members( $args ) ){ ?> <div class="item-avatar"> <a href=""></a> </div> <?php } else echo 'You have no friends!'; ?>I believe, that if you pass user_id to bp_has_members loop, it only returns the friends of that user_id.
In reply to: [Resolved] BP 1.5 unserialize profile fieldIn reply to: [Resolved] profiles1. put this in bp-custom.php
`define(“BP_DEFAULT_COMPONENT”,”profile”);`2. put this in bp-custom.php
`define ( ‘BP_ENABLE_ROOT_PROFILES’, true );`If you don’t know what bp-custom is:
https://codex.buddypress.org/extending-buddypress/bp-custom-php/In reply to: [Resolved] adjust nav / subnav linksI was using the wrong hook.
This works:function user_nav_append_url() { global $bp; $tab_anchor = "pictures"; $bp->bp_nav .= $tab_anchor; } add_action( 'wp_head', 'user_nav_append_url', 9 );Simple, and already answered – flip the if/else actions or remove the false operator like so
`if ( is_super_admin() )
$params .= ‘&per_page=5’;
else
$params .= ‘&scope=friends&per_page=5’;`If this is still confusing – read up on if/else and what the ! operator does – it means false.
In reply to: Buddypress plugin of WordPress remote SQL InjectionReported to developers and fixed in version 1.5.5
`if ( is_super_admin() )
$params .= ‘&per_page=5’;
else
$params .= ‘&scope=friends&per_page=5’;
`In reply to: Avatar problem on buddypress.orgAvatars, for most of us, are not allowed.
And no, you can’t search the forums either.
Hopefully that will be fixed soon.In reply to: Modify the member search functionShort answer – don’t do it.
Long answer – could be done, but performance would be terrible because your meta_value is a serialized string.
If you could require some other field(s) for a search and then based on those results then do a sub-search by pulling the wp_s2member_custom_fields into php and unserializing and doing a string search on each one – then performance would be better.
In reply to: New user is listed fifteen times in Member DirectoryShe created trac ticket 4093
>members posting stuff too
It’s tricky on mobile devices, but doable.
You’ll want to use the BP mobile theme for those or build your own.Apple Safari doesn’t allow uploading, so you have to use a workaround like Aurigma Up.
@modemlooper says he built an app that does the same thing and he’s considering releasing an unbrandable version with a site license – I for one sure hope he does.Android allows uploads but things like the avatar crop tool won’t work, afaik.
We built a custom avatar upload page with auto-crop for Android as part of our custom mobile theme.Hopefully you’re lucky enough to have a client that actually understands what is involved when they say they want a ‘facebook’.
One way is to use:
http://www.hitreach.co.uk/wordpress-plugins/allow-php-in-posts-and-pages/Then create a page called ‘Invite’ in wp-admin and put this on the page
between open and close [ php ] tags without the spaces
` locate_template( array( ‘some-theme-dir/invite.php’ ), true ); `The url for that page won’t be your-site/members/invite
It wil be your-site/invite
If it has to be /members/invite, then I’m not sure how to do it.In reply to: Can’t Register, Help!>Why the he++ did you do that to me?
He’s trying to help you.
You’re obviously in over your head in terms of being a dev.
Consider hiring a dev – then you can justify bitching at them.In reply to: Enterprise Nation: a 64,000 member BuddyPress siteVery nice.
I also liked Eco Living.And thanks for the technical features info.
But would you mind sharing some details about your hosting environment?
Such as:
Number of servers & size of.
Database – sharded / replicated?
Any particular issues you had scaling up to 64k members?There are more ‘large’ BP sites out there now.
It be great to collect dev info about scaling up, maybe even create a page hosted here about it.
For example, we have 25k users.
It’s going well, but scaling is an ongoing process.
When we first moved to a load balancer, we couldn’t distribute the load until we figured out that BP makes a lot of calls to ajax files in the wp-admin dir.
We had to add varnish rules so that wp-admin calls went to the master, but public site ajax calls could go to any webhead.