I have a regular expression for a postal address in which I need to add length checks: 1 - part before dog, 2 - part after dog, 3 - total length of the whole field. I tried to use forward looking, but, unfortunately, did not work. One special condition - the regular expression should remain as it is, you just need to add the necessary length checks. The expression looks like this:
^((\"[^\"]+\")|([\w\!\#\$\%\^\&\*\(\)\_\+\}\{\-\|\'\/\?\)\(\u0400-\u04FF\~\=\`]+\.)*([\w\!\#\$\%\^\&\*\(\)\_\+\}\{\-\|\'\/\?\)\(\u0400-\u04FF\~\=\`])+)@(([0-9A-Za-z\u0400-\u04FF][\-\_]{0,1})+(\.))+(([0-9A-Za-z\u0400-\u04FF][\-\_]{0,1})+?)$