Make WordPress Core

Opened 5 years ago

Closed 5 years ago

#48313 closed defect (bug) (fixed)

Administration email verification uses the site locale instead of the user's locale

Reported by: timothyblynjacobs's profile TimothyBlynJacobs Owned by: sergeybiryukov's profile SergeyBiryukov
Milestone: 5.3.1 Priority: normal
Severity: normal Version: 5.3
Component: Users Keywords: has-patch needs-testing fixed-major
Focuses: Cc:

Description

Given a site locale of German, and a user locale of English. When you login in the "Administration email verification" screen is partially in German instead of English.

I think this is because get_user_locale only works in the admin, which wp-login.php doesn't count as.

A possible fix might be to pass wp_lang when building the redirect URL?

<?php
$redirect_to = add_query_arg( array( 'action' => 'confirm_admin_email', 'wp_lang' => $user->locale ), wp_login_url( $redirect_to ) );

Attachments (1)

48313.patch (670 bytes) - added by sathyapulse 5 years ago.
48313.patch

Download all attachments as: .zip

Change History (11)

#1 @SergeyBiryukov
5 years ago

  • Component changed from General to Users

#2 @SergeyBiryukov
5 years ago

  • Milestone changed from Awaiting Review to 5.3.1

@sathyapulse
5 years ago

48313.patch

This ticket was mentioned in Slack in #core by audrasjb. View the logs.


5 years ago

#4 @audrasjb
5 years ago

  • Keywords has-patch needs-testing added

#5 @audrasjb
5 years ago

  • Keywords needs-refresh added

Hi @sathyapulse ,

The patch doesn't apply cleanly, could you generate a new one against wordpress-develop please? thanks!

#6 @audrasjb
5 years ago

  • Keywords needs-refresh removed

Sorry, it's all good.

#7 @SergeyBiryukov
5 years ago

  • Owner set to SergeyBiryukov
  • Status changed from new to reviewing

#8 @SergeyBiryukov
5 years ago

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

In 46788:

Users: Display admin email verification screen in user's locale instead of site locale.

Props sathyapulse, TimothyBlynJacobs.
Fixes #48313.

#9 @SergeyBiryukov
5 years ago

  • Keywords fixed-major added
  • Resolution fixed deleted
  • Status changed from closed to reopened

Reopening for 5.3.1.

#10 @SergeyBiryukov
5 years ago

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

In 46789:

Users: Display admin email verification screen in user's locale instead of site locale.

Props sathyapulse, TimothyBlynJacobs.
Merges [46788] to the 5.3 branch.
Fixes #48313.

Note: See TracTickets for help on using tickets.