bind

?? [ba?nd]

vt. ???, ?? ??

???? ???() ??? ???

??: bind() ???? ??? ??? ?? ??? ??? ???? ???? ???? ??? ? ??? ??? ?????.

??: ??? ??? ??? ?? ??? ??? ???? ???? ??? ? ??? ??? ?????.

??: ??$(selector).bind(event,data,function)

????:

???? Description
event ?? . ??? ??? ?? ??? ???? ?????. ?? ???? ???? ?????. ??? ????? ???.
??? ????. ??? ??? ?? ???? ?????.
?? ?????. ???? ??? ? ??? ??? ?????.

?? ??: $(selector).bind({event:function, event:function, ...})

????: {event:function, event:function, ...} ???. ??? ??? ?? ??? ???? ???? ??? ? ??? ??? ??? ??? ?? ?????.

???? ???() ??? ?

<html>
<head>
<script type="text/javascript" src="http://apps.bdimg.com/libs/jquery/2.1.1/jquery.min.js"></script>
<script type="text/javascript">
$(document).ready(function(){
  $("button").bind("click",function(){
    $("p").slideToggle();
  });
});
</script>
</head>
<body>
<p>This is a paragraph.</p>
<button>請(qǐng)點(diǎn)擊這里</button>
</body>
</html>
???? ?? ?

??? ????? ??? "???? ??" ??? ?????