iPad联系链接CSS覆盖 [英] iPad Contact Link CSS Override
问题描述
我有一个网页,其中有一个电话号码显示在页面标题中。
I have a web page with a phone number being displayed in the page header. The font color for that section of the page is brown.
在iPad上查看网页时,iPad(正确地)会将文字检测为电话号码并自动生成将电话号码文本转换为联系链接。
When the page is viewed on an iPad, the iPad (correctly) detects the text as a phone number and automagically converts the phone number text to a "contact link".
我的问题是,我无法强制链接颜色为棕色 - 无论我在CSS文件中做什么(包括!important ),电话号码总是显示在自己的自定义颜色!
My problem is that I am unable to FORCE the link color to be brown - regardless of what I do in the CSS file (including "! important" after the color statement), the phone number is always being displayed in it's own self-appointed color!
有关如何获得我的CSS声明赢得战争的任何线索?
Any clues on how to get my CSS declaration to win the war?
推荐答案
看起来ipad会将数字包含在< a> ;.我只是为此添加了一个附加规则:
It seems like ipad wraps the number in an <a>. I just added an additional rule for this:
之前:
.phone {color:red; }
之后:
.phone,
.phone a {color:red; }
这篇关于iPad联系链接CSS覆盖的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!