[Solved] Regular Expression javascript for cip code [closed]
I’ll bite. This should work: var re = /(^\d{2}\.\d{4}$)/; (^ – begin \d{2} – match two digits \. – the period between digit sets \d{4} – match four digits $) – end And if you need the parantheses: var re = /(^\(\d{2}\.\d{4}\)$)/; jsFiddle 0 solved Regular Expression javascript for cip code [closed]