Become Zend Certified

Prepare for the ZCE exam using our quizzes (web or iPad/iPhone). More info...

When you're ready get 7.5% off your exam voucher using voucher CJQNOV23 at the Zend Store


This adapter generates a parsable PHP code representation using var_export(). On restoring, the data will be executed using eval.

There are no configuration options for this adapter.

Unserializing objects

Objects will be serialized using the __set_state magic method. If the class doesn't implement this method, a fatal error will occur during execution.

Uses eval()

The PhpCode adapter utilizes eval() to unserialize. This introduces both a performance and potential security issue as a new process will be executed. Typically, you should use the PhpSerialize adapter unless you require human-readability of the serialized data.

Zend Framework