Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我看过一次,我再也找不到了:
如何通过 JavaScript 检测是否从 url 输入或跳板中的图标打开了 iphone webapp?
谢谢!
您可以检测页面是否以全屏模式打开。
if (window.navigator.standalone) { // } else { // }
从带有以下元标记的主屏幕图标启动的页面将以全屏模式打开。
<meta name="apple-mobile-web-app-capable" content="yes" />