1// Match a string that ends with abc, similar to LIKE '%abc'
2if (theString.match(/^.*abc$/))
3{
4 /*Match found */
5}
6
7// Match a string that starts with abc, similar to LIKE 'abc%'
8if (theString.match(/^abc.*$/))
9{
10 /*Match found */
11}
12