Regex Pattern Structure Javascript Form Submit