Commit 063a74f
committed
Media: Modify escaping used for upload image announcements.
Replaces `esc_js()` with `wp_json_encode()` for escaping the screen reader announcement when a media upload fails. As the code is within a `<script>` tag rather than an inline script handler, the `esc_js()` function would cause special characters to be announced in their HTML encoded form rather than as the character, eg `&` would be announced as `&`.
Follow up to [60263].
Props peterwilsoncc, joedolson.
Fixes #63114.
git-svn-id: https://develop.svn.wordpress.org/trunk@60520 602fd350-edb4-49c9-b593-d223f7449a821 parent 8983c6b commit 063a74f
1 file changed
+2
-2
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
142 | 142 | | |
143 | 143 | | |
144 | 144 | | |
145 | | - | |
| 145 | + | |
146 | 146 | | |
147 | 147 | | |
148 | | - | |
| 148 | + | |
149 | 149 | | |
150 | 150 | | |
151 | 151 | | |
| |||
0 commit comments