Overriding post’s font-family

You could run a regex. Since they’re continuing this behavior, you will probably want to create a custom plugin and set up a cron job to trigger it periodically so it will continue stripping all inline styles. Your plugin will need to query all posts. From there, in a loop that checks each post’s content, … Read more

I can’t seem to install Font Awesome locally [closed]

Considering the folder structure “/public_html/wp-content/themes/TestTheme/static/fontawesome/” as folder location for Font Awesome use following instead 1 use following instead of the one you used for js include <script defer src=”https://wordpress.stackexchange.com/questions/299868/<?php echo get_template_directory_uri(); ?>/static/fontawesome/fontawesome-all.js”></script> 2 use following instead of the one you used for CSS include having fontawesome.min.css file in the CSS folder <link rel=”stylesheet” href=”https://wordpress.stackexchange.com/questions/299868/<?php echo … Read more

Add Icon to Placeholder Text in Search Form

If you’re using FontAwesome, you can display an icon in the placeholder text like this : HTML <input placeholder=”&#xf0e0;” class=”fontAwesome”> CSS .fontAwesome{ font-family: ‘Helvetica’, FontAwesome, sans-serif; }

changing font size and font of a custom message added after comment

You can use CSS, either in a separate CSS file like this: .wpd-custom-text{ color: #f44242; font-family: “Times New Roman”, Times, serif; font-size: 15px; font-weight: 900; } or inline like this: <div class=”wpd-custom-text” style=”color:#f44242; font-family: ‘Arial’, ‘Helvetica’, sans-serif; font-size: 15px; font-weight: 900;”>the comment added here is by the author and my website doesn’t have any take … Read more

How can I set Cache TTL for woff and woff2 font files with htaccess?

ExpiresByType font/woff2 “access plus 1 year” ExpiresByType application/font-woff2 “access plus 1 year” ExpiresByType application/x-font-woff2 “access plus 1 year” You need to set ExpiresActive On (at the top) for these directives to have any effect. You also don’t need all 3 of these directives. You should check the Content-Type HTTP response header for the mime-type your … Read more