In JavaScript, regular expressions are expressions enclosed between forward slashes (/), such as the ones we've already seen (for instance, /\b[^A-Z]+\b/ ); they also can be followed by modifier characters outside the last slash (for instance, /\b[^A-Z]+\b/g , which uses the g modifier to make a search global). In general, such regular expressions can be made up of these parts :
The following sections discuss all of these parts. Note that regular expressions can get very complex very quickly, and that they're very, very compact. They'll often take some patience to work with until you become an expert. I'll start by taking a look at characters in regular expressions. |