faqts : Computers : Programming : Languages : PHP : Common Problems : Arrays

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

6 of 9 people (67%) answered Yes
Recently 5 of 8 people (63%) answered Yes

Entry

How can I skip a row in a two-dimensional array in PHP3?

May 21st, 2001 17:42
Onno Benschop, Peter Van den Berg,


for (reset($myArray) ; $row=current($myArray) ; next($myArray)) {
  for (reset($row) ; $field=current($row) ; next($row)) {
    echo $field ;
    //skip a field ;
    next($field) ;
  }
}