Quote:
Originally Posted by ni_c
Btw, ive had a need to use escapes with some regex searches, and wondering if the way to describe escapes is like saying "treat the next character as plain text, rather than regular expression" because using (.*?) or (\d+) whenever square brackets are present like <span>[page (.*?)]</span> or <span>[page (\d+)]</span> doesnt work, but adding backslashes before each square bracket like <span>\[page (.*?)\]</span> does
|
any find TEXT character that has special meaning to REGEX needs to be escaped
[ ] is a 'set', ( ) is a group
dot, asterisk, question mark or slash
Grab yourself a 'Cheatography' REGEX Quick reference guide and keep it handy.
Just remember that not
everything shown works will
our REGEX variant.