Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Problem character name with spaces #515

Open
Emilianenko opened this issue Jun 18, 2022 · 2 comments
Open

Problem character name with spaces #515

Emilianenko opened this issue Jun 18, 2022 · 2 comments

Comments

@Emilianenko
Copy link
Contributor

Emilianenko commented Jun 18, 2022

I can create character with too many spaces between the letters ,before you create it looks ok on the page ,but in database and ingame you can see that all the spaces are there.
znote name bug

@Emilianenko
Copy link
Contributor Author

I solved this problem by adding if(preg_match("/ {2,}/", $_POST['name'])) { $errors[] = 'Invalid character name format. Use only A-Z and no double spaces.'; } in createcharacter.php, but i don't know if this can cause some issue,or if is the right solution.

@tysonstrange
Copy link

I would just replace any double or more spaces with a single space and be done with it.

Probably goes hand in hand with #509

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants