码迷,mamicode.com
首页 > Web开发 > 详细

jquery的toggle动画效果显示隐藏

时间:2018-06-10 12:17:13      阅读:331      评论:0      收藏:0      [点我收藏+]

标签:func   script   back   AC   hit   round   asc   oct   nbsp   

<!DOCTYPE html>
<html>
    <head>
        <meta charset="UTF-8">
        <title></title>
        <style type="text/css">
            div{
                border: 1px solid white;
                width: 500px;
                height: 350px;
                margin: auto;
                text-align: center;
            }
        </style>
        <script type="text/javascript" src="../js/jquery-1.8.3.js">
        </script>
        <script type="text/javascript">
            $(function(){
                $("#btn").click(function(){
                    $("#img1").toggle();
                });
            });
        </script>
        
    </head>
    <body>
        <div>
        <input type="button" name="btn" id="btn" value="显示/隐藏" />
        <img src="../img/飞机05.gif" width="100%" height="100%" id="img1"/>
        </div>
    </body>
</html>

 

jquery的toggle动画效果显示隐藏

标签:func   script   back   AC   hit   round   asc   oct   nbsp   

原文地址:https://www.cnblogs.com/benjamin77/p/9162196.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!