搜索文档
首页
HTML/CSS
JavaScript
服务端开发
Java教程
移动端
数据库
当前位置:
首页
HTML/CSS
CSS 教程
CSS 基础教程
源代码
清空
点击运行
<!DOCTYPE html> <html> <head> <meta charset="utf-8"> <title>设置径向渐变尺寸示例 - div.cn 基础教程</title> <style> .gradient { width: 400px; height: 300px; /* Fallback for browsers that don't support gradients */ background: red; /* For Safari 5.1 to 6.0 */ background: -webkit-radial-gradient(left bottom, circle farthest-side, red, yellow, lime); /* For Internet Explorer 10 */ background: -ms-radial-gradient(left bottom, circle farthest-side, red, yellow, lime); /* Standard syntax */ background: radial-gradient(circle farthest-side at left bottom, red, yellow, lime); } </style> </head> <body> <div class="gradient"></div> </body> </html>
运行结果