1
0
mirror of synced 2024-12-15 07:36:03 +03:00
doctrine2/manual/docs/Working with objects - Component overview - Record - Serializing.php
2007-04-13 21:49:11 +00:00

9 lines
342 B
PHP

Sometimes you may want to serialize your record objects (possibly for caching purposes). Records can be serialized,
but remember: Doctrine cleans all relations, before doing this. So remember to persist your objects into database before serializing them.
<code type="php">
$string = serialize($user);
$user = unserialize($string);
</code>