Thus, the serialize function identifies member variables with the null * null syntax, as you show here.
The null character is encoded in the string as \0 and is usually not displayed on the output. For non-serialization, you will need to convert this “null” text back to \0 .
When I write a serialized array, I run it through a function that converts \0 to [NULL] .
$string = str_replace("\0","[NULL]",$string);
Then, when you are ready for non-socialization, you can just do the opposite
$string = str_replace("[NULL]","\0",$string);
source share