1. 程式人生 > >Meta標簽中的format-detection屬性及含義

Meta標簽中的format-detection屬性及含義

format 數字 str strong 點擊 開啟 轉化 翻譯 pan

format-detection翻譯成中文的意思是“格式檢測”,顧名思義, 它是用來檢測html裏的一些格式的,那關於meta的format-detection屬性主要是有以下幾個設置:   meta name="format-detection" content="telephone=no"   meta name="format-detection" content="email=no"   meta name="format-detection" content="adress=no" 也可以連寫:   meta name="format-detection" content="telephone=no,email=no,adress=no" 下面具體說下每個設置的作用: 一、telephone

你明明寫的一串數字沒加鏈接樣式,而iPhone會自動把你這個文字加鏈接樣式、並且點擊這個數字還會自動撥號!想去掉這個撥號鏈接該如何操作呢?這時我們的meta又該大顯神通了,代碼如下:

telephone=no就禁止了把數字轉化為撥號鏈接!
telephone=yes就開啟了把數字轉化為撥號鏈接,要開啟轉化功能,這個meta就不用寫了,在默認是情況下就是開啟!

二、email

告訴設備不識別郵箱,點擊之後不自動發送

email=no禁止作為郵箱地址!
email=yes就開啟了把文字默認為郵箱地址,這個meta就不用寫了,在默認是情況下就是開啟!

三、adress

adress=no禁止跳轉至地圖!
adress

=yes就開啟了點擊地址直接跳轉至地圖的功能,在默認是情況下就是開啟!

Meta標簽中的format-detection屬性及含義