当前位置:  开发笔记 > 编程语言 > 正文

CSS Div,需要它在Firefox和Safari中工作

如何解决《CSSDiv,需要它在Firefox和Safari中工作》经验,为你挑选了1个好方法。



1> Tyson..:

如果您可以将我们指向页面的实时版本,这将有很大帮助.有很多事情会影响浏览器中的页面显示(标准或怪癖渲染模式,doctypes,有效/无效的HTML和CSS等)

目前,您的问题中没有足够的信息让人们准确地找出问题的根源.

另外,请记住,Firefox和Safari最有可能"正确"呈现您的页面.但是因为你已经为IE编写了代码,所以你可能已经编写了CSS,使其在IE中看起来很好,但代价是符合标准的浏览器.

编辑:使用上面正确格式化的代码,我稍微重构了你的代码.在编写HTML时,它被认为是最佳实践,使用classid描述内容的属性,而不是它的外观.所以"标题"而不是"顶部"和"内容"而不是左边.

这个更简单的代码也应该使调试更容易.

HTML:





Untitled Document





Water. Pure and Simple

United Distributors, Inc. is the region’s top provider of Water Treatment Solutions and Supplies. For over 30 years, you have trusted us to provide the latest in water treatment technology and related products. We have met your needs through a broad range of products that provide you the purest of water for use in your Home, Office, Restaurant /Food Service and Medical Facilities and Commercial/Industrial facilities.

Call us today. With over 80 years combined experience, our Certified Staff can be called upon to share their experience and expertise with you. At United Distributors we not only provide you with water solutions, our Certified Staff accurately installs your treatment equipment and ensures your system is maintained for the highest level of quality water.

Let us help you enjoy the healthy benefits of safe, pure water.

Our Promise to You...

We are committed to market innovative and creative water treatment and water related products to meet and fulfill your needs. We’ll provide you with experienced and educated service professionals who proudly represent our company, products, business associates and community.

Our Guarantee

United Distributors, Inc. guarantees your customer satisfaction. Our water treatment solutions are manufactured by some of the most trusted companies in the water treatment industry.

CSS:

@charset "utf-8";

body {
    background-color: #EEEEE4;
    font-family: Verdana, Arial, Helvetica, sans-serif;
    font-size: 12px;
    line-height: 17px;
    color: #000000;
}
h2 {
    font-size: 15px;
    line-height: 10px;
}
h2.blue {
    color: #000066;
}
a:link {
    font-size: 12px;
    font-weight: bold;
    color: #003366;
    text-decoration: underline;
}
a:hover {
    font-size: 12px;
    font-weight: bold;
    color: #009900;
    text-decoration: underline;
}


#wrap {
    background: url(blue_white_bkgd.gif) repeat-y 50% 0%;
    margin: 0px auto;
    padding: 0px;
    width: 800px;
}
#header {
    margin: 0px auto;
    padding: 0px;
    width: 800px;
}
#content {
    margin: 0px;
    padding: 0px;
    float: left;
    width: 370px;
    background: url(none);
}
#left_top {
    background: #D9DAD5;
    margin: 0px;
    padding: 15px;
    width: 340px;
}
#left_bot {
    margin: 0px;
    padding: 15px;
    width: 340px;
}


#right {
    margin: 0px;
    padding: 0px;
    float: right;
    width: 430px;
}
#footer {
    clear: both;
    background: #000000;
    width: 770px;
    margin: 0px;
    padding: 15px;
    color: white;
}

推荐阅读
linjiabin43
这个屌丝很懒,什么也没留下!
DevBox开发工具箱 | 专业的在线开发工具网站    京公网安备 11010802040832号  |  京ICP备19059560号-6
Copyright © 1998 - 2020 DevBox.CN. All Rights Reserved devBox.cn 开发工具箱 版权所有