Steve Gattuso Steve Gattuso - 9 months ago 35
PHP Question

Where are $_SESSION variables stored?

Are $_SESSION variables stored on the client or the server?


The location of the $_SESSION variable storage is determined by PHP's session.save_path configuration. Usually this is /tmp on a Linux/Unix system. Use the phpinfo() function to view your particular settings if not 100% sure by creating a file with this content in the DocumentRoot of your domain:


Here is the link to the PHP documentation on this configuration setting: