脚本宝典收集整理的这篇文章主要介绍了php – 为什么filter_var($email,FILTER_VALIDATE_EMAIL)允许test @ test?,脚本宝典觉得挺不错的,现在分享给大家,也给大家做个参考。
那个电子邮件确实是无效的,至少这是PHP开发人员所理解的.来源提供此通知:
/* * The regex below is based on a regex by Michael Rushton. * However,IT is not identical. I changed it to only consider routeable * addresses as valid. Michael's regex considers a@b a valid address * which conflicts with section 2.3.5 of Rfc 5321 which states that: * * Only resolvable,fully-qualified domain names (FQDNs) are PErmitted * when domain names are used in SMTP. In other words,names that can * be resolved to MX RRs or address (i.e.,A or AAAA) RRs (as discussed * in Section 5) are permitted,as are CNAME RRs whose targets can be * resolved,in turn,to MX or address RRs. Local nicknames or * unqualified names MUST NOT be used.
以上是脚本宝典为你收集整理的php – 为什么filter_var($email,FILTER_VALIDATE_EMAIL)允许test @ test?全部内容,希望文章能够帮你解决php – 为什么filter_var($email,FILTER_VALIDATE_EMAIL)允许test @ test?所遇到的问题。
本图文内容来源于网友网络收集整理提供,作为学习参考使用,版权属于原作者。
如您有任何意见或建议可联系处理。小编QQ:384754419,请注明来意。