Safari 热门网站预览 [英] Safari Top Sites Preview

查看:36
本文介绍了Safari 热门网站预览的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在 Safari 的热门站点"部分,iCloud.com 图像显示徽标而不是登录屏幕,如下所示.通常,Top Sites 只显示加载的网页的图片(加载的页面不是这样的).你知道他们是如何做到这一点的吗?我在 Apple 的文档中找不到任何内容.感谢您的帮助.

In the Top Sites section of Safari, the iCloud.com image shows the logo instead of the login screen as you can see below. Normally, the Top Sites just shows a picture of the loaded web page (and the loaded page does not look like this). Do you have any idea how they accomplished this? I couldn't find anything in Apple's documentation. Thanks for your help.

推荐答案

以下是在 iCloud 上显示热门网站特定预览的方法:(针对格式进行了编辑)

Here's how it's done on iCloud to show a Top Sites specific preview: (edited for formatting)

if (window.navigator && window.navigator.loadPurpose === "preview") {
    window.location.href = "http://www.icloud.com/topsites_preview/";
};

来源:http://blog.raffael.me/post/18565169038/defining-how-your-website-looks-like-in-safari-topsites

这篇关于Safari 热门网站预览的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆