CodeIgniter Forums
Form validation should use valid_email in helper - Printable Version

+- CodeIgniter Forums (https://forum.codeigniter.com)
+-- Forum: Archived Discussions (https://forum.codeigniter.com/forumdisplay.php?fid=20)
+--- Forum: Archived Development & Programming (https://forum.codeigniter.com/forumdisplay.php?fid=23)
+--- Thread: Form validation should use valid_email in helper (/showthread.php?tid=17314)



Form validation should use valid_email in helper - El Forum - 04-01-2009

[eluser]dmorin[/eluser]
The Form Validation, old validation, and email helper all contain a valid_email() function. But instead of the libraries using the helper, none of them reference one another. So, if we need to update the email address detection regex that CI uses (for example, to include single quotes which are valid and people do use), we have to extend all three.

Instead, it seems like the two validation libraries should use the version in the helper in which case overriding that single one would have the desired effect across the system.