[php-src] Issue #14742: SimpleXMLElement Serialization
| From: | bchubb-web | Date: | Mon, 01 Jul 2024 09:53:01 +0000 |
| Subject: | [php-src] Issue #14742: SimpleXMLElement Serialization | ||
| Groups: | php.bugs | ||
| Request: | Send a blank email to php-bugs+get-247196@lists.php.net to get a copy of this message | ||
Issue: https://github.com/php/php-src/issues/14742
Author: bchubb-web
### Description
From what i can tell the SimpleXMLElement class can be very easily serialised/unserialised which
would be very useful for use with var_exports and keeping state between requests without the need
for the stored source for the xml, would it be possible to have __serialise() which outputs the
string representation of the xml, and __unserialise() which just calls simplexml_load_string() and
returns the new instance?
the __set_state() method would also be useful but serialise would be beneficial to a larger audience