sknagesh Posted January 12, 2012 Share Posted January 12, 2012 Hi I am loading contents from my Mysql table for editing using PHP and Ajax. The data is loaded on into to the page dynamically using Ajax. Each cell in a column is having unique name and id like tollower[1], tollower[2], tollower[3] etc in one column. Next column is having tolupper[1],tolupper[2],tolupper[3] etc. I am able to update the edited values back in the Mysql table by using serializeArry() and posting the values. The problem i am having is in client side validation of the edit. I want to do some live validation of values entered for tollower[1] in first column to tolupper[1] in second column etc. How do I do this using Jquery validationEngine. Below is the HTML table as created by PHP. <input name="baloonno[0]" id="baloonno[0]" value="34.1" class="validate[required,custom[float]] text-input" type="text"> </td><td> <input name="basicdimn[0]" id="basicdimn[0]" value="22" class="validate[required,custom[float]] text-input" type="text"> </td><td> <input name="tollower[0]" id="tollower[0]" value="0.0000000000" type="text"> </td><td> <input name="tolupper[0]" id="tolupper[0]" value="1.0000000000" type="text"> </td><td> <select name="Instrument_ID[0]" id="Instrument_ID[0]"> <option value="1" selected="Selected">"DEW-1-Digital Vernier</option><option value="2">"DEW-2-0-25mm Micrometer</option><option value="3">"DEW-50-Pin Gage Set</option> </select></td><td> <input name="textfield[0]" id="textfield[0]" value="1" checked="checked" type="radio"> Yes <input name="textfield[0]" id="textfield[0]" value="0" type="radio"> No</td><td> <input name="proddimn[0]" id="proddimn[0]" value="1" checked="checked" type="radio"> Yes <input name="proddimn[0]" id="proddimn[0]" value="0" type="radio"> No</td><td> <input name="deldimn[0]" id="deldimn[0]" value="1" type="checkbox"> </td> </tr> <input name="InProcess_ID[0]" id="InProces_ID[0]" value="195" type="hidden"> <tr> <td> <input name="baloonno[1]" id="baloonno[1]" value="222" class="validate[required,custom[float]] text-input" type="text"> </td><td> <input name="basicdimn[1]" id="basicdimn[1]" value="94.5" class="validate[required,custom[float]] text-input" type="text"> </td><td> <input name="tollower[1]" id="tollower[1]" value="-0.1500000060" type="text"> </td><td> <input name="tolupper[1]" id="tolupper[1]" value="0.1700000018" type="text"> </td><td> <select name="Instrument_ID[1]" id="Instrument_ID[1]"> <option value="1" selected="Selected">"DEW-1-Digital Vernier</option><option value="2">"DEW-2-0-25mm Micrometer</option><option value="3">"DEW-50-Pin Gage Set</option> </select></td><td> <input name="textfield[1]" id="textfield[1]" value="1" checked="checked" type="radio"> Yes <input name="textfield[1]" id="textfield[1]" value="0" type="radio"> No</td><td> <input name="proddimn[1]" id="proddimn[1]" value="1" checked="checked" type="radio"> Yes <input name="proddimn[1]" id="proddimn[1]" value="0" type="radio"> No</td><td> <input name="deldimn[1]" id="deldimn[1]" value="1" type="checkbox"> </td> </tr> <input name="InProcess_ID[1]" id="InProces_ID[1]" value="194" type="hidden"> <tr> <td> <input name="baloonno[2]" id="baloonno[2]" value="22" class="validate[required,custom[float]] text-input" type="text"> </td><td> <input name="basicdimn[2]" id="basicdimn[2]" value="10.5" class="validate[required,custom[float]] text-input" type="text"> </td><td> <input name="tollower[2]" id="tollower[2]" value="0.0000000000" type="text"> </td><td> <input name="tolupper[2]" id="tolupper[2]" value="0.1500000060" type="text"> </td><td> <select name="Instrument_ID[2]" id="Instrument_ID[2]"> <option value="1" selected="Selected">"DEW-1-Digital Vernier</option><option value="2">"DEW-2-0-25mm Micrometer</option><option value="3">"DEW-50-Pin Gage Set</option> </select></td><td> <input name="textfield[2]" id="textfield[2]" value="1" checked="checked" type="radio"> Yes <input name="textfield[2]" id="textfield[2]" value="0" type="radio"> No</td><td> <input name="proddimn[2]" id="proddimn[2]" value="1" checked="checked" type="radio"> Yes <input name="proddimn[2]" id="proddimn[2]" value="0" type="radio"> No</td><td> <input name="deldimn[2]" id="deldimn[2]" value="1" type="checkbox"> </td> </tr> <input name="InProcess_ID[2]" id="InProces_ID[2]" value="193" type="hidden"> Link to comment https://forums.phpfreaks.com/topic/254877-text-box-array-in-jquery/ Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.