0
I have some loops in my php and want to get an array like this:
Array ( [nome1] => valor [nome2] => valor )
inside a loop I tried : $array_dos_pagamentos[nome] = $variavelnome;
and another loop $array_dos_pagamentos[valor] = $variavelvalor;
the problem is that the Array ( [nome] => Susana laginha, [valor] => 84 )
or just a record.. if I do :
$array_dos_pagamentos[]=$variavelnome;
$array_dos_pagamentos[]=$variavelvalor;
sai
Array (
[0] => Beatriz grade
[1] => 15
[2] => Promotores
[3] => 40
[4] => Susana laginha
[5] => 84
)
try
$array_dos_pagamentos = array('nome' => $variavelnome, 'valor' => $variavelvalor);
– Marco Aurélio Deleu
remembering that if the question answered your question, mark the question as answered.
– Ruggi