Re: array problem??

From: Date: Sun, 29 Jul 2001 19:05:26 +0000
Subject: Re: array problem??
References: 1 2  Groups: php.windows 
Request: Send a blank email to php-windows+get-8555@lists.php.net to get a copy of this message
O.....thank for yr help..^_^ "Mike Flynn" <mike@mikeflynn.net> wrote in message news:5.1.0.14.2.20010729143756.02480120@mail.mikeflynn.net... > At 11:32 AM 7/29/01 -0700, Rasmus Lerdorf wrote: > > > <?php > > > $a = array("a","b","c"); > > > > > > for ($c=0 ; $c < count($a) ; ++$c);{ > > > >Get rid of the ; there ^^^ > > Also, > echo("$a[$c] <BR>\n"); > will probably not work. > Try: > echo $a[$c]."<br>\n"; > or, using your syntax, echo($a[$c]."<br>\n"); > You may want to do $c++ rather than ++$c, if only to get into the habit of > thinking along the proper lines of pre- and post- incrementing. > > -Mike > >

« previous php.windows (#8555) next »