zoukankan      html  css  js  c++  java
  • jquery 弥补ie6不支持input:hover状态

    <!doctype html>
    <html>
        <head>
        <meta charset="utf-8">
        <title>jquery 弥补ie6不支持input:hover状态</title>
        <style type="text/css">
        input{border:1px solid #eee;}
        input:focus{border:1px solid #ccc;}
        .focus{border:1px solid #ccc;}
        </style>
        <script type="text/javascript" src="jquery-1.11.1.min.js"></script>
        </head>

        <body>
            <form action="#" method="get">
                <label for="name">用户名</label>
                <input id="name" type="text"/>
                <label for="pass">密码</label>
                <input id="pass" type="text"/>
            </form>
            <script type="text/javascript">
            $(function(){
                $(":input").focus(function(){
                    $(this).addClass("focus");
                }).blur(function(){
                    $(this).removeClass("focus");
                });
            });
            </script>
        </body>
    </html>

  • 相关阅读:
    Prometheus服务发现
    持久化查询
    PromQL进阶
    PromQL基础
    Prometheus概述
    监控系统概念
    zabbix5x解决中文字体问题
    allure 插件新手 demo
    关于时间复杂度~
    IIS发布网站Microsoft JET Database Engine 错误 '80004005'的解决办法,基于Access数据库
  • 原文地址:https://www.cnblogs.com/Better-Me/p/4718470.html
Copyright © 2011-2022 走看看