You should try replacing all empty space with \s+, \s*, or \s. I find that most times it won't work if you actually try to leave the empty space in.
It's also a good idea to build the regex in pieces so you can use the test function at each stage. If something goes wrong it's easier to figure it out that way.
|