How do I group Array results outside the loop in a single variable
- In the example below the result that is inside the loop is correct but I need this same result to appear on the outside of the loop,
How can I make this work?
foreach ($ids_cotados as $value) {
echo $ids_cotados = $value.','; // 520, 130, 60, 700,
}
echo $ids_cotados; // aqui da erro só pega 520,