Skip to content


Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Fetching contributors…

Cannot retrieve contributors at this time

41 lines (40 sloc) 1.039 kb
<!doctype html>
<link href="/basic.css" rel="stylesheet" type="text/css">
<script type="text/javascript" src="/webfont.js"></script>
<script type="text/javascript">
google: {
families: ['Droid Sans'],
api: '/fonts/api'
fontactive: function(familyName, fontDescription) {
if (familyName == 'Droid Sans') {
var h1 = document.getElementsByTagName('h1')[0];
h1.innerHTML = 'Hello World. I am ' + familyName + ' (' + fontDescription + ')';
<style type="text/css">
h1 {
font-family: 'Droid Sans';
Hello World.
<a href="#" onclick="document.getElementsByTagName('body')[0].style.color = '#fff';return false;">Hide Page</a> |
<a href="/event-js-font-active.html">Reload Cached</a>
The goal of this page is to use JavaScript to manipulate the page when
a particular font loads.
Jump to Line
Something went wrong with that request. Please try again.