I want to validate email addresses, it's easy, there are lots of RegEx while I search Google, but here, I want to also allow *@domain.com, here is what I have right now:
/^[\w-\.\d*]+@[\w\d]+(\.\w{2,4})$/
This works just fine for regular email addresses like [email protected] and it also does what I want: *@somedomain.com, but this doesn't allow [email protected].
How I should fix it?
Thanks in advance
+is not accepted in the localpart.