views:

9

answers:

0

Hello

I have developed a site for a client with a pre-existing BT hosting package. Since going live there has been a problem where $_session loses it's data between pages. I have previously fixed the problem, but somehow it has become unfixed.

Last time this problem happened, my research indicated that there is something funny with BT's setup when using sessions, and that article provided this code:

if(ini_get('register_globals') == 1)
  if(is_array($_SESSION))
    foreach(array_keys($_SESSION) as $var_to_kill)
      unset($$var_to_kill);

Which even though it looks broken to me, did in fact reduce the problem to a very low level. (i.e one drop out a day).

However, today my client is in touch again and surprise surprise, the problem is back.

Does anyone know of a solution? (My client has already stated they will not change hosts!)

Oliver