I'm trying to contruct a regexp to find an exact match to an input string of characters.
For example...
User inputs NC (case insensitive if possible), and their input is saved as the var old
var regexp = new RegExp(old, "gi");
How would I construct that RegExp to look for exactly old as it's input...so...I wanted to find just NC, but I don't want it to find the word "since" just NC with nothing else around it.
I've never been good with Regular Expressions, and I'm having a bit of a hard time with this one. Thanks for any help!