I am trying to access the content passed via $_POST in a loop. What I'm trying to get is this:
What I tried and get parse error with is:
Any suggestions?
FnL
Code:
$insAmt_1 = $_POST"['1ins1']";
$insAmt_2 = $_POST"['1ins2']";
$insAmt_3 = $_POST"['1ins3']";
then
$insAmt_1 = $_POST"['2ins1']";
$insAmt_2 = $_POST"['2ins2']";
$insAmt_3 = $_POST"['2ins3']";
etc.
What I tried and get parse error with is:
Code:
for ($i = 1; $i <= 8; $i++) {
$insAmt_1 = $_POST"['".$i."ins1']";
$insAmt_2 = $_POST"['".$i."ins2']";
$insAmt_3 = $_POST"['".$i."ins3']";
...
}
Any suggestions?
FnL