I am attempting to create a form that allows for a few different things to happen. The user will be able to add/remove rows, and click to edit the text and each row. Each row has two columns, a ‘title’ and an ‘entry’ – for example a title might be ‘name’ and an entry might be ‘John Doe’. I plan on using Javascript to handle adding and removing the table rows, and click to edit of both the title and the entry. I have included a mockup of what I have in mind below:

The problem I have run into is how to pass the data from the table through the form using POST. Is this even possible? I would need to pass the following info: the total number of rows, the order/position of the row, the ‘title’ text, and the ‘entry’. Any help with this would be greatly appreciated, I am pretty stumped!
Without knowing the exact structure, a possible method of solving this issue is to have a hidden field on each row that stores the id in an input with the name
title[].When retrieving the POST an array should be passed with the values in the correct order.