tiechui

  博客园  :: 首页  :: 新随笔  :: 联系 :: 订阅 订阅  :: 管理

1.

apple api :http://developer.apple.com/library/safari/#documentation/AppleApplications/Reference/SafariHTMLRef/Articles/MetaTags.html

others:http://mobile.tutsplus.com/tutorials/iphone/iphone-web-app-meta-tags/

full screen:

1. add <meta name="apple-mobile-web-app-capable" content="yes"> to html head.

2. run web apps, click “+” , add to home screen, add

3. run link on desktop, it will full screen, every pages need add this <meta>

  if run at safari, that will not full screen.

 

viewport:

<meta name="viewport" content="width=device-width, initial-scale=1, minimum-scale = 1, maximum-scale = 5, user-scalable = yes" />

 zoom in/ zoom out

user-scalable: yes, can zoom; no: can't; default yes

scale: 0-10, it seems no effect below 1;

 

Application icon:

<link rel="apple-touch-icon" href="../image/iphone-icon.png" />

 

2 . (this is better)

js code
$(window).load(function() {
    setTimeout(function(){
        if(typeof(window.scrollTo) == 'function'){
            window.scrollTo(0, 1);
        }
    }, 100);
});

 

scroll header to top(hide), if you need, scroll down, it appears.

 

posted on 2010-11-10 15:22  tiechui  阅读(626)  评论(0编辑  收藏  举报