[wp-trac] [WordPress Trac] #63568: WP_Font_Face: Font names that contain single quotes are not wrapped in double quotes

WordPress Trac noreply at wordpress.org
Fri Jun 20 02:07:15 UTC 2025


#63568: WP_Font_Face: Font names that contain single quotes are not wrapped in
double quotes
-------------------------------------------------+-------------------------
 Reporter:  wildworks                            |       Owner:  audrasjb
     Type:  defect (bug)                         |      Status:  accepted
 Priority:  normal                               |   Milestone:  6.9
Component:  Editor                               |     Version:  6.4
 Severity:  normal                               |  Resolution:
 Keywords:  has-patch has-test-info has-         |     Focuses:  ui
  screenshots reporter-feedback                  |
-------------------------------------------------+-------------------------

Comment (by wildworks):

 @SirLouen

 Thanks for the test. The disappearance of the font file may be a problem
 with my environment.

 I tested it again using [https://playground.wordpress.net/wordpress.html
 Playground], but I was unable to reproduce the problem you are
 encountering. I used the following two browsers:

 - Chrome 137.0.7151.119
 - Firefox 139.0.4

 On the front end, could you make sure the following code is present in
 your source? If they are all present after running the test steps
 correctly, the font should be applied correctly.

 {{{
 <style class='wp-fonts-local'>
 @font-face{
   font-family:"O'Reilly Sans";
   font-style:normal;
   font-weight:400;
   font-display:fallback;
   src:url('/path/to/wp-content/uploads/fonts/O-Reilly-Sans-Regular.ttf')
 format('truetype');
 }
 </style>

 <style id='global-styles-inline-css'>
 :root{
   --wp--preset--font-family--oreilly-sans: "O'Reilly Sans";
 }
 body{
   font-family: var(--wp--preset--font-family--oreilly-sans);
 }
 </style>
 }}}

-- 
Ticket URL: <https://core.trac.wordpress.org/ticket/63568#comment:22>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list