it is printing as valid. special characters are not there in regular expression.
Well, neither are spaces in your regex... yet, it prints it as valid.
The reason is because you are using the find() method, which doesn't match the whole string, it only finds the substrings that matches.
BTW, at this point, you can either stay with your code that uses find() or go back to the code that uses matches(). If you choose the former, you need to have a regex that forces the whole string to be searched.
Henry
[ October 29, 2007: Message edited by: Henry Wong ]