regex space followed by number at the end of a string code example Example: php preg match space or start of string /\b(stackoverflow)\b/