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.

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

2 decima places & How to reload my page
Hello There,

How do i put full-stop (.) after second figure from behind? ie if i have 123456

adding 0 to numbers
Hey guys i need to create a 00001 number in a loop. Is there a better way of forcing a 5 digit numbe

help with email script...
hey

I need help with my mail script

when the form on http://www.mcgdesignstudio.com/c

show random images
hey guys

can someone please suggest a way in which the following code can be edited so it onl

SAP FICO learning materials
Hi all,
I am new to this world of SAP FICO. I have taken training on SAP FICO, but was wonderin

printing links
Hi every1

i am connecting to a table in sql and the looping through with a while ($ var = my

unexpected T_ENCAPSED_AND_WHITESPACE, expecting T_STRING or T_VARIABLE or T_NUM_
Can anyone view my code and tell me why im getting the error:
Parse error: syntax error, unexpect

Variable Clash
In the past I've had variables clash. For example:

Code: <?php
$c = 5;
$ca

Parse XML
Good day,

I use oempro software and try to parse XMLReturn but it's not working for me, simpl

PHP Include w/If IE Condition Statement?
I was having a problem with Internet Exploder (big surprise, right?) displaying my drop down menus i

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