Using jquery, how can I change the color of these elements to red if the textboxes contain defaultvalues and the ‘isrequired’ value is “Yes”?
<input type="text" value="Name" isrequired="Yes">
<input type="text" value="Address" isrequired="No">
<input type="text" value="Age" isrequired="Yes">
Change your input html to add an extra data-* attribute which store defult value
Jquery
Update : With using defaultvalue property which is very new to me
Much better ,cleaner.