I'm not concerned with browser compatibility.

I want to know if I move my state from PHP Controlled ( Server-Side) sessions to the JavaScript Controlled ( Client - Side ) HTML 5 local storage will I gain or loose security.

I think that I would gain security because now instead of having the user identifier residing in a cookie, which is usually a file, or sql database that is easily accessible...it is not inside some sort of internal browser storage. + b.c. it is a newer technology I would hope that more security was designed into it.

Do I gain or loose security by moving from PHP Sessions to JavaScript Local Storage. ( This is for things like user id, page\_id, etc, the current state that remains after a reload and longer if needed ).

I have a JavaScript solution I want to replace my PHP Sessions with. That is why I ask. I don't care about browser compatibility.

Here is an [informative site](http://diveintohtml5.info/storage.html) on Local Storage. But Security was not mentioned.