首页javascriptinputjQuery Form - 如何处理焦点丢失事件

jQuery Form - 如何处理焦点丢失事件

我们想知道如何处理焦点丢失事件。


<html>
  <head>
    <script type="text/javascript" src='http://code.jquery.com/jquery-1.5.2.js'></script>
    <script type="text/javascript">
        $(document).ready(function(){
            $("input").blur(function () {
                console.log("Hello World!");
            });
        });
    </script>
  </head>
  <body>
    <body>
     <p><input type="text" /> <span>focus event fire</span></p>
    </body>
</html>