diff --git a/reference/filesystem/functions/fnmatch.xml b/reference/filesystem/functions/fnmatch.xml new file mode 100644 index 0000000000..2e47e7feb4 --- /dev/null +++ b/reference/filesystem/functions/fnmatch.xml @@ -0,0 +1,69 @@ + + + + + fnmatch + Match filename against a pattern + + + Description + + arrayfnmatch + stringpattern + stringstring + intflags + + + fnmatch checks if the passed string would + match the given shell wildcard pattern. + + + This is especialy usefull for filenames, but may also be used on regular strings. + The average user may be used to shell patterns or at least in their simplest form + to '?' and '*' wildcards so using + fnmatch instead of ereg or + preg_match for frontend search expression input may be + way more convenient for non-programming users. + + + + Checking a color name against a shell wildcard pattern. + + + + + + + See also glob, + ereg, + preg_match + and the unix manpage on fnmatch(3) for flag names + (as long as they are not documented here ). + + + + + diff --git a/reference/filesystem/functions/glob.xml b/reference/filesystem/functions/glob.xml index cebe3deefe..77663a72d5 100644 --- a/reference/filesystem/functions/glob.xml +++ b/reference/filesystem/functions/glob.xml @@ -1,5 +1,5 @@ - + glob @@ -21,13 +21,6 @@ Returns an array containing the matched files/directories or &false; on error. - - - This function is disabled in safe mode and therefore will always - return &false; in safe mode. - - Convenient way how <function>glob</function> can replace @@ -52,7 +45,9 @@ quickref.txt size 137820 <para> See also <function>opendir</function>, <function>readdir</function> and - <function>closedir</function>. + <function>closedir</function>, <function>fnmatch</function> + and the unix manpage on <literal>glob(3)</literal> for flag names + (as long as they are not documented here <!-- TODO hartmut -->). </para> </refsect1> </refentry>