has any done this way? On Tue, Apr 5, 2011 at 11:15 AM, cake-learner <sh.koiz...@gmail.com> wrote:
> I have set up an application object to save all info in session, but I > don't know how to save with "cakephp" session. > > In app_controller, i have set up like this in beforefilter() and > beforeRender() but I am not able to retrieve the informatoin when i go > to the next page. What I am doing wrong here? > > beforefilter(){ > if( $gwo = unserialize( $this -> Session -> read( "GWO" ) ) > instanceof GWO ) ){ > $this -> gwo = $gwo; > }else{ > $this -> gwo = new GWO(); > } > } > > and > > beforeRender(){ > $this -> Session -> write( "GWO", serialize( $this -> gwo ) ); > } > > class GWO{ > var $curUser; > var $curSurv; > var $curRev; > var $curEmp; > var $curDep; > var $depList; > var $surveyType; > var $curSurv_id; > } > > -- > Our newest site for the community: CakePHP Video Tutorials > http://tv.cakephp.org > Check out the new CakePHP Questions site http://ask.cakephp.org and help > others with their CakePHP related questions. > > > To unsubscribe from this group, send email to > cake-php+unsubscr...@googlegroups.com For more options, visit this group > at http://groups.google.com/group/cake-php > -- Our newest site for the community: CakePHP Video Tutorials http://tv.cakephp.org Check out the new CakePHP Questions site http://ask.cakephp.org and help others with their CakePHP related questions. To unsubscribe from this group, send email to cake-php+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/cake-php