You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I use Carbon Fields to create my meta fields in custom posts and users.
When I create a new post or user (use my custom models) and return the data in my ajax response then I get errors:
unserialize(): Error at offset 0 of 2 bytes in /MY_PROJECT_DIR/vendor/jgrossi/corcel/src/Model/Meta/Meta.php on line 38
But when I save my field values in my code and serialize them, I don't get an error. But in my backend I see the serialized values and I don't want this.
When I display the value with unserialize then the value is ok.
Description:
I use Carbon Fields to create my meta fields in custom posts and users.
When I create a new post or user (use my custom models) and return the data in my ajax response then I get errors:
unserialize(): Error at offset 0 of 2 bytes in /MY_PROJECT_DIR/vendor/jgrossi/corcel/src/Model/Meta/Meta.php on line 38
I also test it with these command in my site:
But when I save my field values in my code and serialize them, I don't get an error. But in my backend I see the serialized values and I don't want this.
When I display the value with unserialize then the value is ok.
I think the problem is because your function:
What can I do?
Steps To Reproduce:
You can also create your own model and extend Post
The text was updated successfully, but these errors were encountered: