验证码之滑动拼图

1、效果图

2、下载js、css文件

3、html

 1 <!DOCTYPE html>
 2 <html lang="en">
 3 <head>
 4   <meta charset="UTF-8">
 5   <title>滑动拼图验证码</title>
 6   <link rel="stylesheet" href="jigsaw.css">
 7   <style>
 8     .container {
 9       width: 310px;
10       margin: 100px auto;
11     }
12     input {
13       display: block;
14       width: 290px;
15       line-height: 40px;
16       margin: 10px 0;
17       padding: 0 10px;
18       outline: none;
19       border:1px solid #c8cccf;
20       border-radius: 4px;
21       color:#6a6f77;
22     }
23     #msg {
24       width: 100%;
25       line-height: 40px;
26       font-size: 14px;
27       text-align: center;
28     }
29     a:link,a:visited,a:hover,a:active {
30       margin-left: 100px;
31       color: #0366D6;
32     }
33 
34   </style>
35 </head>
36 <body>
37 <div class="container">
38   <input value="admin" readonly/>
39   <input type="password" value="1234567890" readonly/>
40   <div id="captcha" style="position: relative"></div>
41   <div id="msg"></div>
42 </div>
43 <script src="jigsaw.js"></script>
44 <script>
45   jigsaw.init(document.getElementById('captcha'), function () {
46     document.getElementById('msg').innerHTML = '登录成功!'
47   })
48 </script>
49 </body>
50 </html>

 

 

over!over!over!

转载于:https://www.cnblogs.com/yulongcode/p/10580312.html

  • 0
    点赞
  • 2
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值