don't assume document.head exists (e.g. IE8)
Merge pull request #1 from pkyeck/master

don't assume document.head exists (e.g. IE8)