Welcome Guest, Not a member yet? Register   Sign In
[Solved] Best method question
#2

The directory_map() function gives you back a nested array. If you loop through it you should perform an extra verification to check if the value is a string (containing your image file name) or an array (containing all the files in the sub directory).

PHP Code:
foreach ($cached_images as $position => $image) { 
 
 if (is_string($image)) {
 
   ...
 
 }

Reply


Messages In This Thread
[Solved] Best method question - by wolfgang1983 - 02-26-2016, 03:35 PM
RE: Best method question - by Diederik - 02-26-2016, 04:46 PM
RE: Best method question - by wolfgang1983 - 02-26-2016, 05:13 PM



Theme © iAndrew 2016 - Forum software by © MyBB