01-25-2003, 12:06 PM
|
#5 (permalink)
|
|
Techno Rat
Join Date: Jan 2003
Location: San Diego
Posts: 559
|
Re: Re: whats 0:
Quote:
Originally posted by redhead
The code does what you tell it to do, displayes every item in your list, you have a first item, with identifyer "log->blah" that holds value "foo" in the foreach it just tels you that the identifyer log is reffering to the blah, and that the first item (0) is holding the value foo.
It is _not_ C style, it is a derived feature from the C shell where foreach is buildin as a special command. php programmers just thought it would be a useful command in the php language aswell.
If anything I would say foreach orriginates from perl (http://www-106.ibm.com/developerwork...ry/l-p560.html)
|
0
Ilya
__________________
> SELECT * FROM users WHERE clue > 0
0 rows returned
|
|
|