Thursday, April 19, 2012

Session lost on redirect

Using latest stable version 2.1.1:

Having this in the controller that is called first:

$this->Session->write('user', $uid);
$this->redirect('/home');

and this in HomeController:

var_dump($this->Session->read('user');

Problem: The session var in HomeController is no longer set. Instead,
a new session is created. Any idea why CakePHP looses the Session on
redirects?

I already set security level to low and checked cookie domain.
--

GrandCentrix GmbH
Lüderichstrasse 2-4
51105 Köln, Deutschland

Amtsgericht Köln | HRB 70119 | Geschäftsführer: R. Freygang, R. Rottmann,
M. Willnow | USt.-IdNr.: DE266333969

--
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+unsubscribe@googlegroups.com For more options, visit this group at http://groups.google.com/group/cake-php

--

GrandCentrix GmbH
Lüderichstrasse 2-4
51105 Köln, Deutschland

Amtsgericht Köln | HRB 70119 | Geschäftsführer: R. Freygang, R. Rottmann,
M. Willnow | USt.-IdNr.: DE266333969

No comments: