{"id":2317,"date":"2019-01-26T16:56:07","date_gmt":"2019-01-26T21:56:07","guid":{"rendered":"https:\/\/bitpost.com\/news\/?p=2317"},"modified":"2019-01-26T17:43:00","modified_gmt":"2019-01-26T22:43:00","slug":"getting-pretty-google-fonts-into-wordpress","status":"publish","type":"post","link":"https:\/\/bitpost.com\/news\/2019\/getting-pretty-google-fonts-into-wordpress\/","title":{"rendered":"Getting pretty Google fonts into WordPress"},"content":{"rendered":"\n<p><a href=\"https:\/\/www.designbombs.com\/add-google-fonts-wordpress\/\">This article<\/a> is a great explanation of the details.  To explain.. no, too much.  To sum up:<\/p>\n\n\n\n<ul class=\"wp-block-list\"><li>Go to <a href=\"https:\/\/fonts.google.com\/?\">Google Fonts<\/a> and browse around and select ones you like, then click the bar in the footer to get an installation guide.  This generated link is the important part: <ul><li>https:\/\/fonts.googleapis.com\/css?family=<strong>Lato|Montserrat|Oswald|Quicksand|Roboto<\/strong><\/li><li>Because it is a &#8220;heavy thing&#8221;, I pared that list down to Montserrat for paragraph text and Quicksand for headings.<\/li><\/ul><\/li><li>Put one-shot loading of the link into functions.php (details on <a href=\"https:\/\/bitpost.com\/wiki\/Wordpress\">wiki<\/a>); example: <\/li><\/ul>\n\n\n\n<pre class=\"wp-block-preformatted\">function custom_add_google_fonts() {  <br>    wp_enqueue_style( <br>        'custom-google-fonts', <br>        'https:\/\/fonts.googleapis.com\/css?family=Montserrat|Quicksand',<br>        false <br>    );  <br>}  <br>add_action( 'wp_enqueue_scripts', 'custom_add_google_fonts' );<\/pre>\n\n\n\n<ul class=\"wp-block-list\"><li>Specify the style in CSS (details on <a href=\"https:\/\/bitpost.com\/wiki\/Wordpress\">wiki<\/a>):<\/li><\/ul>\n\n\n\n<pre class=\"wp-block-preformatted\">body {  font-family: Montserrat, sans-serif;  font-weight: normal;  }<br>#content h2 {  font-family: Quicksand, sans-serif;  font-weight: bold;  }<\/pre>\n\n\n\n<p><\/p>\n","protected":false},"excerpt":{"rendered":"<p>This article is a great explanation of the details. To explain.. no, too much. To sum up: Go to Google Fonts and browse around and select ones you like, then click the bar in the footer to get an installation guide. This generated link is the important part: https:\/\/fonts.googleapis.com\/css?family=Lato|Montserrat|Oswald|Quicksand|Roboto Because it is a &#8220;heavy thing&#8221;, [&hellip;]<\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"jetpack_post_was_ever_published":false,"_jetpack_newsletter_access":"","_jetpack_dont_email_post_to_subs":false,"_jetpack_newsletter_tier_id":0,"_jetpack_memberships_contains_paywalled_content":false,"_jetpack_memberships_contains_paid_content":false,"footnotes":"","jetpack_publicize_message":"","jetpack_publicize_feature_enabled":true,"jetpack_social_post_already_shared":true,"jetpack_social_options":{"image_generator_settings":{"template":"highway","default_image_id":0,"enabled":false},"version":2}},"categories":[10,20],"tags":[],"class_list":["post-2317","post","type-post","status-publish","format-standard","hentry","category-tricks-tips-tools","category-wordpress"],"aioseo_notices":[],"jetpack_publicize_connections":[],"jetpack_featured_media_url":"","jetpack_sharing_enabled":true,"jetpack_shortlink":"https:\/\/wp.me\/p9M11L-Bn","jetpack_likes_enabled":true,"_links":{"self":[{"href":"https:\/\/bitpost.com\/news\/wp-json\/wp\/v2\/posts\/2317","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/bitpost.com\/news\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/bitpost.com\/news\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/bitpost.com\/news\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/bitpost.com\/news\/wp-json\/wp\/v2\/comments?post=2317"}],"version-history":[{"count":5,"href":"https:\/\/bitpost.com\/news\/wp-json\/wp\/v2\/posts\/2317\/revisions"}],"predecessor-version":[{"id":2336,"href":"https:\/\/bitpost.com\/news\/wp-json\/wp\/v2\/posts\/2317\/revisions\/2336"}],"wp:attachment":[{"href":"https:\/\/bitpost.com\/news\/wp-json\/wp\/v2\/media?parent=2317"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/bitpost.com\/news\/wp-json\/wp\/v2\/categories?post=2317"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/bitpost.com\/news\/wp-json\/wp\/v2\/tags?post=2317"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}