一个页面中,上面部分客户要求是渐变的背景,下面部分要求是图案背景
但是只有一个body标签,该怎么实现这个效果?
(注意:是body背景哦,也就是说屏幕大了之后空白部分的背景,不是div内的背景)
求指教!!!
------解决方案--------------------
可以换换思想,用一些比较容易实现的。
- HTML code
<style>
.gradients
{
text-align: center;
width: 400px;
line-height: 160px;
background-image: -moz-linear-gradient(top, #BDD738, #000);
background-image: -webkit-gradient(linear, left top, left bottom, from(#BDD738), to(#000));
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr=#BDD738,endColorstr=#000);
-ms-filter: "progid:DXImageTransform.Microsoft.gradient(startColorstr=#BDD738,endColorstr=#000)";
}
</style>
</head>
<body>
<form id="form1" runat="server" >
<div class="gradients" style="margin: auto; border: 1px solid #000;">
xxxxxxxxxxxxxxxx
</div>
</form>
</body>