var html="你的html代码"
document.write(html)
HTML文件
<script type="text/javascript" src="JS文件"></script>
是这样吗body,div,dl,dd,dt,ul,li,h1,h2,h3,h4,h5,h6,input,form,a,p,textarea{
margin:0px
padding:0px
}
ol,ul,li{
list-style:none
}
a{
text-decoration: none
display: block
color:#fff
}
img{
border:none
display: block
}
.clearfloat{
zoom:1
}
.clearfloat:after{
display: block
clear:both
content:""
visibility:hidden
height:0
}
还是这个
.public-container{
/*position:relative如果子元素没有绝对定位的,其实是不需要写这个的*/
position:relative
width:1100px
margin:0 auto
}
.public-header .header-logo{
float:left
background-image: url("../images/logo.png")
margin-top:40px
}
.public-header .header-logo a{
width:182px
height:54px
}
.public-header .header-nav{
float:right
margin-top:44px
}
.public-header .header-nav .item{
float:left
margin-left:50px
/*color: #3b3b3b这里写是没用的*/
}
.public-header .header-nav a {
color: #3b3b3b
}
.public-header .header-nav a:hover{
text-decoration: underline
}
.public-footer{
height:218px
background-color: #3b3b3b
padding-top:100px
}
.public-footer .footer-col{
width:230px
float:left
margin-right:60px
font-size:16px
color:#fff
lineheight:1.8
}
.public-footer .footer-col:last-child{
margin-right:0px
}
.public-footer .footer-logo{
width:182px
height:54px
margin-top:-10px
margin-bottom:10px
background-image: url("../images/logo-white.png")
}
欢迎分享,转载请注明来源:内存溢出
评论列表(0条)