jquery - How to show struts2 tags in javascript as string -
i using struts2 tags , want create <tr></tr>
dynamically add new row in table. problem inside ""
struts2 tags not treated simple string.
function add_table_row() { var t = $('#item-table .row:last').attr('id'); var num = t.substring(4); var num1 = parseint(num) + 1; $("#item-table .row:last").after(" <tr class=\"row\" id=\"item" + num1 + "\">" + "<td><s:textfield name="billproductlist[0].productdetails.barcode" value="%{billproductlist[0].productdetails.barcode}" cssclass="barcode" cssstyle="width:50px"/></td>" + "<td><s:textfield name="billproductlist[0].productdetails.producttypes.producttype" value="%{billproductlist[0].productdetails.producttypes.producttype}" cssclass="producttype" cssstyle="width:250px"/>"); };
how resolve this. how can use struts2 tags simple string in jsp page.
Comments
Post a Comment