title: Can I code same functionality for 2 id element's in one click function?
body: <p>Is there any method to have the same coding for the click function of two different id elements in one click function?</p>
  
  <p>For example,I have two link elements with ids, myFormsTabSubmitted and formStatusSubmitted. Both the link is of same functionality. When I click both these links, the same div element("submitted") is showed,and other divs are hidden.</p>
  
  <p>So instead of writing two click functions, one for myFormsTabSubmitted and another for formStatusSubmitted, can I have one click function for both? Like </p>
  
  <pre><code>$('#myFormsTabSubmitted #formStatusSubmitted').click(function(){
              $('#allMyForms').hide();
              $('#draftedMyForms').hide();
              $('#submittedMyForms').show();
              $('#myFormsTab').find(".selected").removeClass();
              $('#myFormsTabSubmitted').addClass("selected");
          });
  </code></pre>