Answers for "loop in array in php"

PHP
13

php loop through array

foreach (array_expression as $value)
    statement
foreach (array_expression as $key => $value)
    statement
Posted by: Guest on May-26-2020
1

php loop through array

$letters = ['a','b','c'];
foreach ($letters as $item) {
  echo $item;
}
Posted by: Guest on October-01-2020

Browse Popular Code Answers by Language