Issue #292, Patch for IE6/IE7, getHash() expects document, not location.