Question

Could anybody help me to understand this issue?
The problem is:

I have a two versions of my application that work in parallel. This means that I have sessions already started in one application that I should use in another app. First version uses PHP sessions ($_SESSION with custom handlers) and second version of application built on Zend Framework and it should use Zend_Session.

So when I try to create new Zend_Session_Namespace("default") instance I get an error that session was already started and it's true.

So the question is — can I initialize Zend_Session object with the data already stored in PHP $_SESSION?

Était-ce utile?

La solution 2

Ok, I solved this issue, and in case of me the solution is:

  1. In old version I push member's ID into cookie
  2. In new version I fetch that ID and use different sessions system with own handler.

The one thing that may up security and may help avoid collisions it's check member's email using pubcookie.

Hope my solution helps someone.

Autres conseils

I had similar problem, and figured it out form zend site, This worked for me: in .htaccess file do:

php_value session.auto_start 0

For ref check: http://framework.zend.com/manual/en/zend.session.advanced_usage.html

Hope it helps

Licencié sous: CC-BY-SA avec attribution
Non affilié à StackOverflow
scroll top