[CSS] 常用樣式 (按鈕、表單等)



.simpleBtn {
    display: inline-block;
    margin: 0 3px;
    padding: 5px 15px;
    background-color: #262020;/*背景*/
    -webkit-border-radius: 5px;
    border-radius: 5px;
    color: #ffffff;
    text-decoration: none;
}
.simpleBtn.current,
.simpleBtn:hover {
    color: #fff;
    text-decoration: none;
    background-color: #2F0080;
}

<a class="simpleBtn" href="./">移進變色連結按鈕</a>



移進變色連結按鈕


.btn-cus1{
  display:block;background-color:#ff8400;border:1px solid #f16c00;border-bottom-width:4px;border-radius:3px;color:#fff;font-weight:bold;line-height:37px;text-align:center;text-decoration:none
}
<a href="https://" class="btn-cus1">按鈕樣式 »</a>



按鈕樣式 »


.btn-cus2{
  background:none repeat scroll 0 0 #ffd800;border:2px solid #e0be00;border-top:2px solid #ffe65b;border-left:2px solid #ffe65b;color:#2b0e01;display:inline-block;font-size:13px;padding:8px 10px;text-align:center;text-decoration:underline;width:80px;margin:5px 5px 3px;text-decoration:none
}

<a href="https://" class="btn-cus2">按鈕樣式</a>



按鈕樣式



.btn-cus3{
  background:none repeat scroll 0 0 #fff;
  border:2px solid #d1d1d1;
  border-top:2px solid #eaeaea;
  border-left:2px solid #eaeaea;
  color:#2b0e01;
  display:inline-block;
  font-size:13px;
  padding:8px 10px;
  text-align:center;
  text-decoration:underline;
  width:80px;
  margin:5px 5px 3px;
  text-decoration:none
}

<a href="https://" class="btn-cus3">按鈕樣式</a>


按鈕樣式



.btn-cus4{
font-size: 27px;
display: inline-block;
position: relative;
text-align: center;
color: rgb(255, 255, 255);
font-family: "微軟正黑體","Microsoft JhengHei";
font-weight: bold;
letter-spacing: 6px;
clear: both;
box-shadow: rgb(154, 8, 8) 0px 5px 0px;
box-sizing: border-box;
padding: 10px 50px;
margin: 0px auto 10px;
border-radius: 8px;
background: rgb(191, 0, 0);
}


<a class="btn-cus4" href="http://blog.webgolds.com/view/431">按鈕樣式</a>




按鈕樣式



.link.btnStyle {
    margin: 0 5px;
    padding: 5px 25px;
    color: #fff;
    text-align: center;
    outline: none;
}
.btnStyle {
    display: inline-block;
    padding: 5px 15px;
    color: #fff;
    font-size: 14px;
    background-color: #fff;
    border: none;
    cursor: pointer;
    -webkit-border-radius: 3px;
    -moz-border-radius: 3px;
    border-radius: 3px;
    -webkit-box-shadow: 1px 2px 3px rgba(0,0,0,.15);
    -moz-box-shadow: 1px 2px 3px rgba(0,0,0,.15);
    box-shadow: 1px 2px 3px rgba(0,0,0,.15);
}
a {
    color: #777;
    text-decoration: none;
}
.gradientOrange {
    background-image: -webkit-linear-gradient(bottom, #e64c00, #ff803a);
    background-image: -moz-linear-gradient(bottom, #e64c00, #ff803a);
    background-image: -o-linear-gradient(bottom, #e64c00, #ff803a);
    background-image: -ms-linear-gradient(bottom, #e64c00, #ff803a);
    background-image: linear-gradient(to top, #e64c00, #ff803a);
}
.gradientPink {
    background-image: -webkit-linear-gradient(bottom, #d95755, #f07674);
    background-image: -moz-linear-gradient(bottom, #d95755, #f07674);
    background-image: -o-linear-gradient(bottom, #d95755, #f07674);
    background-image: -ms-linear-gradient(bottom, #d95755, #f07674);
    background-image: linear-gradient(to top, #d95755, #f07674);
}
.gradientBlack {
    background-image: -webkit-linear-gradient(bottom, #444, #5a5a5a);
    background-image: -moz-linear-gradient(bottom, #444, #5a5a5a);
    background-image: -o-linear-gradient(bottom, #444, #5a5a5a);
    background-image: -ms-linear-gradient(bottom, #444, #5a5a5a);
    background-image: linear-gradient(to top, #444, #5a5a5a);
}
.gradientWhite {
    background-image: -webkit-linear-gradient(bottom, #A9A9A9, #bbb);
    background-image: -moz-linear-gradient(bottom, #A9A9A9, #bbb);
    background-image: -o-linear-gradient(bottom, #A9A9A9, #bbb);
    background-image: -ms-linear-gradient(bottom, #A9A9A9, #bbb);
    background-image: linear-gradient(to top, #A9A9A9, #bbb);
}
.gradientBlue {
    background-image: -webkit-linear-gradient(bottom, #508FBD, #79C4FF);
    background-image: -moz-linear-gradient(bottom, #508FBD, #79C4FF);
    background-image: -o-linear-gradient(bottom, #508FBD, #79C4FF);
    background-image: -ms-linear-gradient(bottom, #508FBD, #79C4FF);
    background-image: linear-gradient(to top, #508FBD, #79C4FF);
}
.gradientGreen {
    background-image: -webkit-linear-gradient(bottom, #08A393, #5EE4D6);
    background-image: -moz-linear-gradient(bottom, #08A393, #5EE4D6);
    background-image: -o-linear-gradient(bottom, #08A393, #5EE4D6);
    background-image: -ms-linear-gradient(bottom, #08A393, #5EE4D6);
    background-image: linear-gradient(to top, #08A393, #5EE4D6);
}

<a href="./" class="btnStyle link gradientOrange">首頁</a>
<a href="./" class="btnStyle link gradientPink">首頁</a>
<a href="./" class="btnStyle link gradientBlack">首頁</a>
<a href="./" class="btnStyle link gradientWhite">首頁</a>
<a href="./" class="btnStyle link gradientBlue">首頁</a>
<a href="./" class="btnStyle link gradientGreen">首頁</a>

css button style





 

回上一頁

相關文章:

喜歡這篇文章嗎?立即分享

Posted : / Views: 1232
Last updated :2017-11-30