Skip to content

Instantly share code, notes, and snippets.

@dermatologist
Last active October 4, 2018 14:54
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save dermatologist/26062e3c92639eb4d12c7b494c0ba0e1 to your computer and use it in GitHub Desktop.
Save dermatologist/26062e3c92639eb4d12c7b494c0ba0e1 to your computer and use it in GitHub Desktop.
Add name next to all input and select fields
var $input_fields = $("input, select");
$.each($input_fields, function() {
$(this).after('<span style="color:red;">' + $(this).prop("name") + '</span>');
$(this).show();
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment