I want to make the input text allow only the following strings:
site.com; site.com.br; site123.com123.br; site-123.com. But never: site-123-.com.br
My expression looks like this:
(([a-z0-9-]{3,})[^-])+\.([a-z0-9]{2,})(([.]{1})([a-z]{2}))?
That way, when I type: site.co*/@m.br, it is accepting.
That is, I want you to accept strokes, but never at the end of the first string or before the first dot.