• 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
current user data

#3
(08-20-2019, 12:28 AM)muuucho Wrote: 1 SESSION
When a user login, I grab and store the user data in a session array, like $_SESSION['current_user']. Of course, I need to ensure that if the user data changes throughout the session, the session data has to change accordingly.

2 Grab data on every request
When a logged-in user requests any page, all user data is grabbed from each table and is stored in an array, like $current_user
3 Grab data only when you need it, and only the data you need, not everything. Do you really need all that on every request?
Test your translation files with Translation Tester
Reply


Messages In This Thread
current user data - by muuucho - 08-20-2019, 12:28 AM
RE: current user data - by InsiteFX - 08-20-2019, 03:30 AM
RE: current user data - by muuucho - 08-22-2019, 02:22 PM
RE: current user data - by includebeer - 08-20-2019, 09:38 AM
RE: current user data - by muuucho - 08-22-2019, 02:24 PM
RE: current user data - by includebeer - 08-23-2019, 05:44 AM

Digg   Delicious   Reddit   Facebook   Twitter   StumbleUpon  


  Theme © 2014 iAndrew  
Powered By MyBB, © 2002-2020 MyBB Group.