HTML 表格和图像问题 - Firefox

标签 html css internet-explorer firefox

我在 Firefox 中查看表格时遇到问题,想知道是否有人可以提供帮助?以下是我的页面在 Firefox 中的显示方式:

http://s15.postimg.org/sx6cn6ktn/Problem_Firefox.jpg

但在 Internet Explorer 中看起来不错:

http://s16.postimg.org/e96xsuwj9/Problem_IE.jpg

我的 HTML 代码如下:

<!DOCTYPE_HTML>
<HTML>
<head>
<link rel="stylesheet" type="text/css" href="css.css">  
<title>Website Name | Album Name</title>

<body>
<div id="wrap">
<div id="logo"><img height="182.135433071px"; width="276.699212598px"; src="ctlogonew.jpg"></img> </div>
<div id="header"><img height="182.135433071px"; width="700px"; src="header1.png"</img>   </div>
<ul>
    <li><a href="#home">Home</a></li>
    <li><a href="#news">News</a></li>
    <li><a href="#news">About</a></li>
    <li><a href="#Album Name">Album</a></li>
    <li><a href="#contact">Contact</a></li>
</ul>
   <hr>
    <!---HEADER ENDS HERE--->


    <h1>Welcome to Website</h1>
    <table border="1px" width="100%">
<col width="40">
<col width="60">
<tr>
    <td><img width="400px" src="homepic.jpg"></img></td>
    <td><p>Welcome to xxxxx - an indie-rock band from Norwich.</p><p> The band are known in the industry for creating great music, with all members, including xxxxxxxxxx having a passion for the genre. Formed in 2010, and based in Norwich, Norfolk, the band have increased massively in popularity since then, selling out all performances for their tour in 2012, with more scheduled for 2013, as well as developing a following in London and on the festival scene.</p><p>The band are known musically for their own brand of indie pop music, containing riffs, hooks and soaring choruses, which has seen them become an online sensation worldwide</p><p>Explore our website for our latest news, details of our latest album <strong><i>Album Name</strong></i>, and purchase merchandise from the store.</p><p> Fans can also explore our Facebook and Twitter profiles, and get in touch with us via the Contact Us page. </p></td>
</div>
</body>
</html>

我的 CSS 代码如下:

#wrap {
width:1000px;
height:1000px;
background-color:black;
margin: 0 auto;
}
#logo {
width:276.699212598px;
height:182.135433071px;
background-color:black;
align:left;
float:left;
margin-top:0px;
margin-left:5px;
margin-right:5px;
}
#header {
width:700px;
height:182.135433071px;
background-color:white;
float:right;
}
ul{
line-height:90px;
list-style-type:none;
text-align:center;
margin:0;
padding:0;
padding-top:6px;
padding-bottom:6px;
}
li{
display:inline;
}
a:link,a:visited {
font-family:Reprise Title, Gill Sans MT, Trebuchet MS, Sans-serif;
font-size:2em;
font-weight:bold;
border-radius:5px;
color:#000000;
background-color:#FFFFFF;
text-align:center;
padding:6px;
text-decoration:none;
text-transform:uppercase;
}
a:hover,a:active {
background-color:#7A991A;
}


  {
  border:1px solid #0000ff;
}
div.desc {
text-align:center;
font-weight:normal;
width:120px;
 margin:2px;
}
hr {
height:4px;
background-color:white;
margin-left:20px;
margin-right:20px;
margin-bottom:30px;
}
/*HEADER ENDS HERE*/
h1 {
font-family:Reprise Title, Gill Sans MT, Trebuchet MS, Sans-serif;
font-size:2em;
color:#FFFFFF;
font-weight:bold;
margin-left:20px;
}
p {
font-family: Gill Sans MT, Trebuchet MS, Sans-Serif;
font-size: 1em;
color: #FFFFFF;
}


table {
font-family: Gill Sans MT, Sans-Serif;
color: #FFFFFF;
padding: 3px;
}

非常感谢任何帮助!!

非常感谢。

最佳答案

将单位添加到 colgroup 中的值。您的代码似乎对我有用。

列宽度="40%"

列宽度="60%"

关于HTML 表格和图像问题 - Firefox,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/19863531/

相关文章:

css - 替代位置 : relative; for overflow: auto; bug in IE7

css - IE6和IE7菜单显示:block with padding isn't allowing complete selection

css - 标签内的 SVG 在 IE11 上被截断

jquery - translate3d() & rotateY() 工作,但透视原点不工作......为什么?

html - 复杂的定位元素(乘以行)

internet-explorer - Windows 注册表中的哪个键禁用了 IE 连接参数 "Automatically Detect Settings"?

html - 如何将多个链接放在同一行? (HTML5)

javascript - 无法获取属性 'scopeName'

html - CSS 溢出 : show entirely or hide

javascript - 确定视口(viewport)滚动条的位置