faqts : Computers : Programming : Languages : PHP

+ Search
Add Entry AlertManage Folder Edit Entry Add page to http://del.icio.us/
Did You Find This Entry Useful?

1 of 1 people (100%) answered Yes
Recently 1 of 1 people (100%) answered Yes

Entry

In PHP4,what is the simplest way of looping through an array?

Mar 22nd, 2008 21:31
ha mo, Chad Currie, Himanshu Jain, http://www.blogvoid.com/


You can loop through an array using the foreach statement.
eg.
<?php
foreach($array as $value){
echo $value;
}
?>
The above example would echo each value in the array $array.
http://www.tantofa.com
http://www.fantofa.com
http://www.mantofa.com
http://www.tanpola.com
http://www.tampola.com
http://www.yamot.com
http://www.mozmar.com
http://www.templatestemp.com