用IE9把你的網(wǎng)站定到任務(wù)欄
效果先上圖:像iPad iPhone 可以把網(wǎng)頁(yè)當(dāng)成一個(gè)APP 圖標(biāo)一樣的放在桌面上。可以快速啟動(dòng)。
IE9+ 的版本提供了這個(gè)功能,只需要在 網(wǎng)頁(yè)的 head 里面設(shè)置相應(yīng)的 meta 字段即可。
具體原理可以參見(jiàn)這兒: IE9瀏覽器固定網(wǎng)站功能的實(shí)現(xiàn)方法

實(shí)現(xiàn)的代碼:
<!doctype html> <html> <head> <meta charset="utf-8"> <title>IE9 自定義圖標(biāo)</title> <meta name="keywords" content="壁紙,手機(jī)壁紙,安卓手機(jī)壁紙,高清壁紙合集,安卓壁紙下載,電腦桌面,iPhone壁紙,安卓壁紙"> <meta name="description" content="wallfaves.com 為您提供多種風(fēng)格的高清壁紙,無(wú)論您使用電腦,安卓手機(jī),iPhone,iPad您都可以從wallfaves.com 找到您喜歡的壁紙"> <link rel="shortcut icon" href="http://localhost/ie9test/wallfaves.ico"> <meta name="msapplication-task" content="name=task1首頁(yè);action-uri=http://wallfaves.com/?ie9;icon-uri=http://wallfaves.com/resource/img/wallfaves.ico" /> <meta name="msapplication-task" content="name=task2分類(lèi);action-uri=http://wallfaves.com/?ie9;icon-uri=http://wallfaves.com/resource/img/wallfaves.ico" /> <meta name="msapplication-task" content="name=task3標(biāo)簽;action-uri=http://wallfaves.com/?ie9;icon-uri=http://wallfaves.com/resource/img/wallfaves.ico" /> </head> <body> TTEESSTT </body> </html>
注意:
content="name=task1首頁(yè);action...
content 字段取值不能有空格,有空格,后面就解析不下去了。起碼我的IE10 是這樣的。
前進(jìn)后退的按鈕 在添加到任務(wù)欄完成后,會(huì)自動(dòng)根據(jù) ico 的色調(diào)變化,大部分情況下不需要再單獨(dú)設(shè)置
<meta name=”msapplication-navbutton-color” content=”#0099cc” /> 等顏色~
posted on 2013-05-07 16:19 trance 閱讀(241) 評(píng)論(0) 收藏 舉報(bào)
浙公網(wǎng)安備 33010602011771號(hào)