glob() - What exactly does it do?

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
User avatar
Luke
The Ninja Space Mod
Posts: 6424
Joined: Fri Aug 05, 2005 1:53 pm
Location: Paradise, CA

glob() - What exactly does it do?

Post by Luke »

OK, I came accross this function on php.net, and it looks interesting, but I'm not sure exactly what it does/is used for. Can somebody explain it in n00b terms?
User avatar
feyd
Neighborhood Spidermoddy
Posts: 31559
Joined: Mon Mar 29, 2004 3:24 pm
Location: Bothell, Washington, USA

Post by feyd »

glob() is used to search a location (directory) for files and directories contained within it. It allows the usage of patterns to filter the results, it can sort them, only return directories, etc..
User avatar
Luke
The Ninja Space Mod
Posts: 6424
Joined: Fri Aug 05, 2005 1:53 pm
Location: Paradise, CA

Post by Luke »

Wow... I've been looking for a way to do that for a long time. Nice!
Post Reply