Drupal: session variable is lost when not registered

I have a module in Drupal 6 that stores some information in the $ _SESSION array. I am using this information to customize the content on another page.

The problem is that when I am not registered with Drupal, the information is not saved in the session. When I logged in, it works as expected.

Any ideas? Thank.

+3
source share
1 answer

Found the answer here . The "users" table should have a user with uid = 0. For some reason, my project did not have one, so I inserted it manually and now the session variables are saved.

+3
source

Source: https://habr.com/ru/post/1770177/


All Articles