Source for file RegExpConstants.inc.php
Documentation is available at RegExpConstants.inc.php
* Thanks to Jeffrey E. F. Friedl for his great work:
* "Mastering Regular Expressions"
* Identify topleveldomains with a regular expression
"TOPLEVELDOMAIN", "(?i:(?i)"
define( "INTEGER", "(?:-?[1-9]\d*|0)" );
* Identify strings that are in single quotation in a text.
define( "SINGLE_QUOTATION_STRING", "(?:'.*?[^\\\\](?:\\\\\\\\)*')" );
* Identify strings that are in double quotation in a text.
define( "DOUBLE_QUOTATION_STRING", "(?:\".*?[^\\\\](?:\\\\\\\\)*\")" );
* Identify positive integer.
define( "UNSIGNEDINTEGER", "(?:[1-9]\d*|0)" );
* Identify files of webgraphics.
define( "WEBGRAPHICS", "[^/ &?=]+\.(?:(?i)gif|png|jpg|jpeg)" );
* Identify hexadecimal colors.
define( "HEXCOLOR", "#[0-9a-fA-F]{6,6}" );
* Identify a time in ISO-format
define( "ISOTIME", "([01]\d|2[0-3])(?::([0-5]\d)){1,2}" );
"EMAIL", "[-a-zA-Z0-9_.]+@"
. "(([-a-zA-Z0-9]+\\.)+" // domain
. "|\[?([0-9]{1,3}\.){3,3}" // ip
* Identify websafe colors.
* Identify webcolor names
"WEBCOLORNAMES", "(?:(?i)"
|