docs.roxen.comBack to normal mode
DocsRoxenWebServer 4.0Administrator ManualAppendix A - Glob Expression Syntax
Copyright © 2006, Roxen Internet Software
Suggestions, comments & compliments
manuals@roxen.com

Appendix A - Glob Expression Syntax

A glob pattern, is a sort of string that can be compared and matched against several other strings. The rules for a glob pattern are fairly simple. There exist two special characters, "*" and "?". "*" can match zero or more characters of any kind while "?" can match one, and only one, character of any kind. All other characters match themselves. Some examples:

"Hello" matches "Hello" and only "Hello", e.g. not "hello".

"Hi?" matches all string with three letters than begin with "Hi", e.g. "Him" and "His", but not "Hi" nor "Hiss".

"Hi*m" matches all strings that begin with "Hi" and ends with "m", e.g. "Him" and "Hi mum".

"Hi?*m" matches all strings that begin with "Hi", ends with "m" and has at least one character between "Hi" and "m".

"Hi*m*" matches all strings that begin with "Hi" and has an "m" in it.

Note!

It is not possible to escape the characters "*" and "?" so that they match themselves. If you need to do such a match you have to use a regular expression.