creating a button click effect - JQuery -
i wondering on how go recreating button pressed effect using jquery.
my ideas use event mouse click change image pressed image , after mouse releases, return original image. thoughts or ideas on ways accomplish this?
that should work. code be:
$("#button").mousedown(function(){ $("#img").attr("src", "img2.jpg"); }) $("#button").mouseup(function(){ $("#img").attr("src", "img1.jpg"); }
hope helps!
Comments
Post a Comment