Manual:Hooks/isValidEmailAddr

isValidEmailAddr
Available from version 1.12.0
Override the result of Sanitizer::validateEmail().
Define function:
public static function onisValidEmailAddr( $addr, &$result ) { ... }
Attach hook: In extension.json:
{
	"Hooks": {
		"isValidEmailAddr": "MyExtensionHooks::onisValidEmailAddr"
	}
}
Called from: File(s): Sanitizer.php
Interface: isValidEmailAddrHook.php

For more information about attaching hooks, see Manual:Hooks .
For examples of extensions using this hook, see Category:isValidEmailAddr extensions.

DetailsEdit

  • string $addr: The e-mail address entered by the user
  • bool/null &$result: Set this and return false to override the internal checks