![]() ![]() Have you still got single quote marks around your pasted URL? Now take a second to just double check it looks ok. Your code should look something like this: /** Next, paste/replace this text with that shown in pink above. Wp_register_style('googleFonts', ' insert URL') Īdd_action('wp_print_styles', 'load_fonts') īefore you hit update, go back to the code you copied from Google and pasted into your text editor. Then at the very bottom of this file paste this piece of code /** Log into your WordPress site and navigate to your theme editor page via Appearance>Editor Step 3 – Enqueue your chosen Google font stylesheet If the next step fails, re-upload your backup file and try again.įollow step 1 in this tutorial if you’re unsure how to go about this. So whenever you plan to edit it, copy the file to your computer as a backup. ![]() Step 2 – Back up your theme functions.php fileĪs we’ve mentioned in several posts before it is easy to ruin your day with a small typo when editing your theme’s function file. We’ll need this later – but let’s move on. So open up your favourite text editor app like Word (PC) or TextEdit (Mac) and paste the code into a blank document. You only need to copy the URL portion of the code, but Google won’t let you copy anything less than all of it. Scroll down the page and copy the code in step 3. Check the impact-o-meter readout and try to keep in the green zone. Some fonts have greater impact than others. Select a font and hit the Quick Use icon.īe aware that the more styles you choose the greater the impact on page loading speed. Step 1 – Choose your font from the Google font store (they’re free to use!) The ability to add Google fonts to your WordPress website is a four step process and especially useful for those wanting to customise their site a little further.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |