in a html table i construct in each row an edit button like the following:
retour.append("<input type=\"hidden\" id=\"id_"+nomTab+"_"+compteur+"\" value=\""+object.getIdDailyTimeSheet()+"\" name=\"hd_"+compteur+"\" />");
this is the hidden type then i do the following:
retour.append("<button id=edit name=edit type=button onClick= editarow()>");
retour.append("<img src=edit.gif />");
retour.append("</button>");
retour.append("</td>");
here i am using the hidden type to differentiate between my rows with it.
Now I am trying to get the parameter called here: value=\””+object.getIdDailyTimeSheet() in my servlet to do an update query based on the IdDailyTimeSheet.
I didn’t until know find the way to get this value every time i click the edit button (i do its submit with the javascript).
thanks for help.
You can send the
idparameter with theGETHTTP method in each row:where:
URLis the URL to which you submitthis form to and
idis what you build with “id_” + nomTab + “_” + compteur