Make WordPress Core

Opened 10 years ago

Closed 10 years ago

#20764 closed defect (bug) (fixed)

Role names not translated in new user notification message in MS

Reported by: kobenland Owned by: ryan
Milestone: 3.5 Priority: normal
Severity: normal Version: 3.3.2
Component: I18N Keywords: has-patch dev-feedback
Focuses: Cc:

Description

In Multisite when a new user gets added to a site, the role name in the notification message does not get translated.

Currently the role name itself is used (which is lowercase and English only) not the role display name.

In the patch I call get_editable_roles() to also take custom role names into account, when fetching the role display name.

Attachments (3)

20764.diff (1.9 KB) - added by kobenland 10 years ago.
20764.2.diff (1.9 KB) - added by obenland 10 years ago.
Removed spaces around static keys, as suggested by nacin
20764.3.diff (1.9 KB) - added by obenland 10 years ago.
Removed instances of esc_html() in favor of wp_specialchars_decode()

Download all attachments as: .zip

Change History (7)

@kobenland
10 years ago

#1 @SergeyBiryukov
10 years ago

  • Milestone changed from Awaiting Review to Future Release

Closed #14830 as a duplicate.

@obenland
10 years ago

Removed spaces around static keys, as suggested by nacin

#2 @nacin
10 years ago

Looks good, though a note, esc_html() going into an email looks off. But that's a recurring theme through MS and core.

#3 @ryan
10 years ago

  • Milestone changed from Future Release to 3.5

@obenland
10 years ago

Removed instances of esc_html() in favor of wp_specialchars_decode()

#4 @ryan
10 years ago

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

In [21316]:

Translate role names in the new user notification email. Props obenland. fixes #20764

Note: See TracTickets for help on using tickets.