Properly escape '.' inside regex's.

Wow, how did I miss this? Properly escaping them now inside
directives and tags.