How do global variables $ _COOKIES and $ _SESSION work? [duplicate]

1

I know that in PHP there are two superglobal variables $_COOKIE and $_SESSION , but how do they work, in fact? And what do they stand for my application?

    
asked by anonymous 28.08.2018 / 02:58

1 answer

0

Quickly, $ _SESSION and $ _COOKIES are used to store information.

$ _SESSION stores the information on the server, so it is safer and generally used for logins and passwords.

$ _COOKIES stores the information in your user's browser and is most often used to store user preferences, shopping cart, etc.

    
28.08.2018 / 03:16