Subversion Repositories vgwhois

Rev

Rev 5 | Rev 76 | Go to most recent revision | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 5 Rev 11
Line 1... Line 1...
1
<?php
1
<?php
2
 
2
 
3
#
3
#
4
#  VWhois (ViaThinkSoft WHOIS, a fork of generic Whois / gwhois)
4
#  VGWhoIs (ViaThinkSoft Global WhoIs, a fork of generic Whois / gwhois)
5
#  Common functions in PHP
5
#  Common functions in PHP
6
#
6
#
7
#  (c) 2013-2015 by Daniel Marschall, ViaThinkSoft <info@daniel-marschall.de>
7
#  (c) 2013-2019 by Daniel Marschall, ViaThinkSoft <info@daniel-marschall.de>
8
#
8
#
9
#  License: https://www.gnu.org/licenses/gpl-2.0.html (GPL version 2)
9
#  License: https://www.gnu.org/licenses/gpl-2.0.html (GPL version 2)
10
#
10
#
11
 
11
 
12
function getpatternfiles() {
12
function getpatternfiles() {
13
        $out = array();
13
        $out = array();
14
 
14
 
15
        $files = glob(__DIR__ . '/../../main/pattern/'.'*');
15
        $files = glob(__DIR__ . '/../../main/pattern/'.'*');
16
        foreach ($files as &$file) {
16
        foreach ($files as &$file) {
17
                # see /usr/bin/gwhois
-
 
18
                if (preg_match('@\.dpkg-@', $file)) continue;
-
 
19
                if (preg_match('@\.orig$@', $file)) continue;
-
 
20
                if (preg_match('@\.bak$@',  $file)) continue;
-
 
21
                if (preg_match('@\.save$@', $file)) continue;
-
 
22
                if (preg_match('@^\.@',     $file)) continue;
17
                if (preg_match('@^\.@',     $file)) continue;
23
 
18
 
24
                $out[] = $file;
19
                $out[] = $file;
25
        }
20
        }
26
 
21