Skip to main content

jQuery - bind events

 <img id="example" src="example.jpg" onclick="say('BOOM!');" alt="ooooh! ahhhh!"/>


  $(function(){
        $('#example').bind('mouseover',  function(event) {
          say('Crackle!');
        }).bind('mouseout', function(event){
            say('bye');
        })
        ;
      });

Comments