I know I can do this...
glob('/dir/somewhere/*.zip');
...to get all files ending in .zip
, but is there a way to return all files that are not ZIPs?
Or should I just iterate through and filter off ones with that extension?
You could always try something like this:
$all = glob('/dir/somewhere/*.*');
$zip = glob('/dir/somewhere/*.zip');
$remaining = array_diff($all, $zip);
Although, using one of the other methods Pascal mentioned might be more efficient.