Imagine you have a set of HTML markup and CSS like this:
#CSS
.inputhelp_text { background: #000; color: #fff; }
.nodisplay { display: none; }
<input class="inputhelp" id="firstname" /><span class="inputhelp_text nodisplay" id="help_firstname">Write in your firstname</span>
<input class="inputhelp" id="lastname" /><span class="inputhelp_text nodisplay" id="help_lastname">Write in your lastname</span>
If you're using jQuery, you want to bind a function to all input fields (potentially using jQuery's EACH function) so that when you click an input field, it should switch the class of each span to only "inputhelp_text". While you may have achieved this with separate functions for each field, with numerous fields, there must be a more efficient solution.
Any ideas on how to achieve this?