Function isReservedName
Check if a name is in the reserved words list. (name, current member id, name/username?.) - checks if name is a reserved name or username. - if is_name is false, the name is assumed to be a username. - the id_member variable is used to ignore duplicate matches with the current member.
Package: SMF
Copyright: 2020 Simple Machines and individual contributors
License: BSD
Author: Simple Machines https://www.simplemachines.org
Located at Sources/Subs-Members.php
Copyright: 2020 Simple Machines and individual contributors
License: BSD
Author: Simple Machines https://www.simplemachines.org
Located at Sources/Subs-Members.php
string |
$name |
The name to check |
integer |
$current_id_member = 0 |
The ID of the current member (to avoid false positives with the current member) |
boolean |
$is_name = true |
Whether we're checking against reserved names or just usernames |
boolean |
$fatal = true |
Whether to die with a fatal error if the name is reserved |
boolean|
|
False if name is not reserved, otherwise true if $fatal is false or dies with a fatal_lang_error if $fatal is true |