Skip to:
Content

BuddyPress.org

Opened 7 years ago

Closed 3 years ago

#4646 closed enhancement (fixed)

Deleting profile fields - UX issue

Reported by: rogercoathup Owned by: slaFFik
Milestone: 2.8 Priority: normal
Severity: normal Version: 1.5
Component: Administration Keywords:
Cc:

Description

In wp-admin (users.. profile fields).

If I delete a profile field from a profile field group, it always redirects me back to the base profile field group tab.

For a better UX experience, it should redirect you back to the field group you were working on.

Attachments (1)

4646.patch (825 bytes) - added by slaFFik 3 years ago.

Download all attachments as: .zip

Change History (8)

#1 @DJPaul
7 years ago

  • Milestone changed from Awaiting Review to Future Release
  • Version changed from 1.7 to 1.5

#2 @DJPaul
7 years ago

  • Component changed from Core to Administration

#3 @mercime
3 years ago

  • Keywords needs-patch added

Confirming that this is still an issue as of BP 2.7 trunk. Needs fix for better UX and Accessibility.

@slaFFik
3 years ago

#4 @slaFFik
3 years ago

  • Keywords has-patch added; needs-patch removed
  • Milestone changed from Future Release to 2.8

#5 @DJPaul
3 years ago

  • Keywords needs-patch added; has-patch removed

Eeep, scary old code! :) Rather than tack a new part on the end, let's improve the whole thing. While there isn't an output escaping issue as such, the way it has been done already is less than perfect.

We need to esc_url the entire value for the href attribute, and use either add_query_arg or sprintf to concatenate the hardcoded URL and the variables together. Think also about how to escape the values you're concatenating (strings would usually be passed through urlencode but it looks like these are integers, so you could do a simple cast to make that clear).

I think you'd do this above the HTML part of the function, because trying to do all that inline would make the line length really long.

#6 @slaFFik
3 years ago

  • Keywords needs-patch removed
  • Owner set to slaFFik
  • Status changed from new to assigned

#7 @slaffik
3 years ago

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

In 11345:

Profile: redirect to group after profile field deleted.

When deleting a profile field we should redirect back to a fields group, where the field was deleted from. That's a UX improvement.

Props rogercoathup, DJPaul.
Fixes #4646.

Note: See TracTickets for help on using tickets.