Just discovered this strange behaviour in Safari (and Safari mobile). If you are using a cross-page url with a hash tag, first it must be formatted thus:
Note the slash before the hash. That’s apparently key to getting the hash recognized in Safari. Doesn’t seem to break in other browsers this way.
//no good: var hash = window.location.hash.replace('tab-', ''); //good: var hash = location.hash.replace('tab-', '');
Again, this seems to work in other browsers.