Skip to content

Instantly share code, notes, and snippets.

@data-enhanced
Created July 14, 2013 20:45
Show Gist options
  • Save data-enhanced/5995936 to your computer and use it in GitHub Desktop.
Save data-enhanced/5995936 to your computer and use it in GitHub Desktop.
Quick fix to hide browser address bar in mobile safari -- Credit David Walsh -- http://davidwalsh.name/hide-address-bar
// Credit David Walsh
// http://davidwalsh.name/hide-address-bar
window.addEventListener("load",function() {
// Set a timeout...
setTimeout(function(){
// Hide the address bar!
window.scrollTo(0, 1);
}, 0);
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment