xxxxxxxxxx
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>设置颜色停止位置示例 -www.div.cn</title>
<style>
.gradient {
width: 400px;
height: 300px;
/* 不支持渐变的浏览器的后备属性 */
background: red;
/* For Safari 5.1 to 6.0 */
background: -webkit-linear-gradient(red, yellow 30%, lime 60%);
/* For Internet Explorer 10 */
background: -ms-linear-gradient(red, yellow 30%, lime 60%);
/* Standard syntax */
background: linear-gradient(red, yellow 30%, lime 60%);
}
</style>
</head>
<body>
<div class="gradient"></div>
</body>
</html>