//array of the object let Arrayobject=[] obj1={ section:'Dynamic Table', marks:20 } Arrayobject.push(obj1) obj2={ section:'Intellij Usage', marks:10 } Arrayobject.push(obj2) obj3={ section:'Calender Control', marks:30 } Arrayobject.push(obj3) obj4={ section:'Active Form', marks:20 } Arrayobject.push(obj4) obj5={ section:'Object Database', marks:20 } Arrayobject.push(obj5) //obtain data with jquery $(document).ready(function(){ for(let **0;i ${tg} ${Arrayobject[i].marks} ` } //for active form else if(Arrayobject[i].section=="Active Form") { formdata=`
${tg} ${Arrayobject[i].marks}
` } //for marks 20 else if(Arrayobject[i].marks==20) { formdata=`
${tg} ${Arrayobject[i].marks}
` } //for marks 100 else if(Arrayobject[i].marks==100) { formdata=`
${tg}
` } //for marks 30 else if(Arrayobject[i].marks==30) { formdata=`
${tg} ${Arrayobject[i].marks} .
` } $('form').append(formdata) } //submit and clear t=`
` $('form').append(t) }); $("#form input").each(function () { data[theFieldName] = theFieldValue; });