-
Notifications
You must be signed in to change notification settings - Fork 34
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 with utf8 #1293
Comments
You need sanitize text from Word. |
@dkulyk hmm why would we need to sanitize? I want to allow even emojis so sanitization should not be necessary. |
@shirshak55 Do you have any update in this issue?? I have the same problem! |
@emilianotisato Sorry but I stopped using nova for too many issues and edge cases :(. Don't get me wrong but for simple admin panel I still love Laravel Nova for its easiness. |
Ok, thanks! In case is usefull for anyone, I hook on the /**
* Handle the money movement "saving" event.
*
* @param \App\MoneyMovement $moneyMovement
* @return void
*/
public function saving(MoneyMovement $moneyMovement)
{
// Sanitize comments to avoid conflicts y nova index rendering
$moneyMovement->comment = utf8_encode(preg_replace('/[^\x0A\x20-\x7E\xC0-\xD6\xD8-\xF6\xF8-\xFF]/','', $moneyMovement->comment));
} |
This issue relates to an unsupported version of Nova. If you're still experiencing this in the latest version of Nova, please open a new ticket, thanks! |
Might not be related but might also help: This was the issue:
The answer was to use the "unicode safe" version of the string functions: mb_substr and mb_strlen |
Description:
Nova has so weird bug that it cannot even process some character.
Steps To Reproduce:
Create a Text field and insert this.
character was copied from Microsoft word or something by user and i needed to delete and test every row to find which row was creating problem.
It create problem on resource index page mainly with this message
The text was updated successfully, but these errors were encountered: