[an error occurred while processing this directive] [an error occurred while processing this directive][an error occurred while processing this directive] [an error occurred while processing this directive] [an error occurred while processing this directive] [an error occurred while processing this directive] (none) [an error occurred while processing this directive] [an error occurred while processing this directive] [an error occurred while processing this directive] [an error occurred while processing this directive] [an error occurred while processing this directive][an error occurred while processing this directive] [an error occurred while processing this directive][an error occurred while processing this directive] [an error occurred while processing this directive][an error occurred while processing this directive] [an error occurred while processing this directive] [an error occurred while processing this directive] [an error occurred while processing this directive] (none) [an error occurred while processing this directive] [an error occurred while processing this directive] [an error occurred while processing this directive][an error occurred while processing this directive]
 
[an error occurred while processing this directive] [an error occurred while processing this directive]
Skåne Sjælland Linux User Group - http://www.sslug.dk Home   Subscribe   Mail Archive   Forum   Calendar   Search
MhonArc Date: [Date Prev] [Date Index] [Date Next]   Thread: [Date Prev] [Thread Index] [Date Next]   MhonArc
 

[PHP] Serialisering af objekt i session



Kan nogen her forklare hvordan man persisterer objekter i en session mellem sideindlæsninger?

Jeg er indtil videre faldet tilbage til at afprøve eksemplet i "Programming PHP" 2. udgave (som skulle dække PHP5 som jeg bruger). Afsnittet "Serialization" i kapitel 6: "Objects" har netop et eksempel på at lade et objekt serialisere, så man kan bruge indholdet henover sideindlæsninger i en session. Det virker bare ikke. Når jeg prøver at genbruge objektet på den næste side får jeg fejl som denne:

[Sun Jan 06 14:31:59 2008] [error] [client 192.168.1.110] PHP Fatal error: Call to a member function write() on a non-object in /var/www/html/front.php on line 13

Jeg har prøvet både at bruge session_register() som i bogens eksempel (deprecated ifølge dokumentationen) og $_SESSION. Ingen af delene virker helt.

Kan nogen hjælpe? På forhånd tak.

Med venlig hilsen
David List


 
Home   Subscribe   Mail Archive   Index   Calendar   Search

 
 
Questions about the web-pages to <www_admin>. Last modified 2008-02-01, 02:01 CET [an error occurred while processing this directive]
This page is maintained by [an error occurred while processing this directive]MHonArc [an error occurred while processing this directive] # [an error occurred while processing this directive] *