CSS-圆角案例

21 篇文章 1 订阅

代码: 

<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <style>
        *{
            margin: 0px;
            padding: 0px;
        }
        input{
            outline: none;
        }
        /* 不清除样式的话,点击input框就会出现高亮的黑线 */
        div{
            width: 933px;
            height: 120px;
            background-color: #f0eeef;
            border: 1px solid #dedede;
            margin: 10px auto;
            border-radius: 15px;
            box-shadow:3px 10px 7px #d6d6d6,-3px 10px 7px #d6d6d6;
            /* 设置阴影 需要注意的一点是阴影可以写多个
            因为左边也需要阴影,所以复制一份然后在水平方向上加个负号,将其变成负值 */
        }
        [type=text]{
            width: 685px;
            height: 85px;
            margin-top: 17px;
            margin-bottom: 16px;
            margin-left: 16px;
            margin-right:15px;
            border-radius: 6px;
            border: 3px solid #cccccc;
            font-size: 28px;
            text-indent: 12px;
            /* 让字体别贴着框,缩进12px */
        }
        [type=submit]{
            width:200px ;
            height:85px ;
            background: url(../img/117-圆角案例-submit\ 拷贝.png);
            border-radius: 5px;
            border: 1px solid #5ca3b4;
            font-size: 22px;
            color: #f9fafa;
            margin-bottom: 15px;
        }
    </style>
</head>
<body>
   <form>
        <div>
            <input type="text" placeholder="Search for CSS3,HTML5,JQuery...">
            <!-- 通过placeholder可设置预置文本 -->
            <input type="submit" value="GO">
            <!-- 搜索-buttom或submit-->
        </div>
   </form>
</body>
</html>

 

效果:

 

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值