X help with uploading and using Font Woff and Woff2 format - Part 2

HI there,

So I’ve got 2 font faces that I’m trying to use on my site that don’t come standard. I’ve been reading this post:

And I have to say this feature need a lot of work guys…

Any way I to am trying to use the Custom Font section of the Font Manager my self and I’ve switched to the X-Child Theme as listed above and added both snips of code to the functions.php file in the X-child theme and I’m still stuck not being able to even upload the fonts into wordpress:

freight_text_book-webfont.woff Sorry, this file type is not permitted for security reasons.

So I guess I’m stuck there and in need of some help, thx.

Hi John,

Okay, if none of the suggestions on the referenced thread worked, let’s try a different approach then.

This time, you’ll need to edit the wp-config.php file. Please edit it and add this line of code before the line that says /* That's all, stop editing! Happy blogging. */:

define('ALLOW_UNFILTERED_UPLOADS', true);

Then save.

This should allow you to upload any file type, including woff and woff2. After you’ve successfully uploaded all font files you need, it’s good to remove that code from wp-config.php to prevent any possible security issue.

Tell us how it goes.

Ok so I got it that worked thank you!

Just a bit of feedback on the UX, the process of assigning the new fonts was a bit unintuitive so what happen was I assigned the fonts and then they didn’t show up in the media library so I felt like I did it wrong, but when I check the dashbaord media library the fonts were in there so I knew that yes they had indeed been uploaded to the site.

So when I went up to the font manager under the selected font face I saw that it said custom font face, that when I started to get it that I needed to rename the font upload below to something more identifiable, and they every uploaded font should have their own entry.

So it worked great job on that but just some padding text how the custom font entry is going to show up in the manager automatically and that they should change to name to help make this easier to find on the user alleviate some confusion.

1 Like

Thank you for your feedback, John. I’ll forward this as feature request.

johnyct9760 You saved the day. Yes - completely counterintuitive, and unless one selects the generic “Custom Font Family” choice they’ll never realize that they successfully uploaded the typeface. Thanks for the UX observation, and thanks to benursal for the answer about how to upload fints in the first place.

1 Like

Hi @Alan Thanks for the feedback, but it’s mostly Wordpress restriction and should be configured by users depending on active restrictions.

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.