Opened 11 years ago
Closed 11 years ago
#1008 closed defect (bug) (fixed)
Fonts Plugin: Unable to add Secure URL for Google Fonts under Appearance > Fonts
| Reported by: | andywashere | Owned by: | kovshenin |
|---|---|---|---|
| Priority: | high | Milestone: | |
| Component: | WordCamp Site & Plugins | Keywords: | |
| Cc: |
Description
Steps to reproduce:
- On any WordCamp site, go to Appearance → Fonts.
- Paste in a Google Web Fonts @import rule with an
https://URL, e.g.:
@import url('https://fonts.googleapis.com/css?family=Titillium+Web:400,700');
- Click Save Changes.
After changes are saved, the https:// in the URL is changed to http://. Since WordCamp sites are now forcing https, this causes the font not to be loaded in some browsers, due to an http/https mismatch.
Change History (3)
Note:
See TracTickets
for help on using tickets.
![(please configure the [header_logo] section in trac.ini)](/chrome/site/your_project_logo.png)
It looks to be the
esc_url_rawon line 123 of wc-fonts.php that is forcing http:https://meta.trac.wordpress.org/browser/sites/trunk/wordcamp.org/public_html/wp-content/plugins/wc-fonts/wc-fonts.php#L123
The line should probably be changed to:
if ( $matches ) $url = esc_url_raw( 'https://' . $matches[0] );