topical media & game development

talk show tell print

#javascript-code-17-cue.js / js



  // Find all input fields that have been marked as required        
  $("input.required")
      // then locate the previous label
      .prev("label")
  
      // Change the cursor, over the label, to being more helpful
      .css("cursor", "help")
  
      // Make it so that when the user hovers their mouse over, a description
      // of the * is explained
      .title( errMsg.required )
  
      // Finally, add a * at the end of the label, to signify the field as being required
      .append(" <span class='required'>*</span>");
  
  


(C) Æliens 20/2/2008

You may not copy or print any of this material without explicit permission of the author or the publisher. In case of other copyright issues, contact the author.