I have a dynamically generated form. I use an array to retrieve all the data. Something like this:
<input type="text" class="dynamically-generated" name="ItemArray[]">
<!-- This code as many times as desired -->
Now I want these inputs to be validated in the request:
public function rules()
{
return [
'Item' => 'integer'
];
}
I need however to do this in each of the elements in the array. This would be pretty easy in plain PHP. How is this possible in Laravel? I want to do this properly