classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view


Ralf Eggert

I just started playing with the Zend_Session version which is located here:


I wonder why there is no Zend_Session::isStarted() method to check if
the session was already started. This would come in handy to do
something like this:

  // if button "action_search" was clicked save form data to session
  if (isset($form['action_search']))
    $session = Zend_Session::getInstance();
    $session->userselect = $form;
  // if session contains userselect data copy data to form data
  elseif (Zend_Session::isStarted())
    $session = Zend_Session::getInstance();

    if (isset($session->userselect))
      $form = $session->userselect;

So, I don't want to start a session whenever someone access the website,
but only when it makes sense.

Further question, what is the status of Zend_Session?

Best Regards,