#65245 closed defect (bug) (reported-upstream)
Accented or special characters issue
| Reported by: |
|
Owned by: | |
|---|---|---|---|
| Milestone: | Priority: | normal | |
| Severity: | normal | Version: | |
| Component: | General | Keywords: | has-screenshots |
| Focuses: | Cc: |
Description
On WordPress 7.0-RC4, on the page /wp-admin/credits.php, I encounter an issue with some characters.
At first, I thought there might be a character encoding issue with my database tables on my end, but in fact, some accented characters are displaying correctly elsewhere on the page. And @audrasjb reproduce the issue.
In the screenshots :
- "Fabian Kägy" should be "Fabian Kaegy"
- "Albert Juhテゥ Lluveras" should be "Albert Juhé Lluveras"
- "Alvaro Gテウmez" should be "Alvaro Gómez"
- "Béryl de La Grandière" is ok
- "Eliezer Peテアa" should be "Eliezer Peña"
- "Johannes Jテシlg" should be "Johannes Jülg"
- Etc.
By switching into French language to have a lot of accents, I reproduce the issue on the contributors name, but I have more correct accents in this page, and I didn't detect the issue elsewhere in others admin pages.
Attachments (3)
Change History (10)
#1
@
4 weeks ago
Fabian Kägy is actually correct. ä is a German umlaut. :)
For the other ones, this looks more like an issue on WordPress.org since the API already returns the incorrect encoding, see https://api.wordpress.org/core/credits/1.1/?version=6.9.
The profiles, e.g. https://profiles.wordpress.org/aljullu/ and https://profiles.wordpress.org/anlino/, are looking ok though.
/cc @dd32 since you have worked on this before, IIRC
This ticket was mentioned in Slack in #meta-wordcamp by sebastienserre. View the logs.
4 weeks ago
#3
follow-up:
↓ 4
@
4 weeks ago
Agree with @ocean90, this belongs on meta trac.
This line looks suspicious. It hasn't changed in a long time, but changes to underlying language data or functionality could plausibly produce different results. In particular, listing JIS before UTF-8 in the from encoding seems problematic. Maybe the conversion can be dropped completely if the data is already UTF-8.
<?php $raw = 'é1234567890'; echo mb_convert_encoding($raw, 'UTF-8', 'ASCII, JIS, UTF-8, Windows-1252, ISO-8859-1') . "\n"; // テゥ1234567890 echo mb_convert_encoding($raw, 'UTF-8', 'ASCII, UTF-8, JIS, Windows-1252, ISO-8859-1') . "\n"; // é1234567890
#4
in reply to:
↑ 3
@
4 weeks ago
Replying to jonsurrell:
It hasn't changed in a long time, but changes to underlying language data or functionality could plausibly produce different results.
It looks like the behavior changed in PHP 8.3:
<?php $raw = 'é1234567890'; $raw = mb_convert_encoding( $raw, 'UTF-8', 'ASCII, JIS, UTF-8, Windows-1252, ISO-8859-1' ); // PHP 8.2: é1234567890 // PHP 8.3: テゥ1234567890 echo $raw . "\n";
This ticket was mentioned in Slack in #core by sana_yasir. View the logs.
3 weeks ago
#6
@
3 weeks ago
- Keywords needs-patch needs-testing removed
- Milestone Awaiting Review deleted
- Resolution set to reported-upstream
- Status changed from new to closed
Moved to #meta8253
Character issue in noteworthy contributors