Search Results

Search found 1 results on 1 pages for 'gotguts'.

Page 1/1 | 1 

  • Combining a mousedown event with a keydown event

    - by gotguts
    I am trying to combine a keydown event with a mousedown event. Basically, I have a chat dialog, and if the user writes in one of 2 divs (keydown event) or makes a selection from either (or both) of 2 dropdowns (mousedown), I need these to have the same exact function. Thanks in advance. Code (to be combined): $('#usermsg').add('#otherComments').keydown(function() { // When key pressed and $('#strategies').add('#whySwitch').mousedown(function() { // When mouse is clicked //function body });

    Read the article

1