-As requested the datatables and bootstrap files have been moved into the tools folder
-Fixed spells and creatures datatable.
-Double space in name fix.
This commit is contained in:
Lee
2020-05-07 01:36:56 +01:00
parent 1799ef42a7
commit d281fc588b
9 changed files with 252 additions and 17 deletions

View File

@@ -84,6 +84,12 @@ class Validator
self::$lastError = 'Account name is too long (max. 32 chars).';
return false;
}
if(preg_match('/ {2,}/', $name))
{
self::$lastError = 'Invalid account name format. Use only A-Z and numbers 0-9 and no double spaces.';
return false;
}
if(!preg_match("/[A-Z0-9]/i", $name))
{
@@ -194,6 +200,12 @@ class Validator
self::$lastError = "Invalid name format. Use only A-Z, spaces and '.";
return false;
}
if(preg_match('/ {2,}/', $name))
{
self::$lastError = 'Invalid character name format. Use only A-Z and numbers 0-9 and no double spaces.';
return false;
}
if(!preg_match("/[A-z ']/", $name))
{
self::$lastError = "Invalid name format. Use only A-Z, spaces and '.";