jQuery相应事件的参数及回调函数

   
 <script>
        $(function(){
            var eventType, textValue, textStatus;
            $('input[type="submit"]').on(
                'mouseover',
                {status:'important'},
                function(e){
                    eventType = e.type;
                    textValue = $('textarea').val();
                    textStatus = e.data.status;
                    alert(eventType+' '+textValue+' '+textStatus);
                }
            )
        })
    </script>
相关文章
相关标签/搜索