纯Div+Css制作的漂亮点击按钮和关闭按钮

时间:2022-06-18 13:06:33

纯Div+Css制作的漂亮点击按钮和关闭按钮,单击点击按钮也有效果.这些都不是图片.

aaarticlea/png;base64,iVBORw0KGgoAAAANSUhEUgAAAW4AAACVCAIAAAD34oe2AAAUaklEQVR4nO2d23PbZnqHv2vTohQdI1tWbK277jFNm80m+Q8skqIoS7JOPmS3TbIbHxpJ6f0m7Uzuuk28TaeNeues05u2s5PdnVE6U63TNoftttOOPXZuYntkmTgDJAACPEjoxUeCOJGSKVgSyd8zv4ElkNGHAPieeV8AQxILAAB2DdnvDQAAtAJQCQAgBKASAEAIQCUAgBCASgAAIQCVAABCACoBAIQAVAIACAGoBAAQAlAJACAEoBIAQAhAJQCAEIBKAAAhAJUAAEIAKgEAhABUAgAIAagEABACNVWyVaHOq09sqwAATUaASra2tjY3Nzc3N0sMw25uepRBJbK5ubm5ybKs91UAQHviVQnVRLFYzG/84ioh5OovmFJpsyIU+9VCofA/f0sIIX/3vyXYBADgUgk1RaFQMNY/uUIqXP15ulikNqEeMQzj1z+xX4ZNAAA+lZRKJWP9k0vEzdVP0sUiLUYMw/jymudl8vf/h04HgLbGpRJakvzX33hNQQghVz5ZNwxd1/0eIYSQP/slB5UA0MYEqETXdeWL9wJ8celf/jlo9Qf/bRSLRVQlALQzQQ2OYWSzWfE//jqo/PBy7SvVNM1SCZdLAGhrvHdwaGGSy+Uymcy2Nrn2ZdYwjGKxuLm5uS9bDwA4IATfDKY2URSF/+zHtTzy/heZXC5XrNzc2ZetBwAcEIIfUSuVSqZpqqoqiuLNvwoSyRv/dF/T8vk8WhsAgFVHJfl8XlXVei3OlZ9t5PMoSQAAVp2nXXO53Bfvb3fR9eonaTQ4AIDAy670edbg50dq22Rfth4AcEAIuBlsmuZXQR758Wc891nQhZOrP2dwxQSA9sarkmKx+JsPAnTx3ueyoiiyLAv/HnT5BE+7AtDeBKgkl8t5HnZ9/4uMruu5XE7X9YDnTa6gxwGg3QlucFRV/bxik2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qDBw/u379/7969e/fufQMA2DV0Nt2/f//Bgwfr6+sbGxsMw3AcR5+X1zTNLkmaqLuxLIuUSqVCoWCaJm1zaG3C8zzLsul0+tGjRxsbGw8fPnz48OE6AGDX0Nm0sbHx6NGjdDrNsizP87Qeoa2NaZpNV5JYVCXFYtG2Ca1NZFmWJEkQBJ7nOY5jWZZlWQYAsGvobOI4jud5QRAkSZJl2a5HqEeariSxLItsbm56bKLruqqq2WxWURTqFEmSRABASNA5JcuyoijZbFZVVV3XAz3STCrZ2tpy2iSfzxuGQYWiaZqqqlQrNhkAQEM45xGdWZqmUYkYhpHP55vXIxZViW0Tp1BM0zQMg2rFRgcA7ALnbKLzyzRNp0ScHmlKlVCbOIVCnUK1AgAIHTq/6FyzJdKkHrEsi9B/PEKxnWJrBQAQLvYUsyddk0qEQuyfttxsAgD2BOe820cX7BLiX7UFANhz9n7yh0uASgAA4HGBSgAAIQCVAABCACoBAIQAVAIACAGoBAAQAlAJACAEoBIAQAhAJQCAEIBKAAAhAJUAAEIAKgEAhABUAgAIAagEABACUAkAIASgEgBACEAlAIAQgEoAACEAlQAAQgAqAQCEAFQCAAgBqAQAEAL/D2kK7kZj0pQmAAAAAElFTkSuQmCC" alt="" />

值得注意三点:

1.其中,主要使用了rotate.它能让文字旋转角度

2.还有radius,做圆角专用,很好用的属性.给想我这样的人省去了作图的时间.

3.W3C标准中对CSS3的transition这是样描述的:"CSS的transition允许CSS的属性值在一定的时间区间内平滑地过渡。这种效果可以在鼠标单击、获得焦点、被点击或对元素任何改变中触发,并圆滑地以动画效果改变CSS的属性值。"

 <!doctype html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title></title>
<style type="text/css">
span{
display: inline-block;
font-size: 40px;
font-weight: 700;
line-height: 40px;
text-shadow: 0 1px 2px rgba(0,0,0,.1);
-o-transform: rotate(45deg);
-moz-transform: rotate(45deg);
-webkit-transform: rotate(45deg);
-ms-transform: rotate(45deg);
}
button{
font-size: 24px;
letter-spacing: 15px;
cursor: pointer;
width: 300px;
height: 44px;
margin-top: 25px;
padding: 0;
background: #ef4300;
-moz-border-radius: 6px;
-webkit-border-radius: 6px;
border-radius: 6px;
border: 1px solid #ff730e;
-moz-box-shadow: 0 15px 30px 0 rgba(255,255,255,.25) inset,
0 2px 7px 0 rgba(0,0,0,.2);
-webkit-box-shadow: 0 15px 30px 0 rgba(255,255,255,.25) inset,
0 2px 7px 0 rgba(0,0,0,.2);
box-shadow: 0 15px 30px 0 rgba(255,255,255,.25) inset,
0 2px 7px 0 rgba(0,0,0,.2);
font-family: 'PT Sans', Helvetica, Arial, sans-serif;
font-weight: 700;
color: #fff;
text-shadow: 0 1px 2px rgba(0,0,0,.1);
-o-transition: all .2s;
-moz-transition: all .2s;
-webkit-transition: all .2s;
-ms-transition: all .2s;
}
button:hover {
-moz-box-shadow: 0 15px 30px 0 rgba(255,255,255,.15) inset,0 2px 7px 0 rgba(0,0,0,.2);
-webkit-box-shadow: 0 15px 30px 0 rgba(255,255,255,.15) inset,0 2px 7px 0 rgba(0,0,0,.2);
box-shadow: 0 15px 30px 0 rgba(255,255,255,.15) inset,0 2px 7px 0 rgba(0,0,0,.2);
}
</style>
<script type="text/javascript" src="js/jquery-2.1.1.js"></script>
<script type="text/javascript">
$("button").click(function(){
alert("nihao!"); });
</script>
</head>
<body>
<span>+</span><br/>
<button>点击</button>
</body>
</html>

纯Div+Css制作的漂亮点击按钮和关闭按钮的更多相关文章

  1. 纯div&plus;css制作的弹出菜单

    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/ ...

  2. DIV&plus;CSS制作二级横向弹出菜单,略简单

    没有使用JavaScript控制二级菜单的显示,结果如上图所示. 代码如下: <!DOCTYPE html> <html> <head> <meta char ...

  3. 利用DIV&plus;CSS制作网页过程中常用的基本概念及标签使

    CSS主要用于对HTML文件功能的补充及扩展,其作用就是对HTML文件中各种排版进行设置,达到对网页中字体.颜色.背景.图片等的控制,使网页能够完全依照设计者的想法来显示. CSS可以控制网页的显示, ...

  4. 利用DIV&plus;CSS制作网页过程中常用的基本概念及标签使用细节

    CSS主要用于对HTML文件功能的补充及扩展,其作用就是对HTML文件中各种排版进行设置,达到对网页中字体.颜色.背景.图片等的控制,使网页能够完全依照设计者的想法来显示. CSS可以控制网页的显示, ...

  5. Div&plus;Css制作圆

    Div+Css制作四分之一圆主要是使用Css3.0中的border-radius这个圆角隐藏属性.利用这一属性,我们可以画圆,画半圆,四分之三圆,四分之一圆等.以后我会更新…… 如何使用border- ...

  6. 项目实战之玩转div&plus;css制作自己定义形状

    项目需求 watermark/2/text/aHR0cDovL2Jsb2cuY3Nkbi5uZXQv/font/5a6L5L2T/fontsize/400/fill/I0JBQkFCMA==/diss ...

  7. 使用div&plus;css制作简单导航 以及要注意问题

    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/ ...

  8. DIV&plus;CSS制作斜线效果记录

    DIV+CSS 斜线效果很简单,只需设置一下CSS Border 的边框就能有斜线效果.代码分享给大家,你可以自己变通. 提示要注意两点:1.DIV宽高的定义.2.DIV在 IE6 中默认是有高度的. ...

  9. div&plus;css 制作表格

    <div class="table"> <h2 class="table-caption">花名册:</h2> <di ...

随机推荐

  1. SSH整合开发的web&period;xml配置

    <?xml version="1.0" encoding="UTF-8"?><web-app version="2.5" ...

  2. Atitti&period;java exp ast java表达式语法ast构造器

    Atitti.java exp ast java表达式语法ast构造器 /atiplat_cms/src/com/attilax/lang/AstParser.java 原理 分割tokens_sli ...

  3. &period;NET 4&period;0 任务和并行编程系列

    8天玩转并行开发 8天玩转并行开发——第一天 Parallel的使用 8天玩转并行开发——第二天 Task的使用 8天玩转并行开发——第三天 plinq的使用 8天玩转并行开发——第四天 同步机制(上 ...

  4. U1 - A 留在电脑里的字体

    U1系列新篇章,实战派!说说常用的字体! U1系列新篇章,实战派!更多干货更多关于软件的使用等即将放出,大家敬请期待!!

  5. 基于Qt QGraphicsView的多点触摸绘图

    本应用于基于QGraphicsView框架,实现多点触摸. 工程仅仅演示了多点触摸绘图,源自我前段时间一款基于Qt的绘图软件. 工程结构: kmp.h 定义了枚举 slide.h/cpp 定义了派生于 ...

  6. poj2774之最长公共子串

    Long Long Message Time Limit: 4000MS   Memory Limit: 131072K Total Submissions: 18794   Accepted: 77 ...

  7. TCP&sol;IP协议精华笔记

    1.简介 TCP/IP协议并非单指TCP协议.IP协议,它是一组包括TCP协议和IP协议,UDP(User Datagram Protocol)协议.ICMP(Internet Control Mes ...

  8. Git篇(基础)

    安装过程省略... 至于安装目录的有关功能,略过... 一.关于初次使用的关键配置命令: 1.配置基本信息,该信息将保存在该用户目录下的.gitconfig文件内 配置用户信息$ git config ...

  9. Android项目实战(四十三):夜神模拟器

    一.下载模拟器到电脑 夜神模拟器 二.环境配置 计算机--系统--高级系统设置--环境变量 PATH 里面加入夜神模拟器的安装目录下的bin文件 三.启动模拟器 四.运行cmd命令,cd到夜神安装目录 ...

  10. mysql 导入sql 2006 - mysql server has gone away 导入

    解决办法:找到你的mysql目录下的my.ini配置文件,加入以下代码 max_allowed_packet=500M wait_timeout=288000 interactive_timeout ...