Examples of usage of foreach statement in php array
WBOYOriginal
2016-07-25 08:59:17963browse
$arr=array("one","two","three","four");
foreach ($arr as $value){
echo $value."< br>";
}
?>
Copy code
Output results
one
two
three
four
For the usage of foreach, please refer to: http://bbs.it-home.org/w3school/php/php_looping.html.
Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn