Yii Creates Several Empty Sessions Files Each Time You Reload A Page

I have problems with sessions … every time I load a page it creates sessions files with same data!

So I decided to do a test:

I download the lastest Yii 1.1.13. I installed in a server. I visited the "demo/helloworld" page.

Each time I reload the page, it creates 3 empty sessions files in the server.

Why is that ?

If i set the “sessionName” in the config with a specific name, it’s almost fixed.

I’ve read that Yii sets the name of the session by default as " name-of-project + {space} + session ", and that generates that Yii never finds the session, and it creates again the sess_files.

Now, setting a sessionName custom without spaces, it’s almost fixed.

Now, every time I reload the "helloworld demo" page, it creates just ONE file.

But it’s still a problem :P

So any idea ? I have also same problem

I had a similar problem once when I set an invalid domain in the session cookie. Check if it matches the domain from the URL bar.