Given the array below:
$aDup = array(
array('35342-1','2016-06-20','300.00'),
array('35342-2','2016-07-20','300.00'),
array('35342-3','2016-08-20','300.00'),
array('35342-4','2016-09-20','300.00')
);
I created something like:
for($i=0; $i<$dados['dados']['n-parcelas']; $i++){
$val .= "array('".$id."-".($i+1)."','".$dados['dados']['vencimento-parcela'][$i]."','".$dados['dados']['parcela'][$i]."'),";
}
$val = substr($val, 0, -1);
$aDup = array($val);
But without success.
The information should feed the following variables:
foreach ($aDup as $dup) {
$nDup = $dup[0]; // Código da Duplicata
$dVenc = $dup[1]; // Vencimento
$vDup = $dup[2]; // Valor
$resp = $nfe->tagdup($nDup, $dVenc, $vDup);
}