How TO - Google Fonts


googletag.cmd.push(function() googletag.display('div-gpt-ad-1422003450156-2'); );
How TO - Google Fonts
❮ Previous
Next ❯
Learn how to use Google Fonts on your web page.
Example
Use this font for free!
All of Google fonts are free and easy to use.
Try it Yourself »
810 Google Fonts
Currently there are 810 fonts available at Google:
Your search did not match any fonts.
var fontjson;
function googleFonts()
var xmlhttp;
xmlhttp = new XMLHttpRequest();
xmlhttp.onreadystatechange = function()
if (this.readyState == 4 && this.status == 200)
fontjson = JSON.parse(xmlhttp.responseText);
downloadfonts();
drawtable();
window.setTimeout(function () drawtable(2);,1000);
;
xmlhttp.open("GET", "https://www.googleapis.com/webfonts/v1/webfonts?key=AIzaSyCz-kpy86ft7U0Dh1LYkhTxrr_QPK27s1I&", true);
xmlhttp.send();
function drawtable()
var l, i, txt, ff;
l = fontjson.items.length;
document.getElementById("spancount").innerHTML = l;
document.getElementById("spancount2").innerHTML = l;
txt = "
Font Family | Example | "; for (i = 0; i < l; i++) ff = fontjson.items[i].family; txt += " |
---|---|---|
" + ff + ""; txt += " | Lorem ipsum dolor sit amet"; txt += " | Try it"; txt += ""; txt += ""; document.getElementById("fonttable").innerHTML = txt; function downloadfonts() var i, j, l, ff, linkrel, fonts; if (!fontjson) return false; l = fontjson.items.length; i = 0; while (i < l) linkrel = document.createElement("link"); linkrel.setAttribute("href", "https://fonts.googleapis.com/css?family=" + fonts); linkrel.setAttribute("rel", "stylesheet"); document.getElementsByTagName("head")[0].appendChild(linkrel); i = i + 100; } googleFonts(); function filterSearch() var a, b, i, j, c, r, tr, td; a = document.getElementById("fonttable"); tr = a.getElementsByTagName("tr"); c = document.getElementById("searchstring").value; for (i = 0; i |