jquery - Check if one of two elements are clicked -


i checking if 1 button clicked this

$j('#button1').click( function () {  

and performing function want perform same function when either button1 or button2 clicked.

what jquery syntax that?

you can this:

$j('#button1, #button2').click( function () {  

Comments

Popular posts from this blog

php - What is the difference between $_SERVER['PATH_INFO'] and $_SERVER['ORIG_PATH_INFO']? -

fortran - Function return type mismatch -

queue - mq_receive: message too long -