I if have inputs like this one, but those 2 inputs are repeating themselves multiple times. So it could be:
<input name="Gpodaciogolubu[]" type="text">
<input name="Gpodaciogolubu_godina[]" type="number">
<input name="Gpodaciogolubu[]" type="text">
<input name="Gpodaciogolubu_godina[]" type="number">
<input name="Gpodaciogolubu[]" type="text">
<input name="Gpodaciogolubu_godina[]" type="number">
...
Is it possible to use while or foreach loop to get both values at the same time and insert it both in database like:
"INSERT INTO database (field1, filed2) VALUES ('$_POST["Gpodaciogolubu"]','$_POST["Gpodaciogolubu_godina"]')"
I'm coding in PHP/MySQL