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

Adding an emoij to a label breaks everything #1380

Closed
WHITE-developer opened this issue Apr 7, 2023 · 3 comments
Closed

Adding an emoij to a label breaks everything #1380

WHITE-developer opened this issue Apr 7, 2023 · 3 comments

Comments

@WHITE-developer
Copy link

Describe the bug

When adding an emoij to a field label, the json object saved in the database isn't valid and breaks the entire site.
same issue happend in Craftcms itself craftcms/cms#2725 and in Commerce craftcms/commerce#886

Steps to reproduce

  1. Add an emoij to a form field label
  2. save the form

Form settings

  • Multi-page form: No
  • Submission Method: Ajax
  • Client-side Validation: Yes
  • Custom Form Templates: No

Craft CMS version

4.4.6.1

Plugin version

2.0.26

Multi-site?

No

Additional context

No response

@engram-design
Copy link
Member

The form shouldn't save at all if it contains an emoji. Are you saying that the form actually saves despite the error notice? If so, that certainly shouldn't be the case (it isn't for me). I'll correctly get the following form error
image

And the form will have failed to save, so refreshing the page doesn't retain my update.

@WHITE-developer
Copy link
Author

Looks like the problem is somewhere in our sever setup.
Locally I'm also getting the error notice, but on our servers we are able to save the form.

@engram-design
Copy link
Member

Just want to confirm that using emoji's in field labels is not allowed, but you shouldn't be able to save the form with the error being raised. From the sounds of your issue, if it's breaking the control panel, the form has somehow been saved despite validation errors, which shouldn't happen.

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