字体大小继承IE6问题 [英] font-size inheritance IE6 problem

查看:63
本文介绍了字体大小继承IE6问题的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

以下代码适用于Firefox。但IE显示的链接是

font-size = 13而不是font-size = 10。为什么?如果它是一个已知的IE bug,我应该如何修复它?b $ b我总是希望超链接的大小为

下一个父元素的类。


感谢您的帮助,

Shashi


< HTML>

< head>< Title>示例对于cellspacing< / title>

< style>

* {

font-family:Verdana,Helvetica,Arial,sans-serif;

font-size:13px;

}


a,a:已访问{

字体大小:继承;

颜色: #0000FF;

text-decoration:none

}


a:悬停{

颜色: #FF0000;

}


..footer {

颜色:#FFFFFF;

text -align:center;

font-family:Verdana,Helvetica,Arial,sans-serif;

font-size:10px;

background -color:#999966;

}

< / style>

< / head>

< ; BODY>

< p class =" footer">

这是< a href ="#&quo t;>一个你永远不会使用的页脚< / at。

< / p>

< / BODY>

< / HTML>

The following code works in firefox. But IE displays the hyperlink at
font-size=13 rather than font-size=10. Why? If its a known IE bug, how
should I fix it? I always want the hyperlinks to take the size of the
next parent element''s class.

thanks for the help,
Shashi

<HTML>
<head><Title>Example For cellspacing</Title>
<style>
* {
font-family: Verdana, Helvetica, Arial, sans-serif;
font-size: 13px;
}

a, a:visited {
font-size: inherit;
color: #0000FF;
text-decoration: none
}

a:hover {
color: #FF0000;
}

..footer {
color: #FFFFFF;
text-align: center;
font-family: Verdana, Helvetica, Arial, sans-serif;
font-size: 10px;
background-color: #999966;
}
</style>
</head>
<BODY>
<p class="footer">
this is <a href="#">a footer</athat you would never use.
</p>
</BODY>
</HTML>

推荐答案

按正文替换*。然后你的页面中的每个字体将是13px,

,除非它在一个html元素中定义了另一个字体大小,例如

你的页脚。这就是他们称之为级联的原因。样式表。

sr*******@gmail.com schreef:
Replace * by body. Then every font in your page will be size 13px,
unless it is in an html element for which defined another font size, eg
your footer. That''s why they call it "cascading" style sheets.

sr*******@gmail.com schreef:

以下代码适用于firefox。但IE显示的链接是

font-size = 13而不是font-size = 10。为什么?如果它是一个已知的IE bug,我应该如何修复它?b $ b我总是希望超链接的大小为

下一个父元素的类。


感谢您的帮助,

Shashi


< HTML>

< head>< Title>示例对于cellspacing< / title>

< style>

* {

font-family:Verdana,Helvetica,Arial,sans-serif;

font-size:13px;

}


a,a:已访问{

字体大小:继承;

颜色: #0000FF;

text-decoration:none

}


a:悬停{

颜色: #FF0000;

}


.footer {

颜色:#FFFFFF;

text- align:center;

font-family:Verdana,Helvetica,Arial,sans-serif;

font-size:10px;

background-颜色:#999966;

}

< / style>

< / head>

< BODY>

< p class =" footer">

这是< a href =" ;#">一个页脚< / athat你永远不会使用。

< / p>

< / BODY>

< / HTML>
The following code works in firefox. But IE displays the hyperlink at
font-size=13 rather than font-size=10. Why? If its a known IE bug, how
should I fix it? I always want the hyperlinks to take the size of the
next parent element''s class.

thanks for the help,
Shashi

<HTML>
<head><Title>Example For cellspacing</Title>
<style>
* {
font-family: Verdana, Helvetica, Arial, sans-serif;
font-size: 13px;
}

a, a:visited {
font-size: inherit;
color: #0000FF;
text-decoration: none
}

a:hover {
color: #FF0000;
}

.footer {
color: #FFFFFF;
text-align: center;
font-family: Verdana, Helvetica, Arial, sans-serif;
font-size: 10px;
background-color: #999966;
}
</style>
</head>
<BODY>
<p class="footer">
this is <a href="#">a footer</athat you would never use.
</p>
</BODY>
</HTML>


sr ******* @ gmail .com 写道:
sr*******@gmail.com wrote:

font-family:Verdana,Helvetica,Arial,sans-serif;

font-size: 13像素;
font-family: Verdana, Helvetica, Arial, sans-serif;
font-size: 13px;

http://k75s.home.att。 net / fontsize.html


-

-bts

-警告:我为草坪鹿刹车

http://k75s.home.att.net/fontsize.html

--
-bts
-Warning: I brake for lawn deer


2006-07-14,Beauregard T. Shagnasty写道:
On 2006-07-14, Beauregard T. Shagnasty wrote:
sr ******* @ gmail.com 写道:
sr*******@gmail.com wrote:

> font-family:Verdana,Helvetica,Arial,sans-serif;
font-size:13px;
> font-family: Verdana, Helvetica, Arial, sans-serif;
font-size: 13px;


http:// k75s。 home.att.net/fontsize.html



或者,为了更准确的比较:

< http://cfaj.freeshell .org / testing / verdana-helvetica.shtml>


-

Chris FA Johnson,作者< http://cfaj.freeshell.org>

Shell Scripting Recipes:问题解决方案(2005,Apress)

=====我在这篇文章中的代码(如果有的话)假设POSIX语言环境

=====并根据GNU通用公共许可证发布

Or, for a more accurate comparison:
<http://cfaj.freeshell.org/testing/verdana-helvetica.shtml>

--
Chris F.A. Johnson, author <http://cfaj.freeshell.org>
Shell Scripting Recipes: A Problem-Solution Approach (2005, Apress)
===== My code in this post, if any, assumes the POSIX locale
===== and is released under the GNU General Public Licence


这篇关于字体大小继承IE6问题的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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