Jump to content

Check if directory is empty / read files from directory


Omzy

Recommended Posts

you can use the GLOB_BRACE flag to specify that you want to use the brace syntax in the glob pattern. you can use that to specify different extensions. for example

$glob = glob("director/*.{pdf,doc,docx}", GLOB_BRACE);

 

check out the manual entry for more information

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.