Can php share variable between different requests?
You can store variable in a database or flat file, but is it also possible that a variable resides in the server memory and then can be accessed by different processes.
For example:
server starts prepare.php
browser1 requests php1.php
browser2 requests php2.php
prepare.php
load_db()
put_array_in_memory()
php1.php
get_array_from_memory()
parse_data_from_array()
display_data()
php2.php
get_array_from_memory()
manipulate_array()
put_array_in_memory()
We all know that memory is one of the fastest storages, so why not use it, for as example as cache? (size limited of course)