Seguir

It blows my mind that there is no simple regex to validate email.

There are websites for the sole purpose of offering a solution, like emailregex.com and threads upon threads on StackOverflow and forums of debates around the topic and still each website will randomly refuse valid emails or accept non valid ones.

@moritzheiber I am pretty close to using something similar to: '/.+@.+\..+/i.' 😋

@hugo

Email regular expressions are the fastest way I've found to help new developers off the Dunning-Krueger hill when they start learning regexs. Seeing the number of cases you have to watch for expand, seemingly endlessly, helps people understand what they don't yet know.

The weird thing to me now isn't that email regexs don't work, it's that, somehow, email DOES work. Mostly. Kinda. Like all older computer systems, email protocols seem to be held together by duct tape and good intentions.

@nate True, if we attempted to explain how the DNS or Email protocol works to an extraterrestrial or one of our ancestrales they wouldn't believe this would ever work :)

Inicie a sessão para participar na conversa
Mastodon (PT)

Mastodon é uma rede social baseada em protocolos abertos da web e software livre e gratuito. É descentralizado como e-mail.