Skip to:
Content

BuddyPress.org

Opened 13 years ago

Closed 13 years ago

Last modified 12 years ago

#276 closed defect (bug) (fixed)

Group create storing wrong url when user logs into a subdomain to create a group

Reported by: burtadsit Owned by:
Milestone: Priority: major
Severity: Version:
Component: Keywords: avatars, groups
Cc:

Description

When a user logs into a subdomain burt.mysite.org and then creates a group, the url mysite.org/members/burt/wp-content ... is stored instead of mysite.org/wp-content ...

The global $bploggedin_domain? contains the domain and the member slug. Slug the right term? Anyway, the function groups_get_avatar_hrefs() happily replaces the ABSPATH with the wrong url and it gets stored.

Thereby insuring nobody ever sees that avatar again. :) I haven't figured out why $bploggedin_domain? contains the wrong url yet. Should that even be used? I'm tired and I wish I had a global var reference next to me. (I know, write one). What should be used get_bloginfo(1, 'siteurl')? Why do a db query if something more appropriate is avail.

Change History (5)

#1 @burtadsit
13 years ago

Since I reported a group avatar problem under windows, I guess I'll tackle both of 'em at the same time. That one was #265

#2 @burtadsit
13 years ago

I talked to Andy about this ticket. This is just a reminder for him.

/mu-plugins/bp-groups.php in function groups_get_avatar_hrefs() line number 1152 now reads:

$src = $bploggedin_domain?;

change it to:

$src = trailingslashit($bproot_domain?);

Fixes the upload group avatar when logging into a subdomain problem.

#3 @burtadsit
13 years ago

(sigh) I never remember to use code blocks here. Like they don't expect us to post snippets of code? We gotta talk to those Trac people.

$src = $bp['loggedin_domain'];

change it to:

$src = trailingslashit($bp['root_domain']);

#4 @apeatling
13 years ago

  • Resolution set to fixed
  • Status changed from new to closed

#5 @(none)
12 years ago

  • Milestone Groups 1.0 deleted

Milestone Groups 1.0 deleted

Note: See TracTickets for help on using tickets.