Is there a way to group jquery 开发者_JAVA百科selectors together?
$(':text, #password').keypress(function() {
Your answer should work as it is written, below are some addition links regarding combining jQuery selectors:
Multiple Selection - jQuery
StackOverflow - Combining two jQuery Selectors
If I got it right I guess it's
$(':text#password').keypress(function() { alert("hello"); });
精彩评论