Window.deviceid = ' {$deviceId}} '; Window.ios = Navigator.userAgent.match (/(ipad|iphone|ipod)/g)? True:false; if (IOS) { iosversion = (!! Window.history &&!! Window.history.pushState? ' 4+ ': ' 4-'); if (!! Window.matchmedia) {iosversion = ' 5+ ';} } Window.getviewport = function () { //Note viewport sizing broken in Android 2.x see http://stackoverflow.com/questions /6601881/problem-with-meta-viewport-and-android var viewport = { Left:window.pageXOffset, /////HTTP www.quirksmode.org/mobile/tableViewport.html top:window.pageYOffset, width:window.innerWidth | | Documentelement.clientwidth, height:window.innerHeight | | documentelement.clientheight }; return viewport; }
It can be elevated on Android, but there is a problem on the iOS machine.
On an iOS machine, you don't always get to the bottom by bottom, but by calculating the top position and then adjusting the position by Scrollto.
Window.timedelay = +; SetInterval (function () { window.scrollto (0, 0); }, Timedelay);
iOS device, fixed layout problem