Does anyone know how I can remove the address bar from the Android browser to better view my web app and make it look more like a native app?
Built-in Fullscreen Mode in Chrome for AndroidTapping the Menu button (three vertical dots) in the upper right-hand corner of the screen (or tap the hardware menu button on those devices having one)
You can do that with the next code
if(navigator.userAgent.match(/Android/i)){ window.scrollTo(0,1); }
I hope it helps you!
Here's the NON-jQuery solution that instantly removes the address bar without scrolling. Also, it works when you rotate the browser's orientation.
function hideAddressBar(){ if(document.documentElement.scrollHeight<window.outerHeight/window.devicePixelRatio) document.documentElement.style.height=(window.outerHeight/window.devicePixelRatio)+'px'; setTimeout(window.scrollTo(1,1),0); } window.addEventListener("load",function(){hideAddressBar();}); window.addEventListener("orientationchange",function(){hideAddressBar();});
It should work with the iPhone also, but I couldn't test this.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With