[wp-trac] [WordPress Trac] #61426: Upload Fonts: Invalid parameter(s): font_family_settings

WordPress Trac noreply at wordpress.org
Thu Jun 13 07:13:36 UTC 2024


#61426: Upload Fonts: Invalid parameter(s): font_family_settings
--------------------------+-----------------------------
 Reporter:  benniledl     |      Owner:  (none)
     Type:  defect (bug)  |     Status:  new
 Priority:  normal        |  Milestone:  Awaiting Review
Component:  Editor        |    Version:  6.5.4
 Severity:  normal        |   Keywords:
  Focuses:                |
--------------------------+-----------------------------
 Hello,
 as I try to upload fonts in woff2 format, I get the error message.
 Invalid parameter(s): font_family_settings

 I have uploaded the same font (same name) earlier in a ttf format and have
 deleted it to replace it with a woff2 version.
 When I now upload the woff2 font I get the error:

 {{{
 {
    "code":"rest_invalid_param",
    "message":"Invalid parameter(s): font_family_settings",
    "data":{
       "status":400,
       "params":{
          "font_family_settings":"font_family_settings[ slug ] cannot be
 empty."
       },
       "details":{
          "font_family_settings":{
             "code":"rest_invalid_param",
             "message":"font_family_settings[ slug ] cannot be empty.",
             "data":{
                "status":400
             }
          }
       }
    }
 }
 }}}
 When I upload the ttf font again and then the woff2 font, it works.

 I found out the reason why this is happening is because the font name is
 missing in the metadata of the font. https://fontdrop.info/

 If this happens, it would be nice to have the option to select the name
 yourself.

-- 
Ticket URL: <https://core.trac.wordpress.org/ticket/61426>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list