javascript - Validation error not showing in right place -
i have appended select box dynamically inside td tag using jquery , assigned class required-entry when submit form validation not showing on right place. appended code.
var addrow = '<tr class="item"><td><select onchange="getprice(this)" id="selectbox-'+counter+'" name="pid[]" customerid="'+customer+'" class="required-entry required-entry select">'; addrow +='<option value="">select product</option>'; (i = 0; < valuearray.length; i++) { addrow +='<option value="'+valuearray[i]+'">'+textarray[i]+'</option>'; } addrow +='</select></td><td style="width:50px"><input type="number" id="qty-box-'+counter+'" class="qty-box" max="1000" min="1" value="1" name="itemqty[]" onchange="qtyupdate(this)" customerid="'+customer+'"></td><td><p style="font-weight:bold" id="price-'+counter+'"> </p><br></td><td><p style="font-weight:bold" id="ext-'+counter+'"> </p><br></td><td class="center"><input id ="delsku-'+counter+'" type="checkbox" value="" name="deletesku[]"/></td></tr>'; jquery("#items-table").append(addrow);
add errors showing want error below of selectbox
Comments
Post a Comment