Print array values separately
3 answers
$myArray = array('mark'=>array(3, 4));
You can print a specific element using for example:
echo $myArray['mark'][0]; // this would print out 3
You can also loop through the array:
foreach($myArray['mark'] => $item) {
echo $item;
}
// this would result it the printing of 3 first and then 4
+1
source to share