Jump to content

[SOLVED] Glob, look for .JPG as well as .jpg


jacko310592

Recommended Posts

A quick search of the manual for glob brought up a post by our very own Crayon Violent which indicates the glob regex supports basic alternation. It looks like you'd be looking for something like...

 

$filecount = count(glob("{$dirLocation}/*.{jpg,JPG,jpeg,JPEG}"));

NB: Untested.

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.