Is it a good practice to store user info. in sessions?


Posted on 16th Feb 2014 07:03 pm by admin

I am making a user class for my script which stores all the user information in sessions. It takes user id as parameter and gets the info from database and stores it in the session variable. I did this for easy access of data as I don't want to query database every now and then.

Did you know?Explore Trending and Topic pages for more stories like this.
Is this a good practice? If not, why?
No comments posted yet

Your Answer:

Login to answer
94 Like 43 Dislike
Previous forums Next forums
Other forums

Mail Script Problems
I have created a PHP mail script. I am having a problem though. In $body i am trying to put two va

cURL proxy
Okay here is the thing... i know how to add proxys

Code: curl_setopt($ch, CURLOPT_PROXYTYPE,

header redirect problems? please help
Ok i am making a site that generates youtube thumbnails and i am generating an image that displays 1

reorder sql query
ok so i have this very simple code:
Code: $query = "SELECT search_keywords, COUNT(search_key

Cursor statement failed with errors
Following statement failed with the errors.

cursor proj_cursor1 is (select projectID from

php email checker
I am having alot of trouble finding info on how to do these email things. I need to do the following

Best way to cross matching large datasets
Hi,

Im running a script where am I cross matching about 200 000 data sets with each other. Ea

The control with ID 'ace' requires a ScriptManager on the page
I'm trying to add a simple AlwaysVisibleControlExtender to my page, but it's not working. I get the

Comparing two dates
Hi Guys
I have two dates I want to compare. Below is my current implementation. The problem with

Website Direction...
I recently used this code to try and make it so the page loads as http://www.domain.com/ when you ty

Sign up to write
Sign up now if you have flare of writing..
Login   |   Register
Follow Us
Indyaspeak @ Facebook Indyaspeak @ Twitter Indyaspeak @ Pinterest RSS



Play Free Quiz and Win Cash