...

View Full Version : How to assign first item in an array as var?



YourDirector
09-01-2011, 03:05 PM
Hey everyone,

I have an array of file names and I need to set a var as the first filename then when this is next called pass the next filename down into the var and so on.

Is this possible?

Thanks

Josh

kbluhm
09-01-2011, 03:59 PM
Are you talking about iterating over the array?


foreach ( $files as $file )
{
var_dump( $file );
}



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum