This question already has an answer here:
I am looping though my data and strong the result in a variable. It is currently being stored as strings.
for ($i = 0; $i < count($AnotherArray); $i++){
$myArray .= $dataArray[$i].",";
}
This correctly returns the content with commas separating the values. But i get a notice
Notice: undefind variable: $myArray in ...
The above is the first time i create and call $myArray
</div>