Files and Folders: Class Grep Search
Cinu Chacko (contact me)
This class can be used to search files in directories like the Unix command grep.
It can traverse a given directory recursively and search for a given text the contents of files with a given list of file name extensions.
The path of the files that have the given text is stored in a class array variable and the class returns the number of occurrences.
The idea of the class was inspired on the Grep Simulator class written by Er. Rochak Chauhan.
Click here for detailed information about this class on phpclasses.org