Re: Open Session Variables [message #171271 is a reply to message #171268] |
Wed, 29 December 2010 23:05 |
Thomas 'PointedEars'
Messages: 701 Registered: October 2010
Karma:
|
Senior Member |
|
|
Thomas 'PointedEars' Lahn wrote:
> Denis McMahon wrote:
>> However, the real problem seems to be that you are storing raw simpleXML
>> objects in the $_SESSION array, when you should cast those objects to eg
> ^^^^^^^^^^^^^^^^^^^^^
>> string before storing them, and it would be better to fix that problem.
> ^^^^^^
> Perhaps you meant to serialize() them instead?
Perhaps not. “PHP Fatal error: Uncaught exception 'Exception' with message
'Serialization of 'SimpleXMLElement' is not allowed' in Command line
code:1”.
But those objects have an asXML() method which returns their string
representation (typecast to string results in the empty string instead).
PointedEars
--
Anyone who slaps a 'this page is best viewed with Browser X' label on
a Web page appears to be yearning for the bad old days, before the Web,
when you had very little chance of reading a document written on another
computer, another word processor, or another network. -- Tim Berners-Lee
|
|
|