jQuery add required to input fields

$("input").prop('required',true);

DEMO FIDDLE

Leave a Comment