Opened 4 years ago
Closed 4 years ago
#5892 closed enhancement (fixed)
Update WordPress.org Openverse theme to pass i18n/L10n info to the iframe
| Reported by: |
|
Owned by: |
|
|---|---|---|---|
| Milestone: | Priority: | normal | |
| Component: | General | Keywords: | has-patch |
| Cc: |
Description
The GitHub PR (https://github.com/WordPress/wordpress.org/pull/39) adds styling to ensure that the iframe on site https://wordpress.org/openverse receives i18n data from the parent window (when it asks for it).
Change History (2)
Note: See
TracTickets for help on using
tickets.
Fixes WordPress/openverse-frontend#189
Closes https://meta.trac.wordpress.org/ticket/5892
---
This PR adds functionality for the Openverse frontend loaded in the
iframeto ask the parent window information about the locale.iframe—(localeGetevent)→ parent windowiframe←(localeSetevent)— parent window## Description
The
localeSetmessage contains the following data:{{{json
{
}
}}}
| Key | Interpretation |
|
dir| Value of parent HTMLdirattribute ||
lang| Value of parent HTMLlangattribute ||
locale| Value of WordPressget_locale()function |