in reply to Regexp - exact matches
Without more to go on it is difficult to suggest much, but I think that you may be better served by the \b anchor than ^ and $.
From your snippit, it looks like you are concatenating several pieces of regex together before using them. This suggests that you could well end up with a regex that has several occurances of the ^ and $ anchors, which probably isn't what you want.
|
|---|