Posted By

peterbelsky on 04/03/11


Tagged


Versions (?)

Who likes this?

2 people have marked this snippet as a favorite

notturnale
SFLWebDev


Hide the Address Bar within Mobile Web Applications


 / Published in: JavaScript
 

URL: http://davidwalsh.name/hide-address-bar?utm_source=feedburner&utm_medium=feed&utm_campaign=Feed%3A+Bludice+%28David+Walsh+Blog+%3A%3A+PHP%2C+CSS%2C+MooTools%2C+and+Everything+Else%29&utm_content=Google+Reader

  1. // When ready...
  2. window.addEventListener("load",function() {
  3. // Set a timeout...
  4. setTimeout(function(){
  5. // Hide the address bar!
  6. window.scrollTo(0, 1);
  7. }, 0);
  8. });
  9.  
  10.  
  11. Bonus: META Tag for Bookmarked Sites
  12.  
  13. <meta name="apple-mobile-web-app-capable" content="yes" />

Report this snippet  

You need to login to post a comment.