Manual:Hooks/UserResetAllOptions/pl
Ta funkcja została całkowicie usunięta z jądra MediaWiki w wersji 1.38.0 (po wycofaniu w 1.37.0). |
UserResetAllOptions | |
---|---|
Dostępne od wersji version 1.24.0 (Gerrit change 144689) Usunięto w version 1.38.0 (Gerrit change 723014) Allows changing the behavior when a user's preferences are reset. For instance, certain preferences can be preserved. | |
Zdefiniuj funkcję: | public static function onUserResetAllOptions( User $user, array &$newOptions, array $oldOptions, $resetKinds ] ); ) { ... }
|
Dołącz hak: | W extension.json:
{
"Hooks": {
"UserResetAllOptions": "MediaWiki\\Extension\\MyExtension\\Hooks::onUserResetAllOptions"
}
}
|
Called from: | Plik(i): User.php Function(s): User::resetOptions |
Interface: | UserResetAllOptionsHook.php |
For more information about attaching hooks, see Podręcznik:Haki .
For examples of extensions using this hook, see Category:UserResetAllOptions extensions/pl.
Szczegóły
User $user
: User whose preferences are being reset.array &$newOptions
: New preferences as associative array.array $oldOptions
: Old preferences as associative array.array|string resetKinds
: Kinds of preferences to reset as an array or string; seeUser::resetOptions
for possible values.