【发布时间】:2012-07-25 13:25:59
【问题描述】:
这是我的网站:LINK
如您所见,我的徽标在 Firefox 中被推到 右侧,但它应该居中。例如,在 Chrome 中效果很好。
我曾尝试寻找仅适用于 Firefox 的样式表,但我真的找不到正确的 CSS 设置来使其正常工作。
以下是包含在 id 中的相关 HTML 代码,名称为 container,目前为止:
<div id="nav">
<ul id="index_cards">
<li id="card-1">
<h3><strong>Home</strong></h3>
</li>
<li id="card-2">
<h3><strong>About/Contact</strong></h3>
</li>
<li id="card-4">
<h3><strong>Portfolio</strong></h3>
</li>
<li id="card-5">
<h3><strong>Services</strong></h3>
</li>
</ul>
</div>
<div id="header">
<div id="logo">
<img src="imgs/logo.png" name="ielogo" width="457" height="223" id="ielogo" />
</div>
</div>
CSS:
#container {
top:-73px;
margin-top:-70px;
min-height:100%;
position:relative;
display:block;
}
#header {
margin-top:-30px;
height:250px;
background-image:url(../imgs/header-top.png);
background-repeat:repeat-x;
padding:10px;
}
#logo {
margin:0 auto;
width:457px;
height:223px;
}
【问题讨论】:
-
那么您的徽标实际上应该在哪里?我在 ff12 中看起来不错
-
我使用的是 FF12,它偏离了中心。 div id
logo的 CSS 看起来不错。我认为您只需要将imghtml 替换为 css 即可。 -
那些在鼠标悬停时放大的图像真的很酷,因为它们是透明的!你是怎么做到的?
-
正如所写,这个问题一旦被回答就毫无用处(因为我认为您将修复错误,因此未来的访问者将看不到已解决的问题)。请编辑问题以包含相关代码。实际可见输出的屏幕截图(如果可能的话,用手绘圆圈突出显示异常:))也会有所帮助。
-
据我所知,问题是ff中的“margin:auto”结果为0px
标签: html css firefox stylesheet