dev/core#2769 use php email validation not hacked qf
authorEileen McNaughton <emcnaughton@wikimedia.org>
Tue, 17 Aug 2021 22:44:19 +0000 (10:44 +1200)
committerEileen McNaughton <emcnaughton@wikimedia.org>
Tue, 24 Aug 2021 11:44:52 +0000 (23:44 +1200)
commit5ae46289c2dc8df73038a621e022564373dfddf8
tree5cfb1e5b975f824c061b43cd78f34d40d890f3a1
parent7bdfe1218c31dbec6dfdf440161a5ccb24db915e
dev/core#2769 use php email validation not hacked qf

Per https://lab.civicrm.org/dev/core/-/issues/2769 we have had problems over the years with
quickform's email validation and we now have a hacked version that is
problematic from a maintenance pov & also doesn't work
with the string I have just encountered: name.-o-.i.10@example.com
(which I am told is valid and which passes the php filter).

We already have an email rule which calls a php native function
which is better maintained than our layers of hacks. This
PR registers our email rule - which overrides the quickform
one. If we merge this we can revert quickform back to
unhacked which will improve debugging
and maintenance (although it's actually bypassed
now with this change)
CRM/Core/Form.php
CRM/Utils/Rule.php
tests/phpunit/CRM/Utils/RuleTest.php