NYCPHP Meetup

[nycphp-talk] Accessing First Element of Array

Paul M Jones pmjones88 at gmail.com
Sun Aug 26 21:06:47 EDT 2007


On Aug 26, 2007, at 7:54 PM, Jon Baer wrote:

> Is it anything that $array[0] would not be able to get access to?

The function `current($array)` should do the trick.  Make sure you do  
so before trying to loop through the array or anything. ;-)

   <http://php.net/current>



--

Paul M. Jones  <http://paul-m-jones.com>

Solar: Simple Object Library and Application Repository
for PHP5.  <http://solarphp.com>

Join the Solar community wiki!  <http://solarphp.org>

Savant: The simple, elegant, and powerful solution for
templates in PHP.  <http://phpsavant.com>





More information about the talk mailing list