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

search function
HI guys,

if anyone could point us in the right direction of how to do this, or provide some t

question about n
I was looking at some of the things you could do with php and one of the things I have tried is n.<

Problem with PHP code- simple contact form
I'm relativily new to PHP; I know HTML and CSS stuff but I have a problem- I have a contact form wit

Socket programming
Hello all,

I have a PHP socket script. GPS trackers connect to this socket. IMEI verification

Intrastat Report Config in ECC 6.0 - goods Movement in EU countries
Colleagues, need ur help to understand the changes require in ECC 6 standard Report configuration se

j1inmis Ouput layout changes
Hi,

Can anybody tell how can j1inmis output layout can be changed so that vendor names ge

mod_rewrite.c on windows ??
why it's not working on windows while it's working on other hosts???

this is the code i got

xml
<?php

echo "<h1>XML Articles</h1>";

$home

standard ALV application toolbar, into custom report....
HI,

I have a question regarding displaying standard ALV menu path and application toolbar

Session variable help
I'm having a very troubling issue. Maybe I'm just looking over something but I have looked at the co

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