iPhone手机网+删除safari界面栏

use*_*300 3 iphone xhtml mobile

一个人知道如何删除safari iphone顶部和底部的栏.我有这个移动网页写作,我无法摆脱导航栏.这甚至可能吗?

谢谢.

mdi*_*ici 6

<meta name="viewport" content="width=device-width; initial-scale=1.0; maximum-scale=1.0; user-scalable=0;" />

<!-- this is the part responsible for hidding the bottom bar -->
<meta name="apple-mobile-web-app-capable" content="yes" />

<meta names="apple-mobile-web-app-status-bar-style" content="black-translucent" />
Run Code Online (Sandbox Code Playgroud)

唯一的问题是它只有在用户将链接保存到他们的iPhone桌面后才能工作.

希望这能解决你的问题.


Rom*_*man 5

您无法从Safari应用程序的顶部和底部删除栏.我已经看过在没有两个条形码的情况下将Safari嵌入其中的应用程序,但是您无法在页面中使用Javascript或元数据标记来执行此操作.

UPDATE

有一些技巧可以让你通过滚动页面来隐藏地址栏.像这样的东西:

<script type="application/x-javascript">
    addEventListener("load", function() { setTimeout(hideURLbar, 0); }, false);

    function hideURLbar(){
        window.scrollTo(0,1);
    }
</script>
Run Code Online (Sandbox Code Playgroud)