This is my template of an angular.js SPA:
<div data-id="{{id}}" ng-repeat="id in array.id">
<input type="text" name="value1" value="{{value1}}">
<input type="text" name="value2" value="{{value2}}">
</div>
The data for this template is loaded via http post request in a controller.
Now I want to send this data back to the php-script to save it in the DB. I would like to do that in a directive, but I don't know how to send the data dynamically - as there are multiple rows and some templates differ a little bit.