summaryrefslogtreecommitdiff
path: root/ext/spl/examples/filter_tree.php
blob: 8ee4cef55676de496c842992f6563df2f5c35e91 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
<?php

/* tree view example
 *
 * Usage: php filter_tree.php <path> <regex>
 *
 * Simply specify the path to tree with parameter <path>.
 * The regular expression <regex> is used to filter the tree.
 *
 * (c) Marcus Boerger
 */

require_once("sub_dir.inc");
require_once("filter.inc");

foreach(new filter(new sub_dir($argv[1]), $argv[2]) as $f) {
	echo "$f\n";
}

?>