Dont allow _ symbol when creating character name.

This commit is contained in:
Znote 2019-10-16 22:45:48 +02:00
parent 27d7ce44eb
commit 734f5c7969

View File

@ -24,7 +24,7 @@ if (empty($_POST) === false) {
if (user_character_exist($_POST['name']) !== false) {
$errors[] = 'Sorry, that character name already exist.';
}
if (!preg_match("/^[a-zA-Z_ ]+$/", $_POST['name'])) {
if (!preg_match("/^[a-zA-Z ]+$/", $_POST['name'])) {
$errors[] = 'Your name may only contain a-z, A-Z and spaces.';
}
if (strlen($_POST['name']) < $config['minL'] || strlen($_POST['name']) > $config['maxL']) {