Prev | Current Page 515 | Next

W. Jason Gilmore

"Beginning PHP and MySQL: From Novice to Professional"

Article identifiers could be mapped to the user??™s SID, allowing
you to compile a list of articles that the user has read, and display that list as the user
continues to navigate. In the coming sections, you??™ll learn how to store and retrieve
this session information.
?– Tip You can also retrieve cookie information via the $_REQUEST superglobal. For instance, if the
session name is sid, $_REQUEST['sid'] will retrieve the SID, just as $_COOKIE['sid'] would. However,
for purposes of clarity, consider using the superglobal that best matches the variable??™s place of origin.
This process continues until the user either closes the browser or navigates to an
external site. If you use cookies, and the cookie??™s expiration date has been set to some
date in the future, should the user return to the site before that expiration date, the
session could be continued as if the user never left. If you use URL rewriting, the session
is definitively over, and a new one must begin the next time the user visits the site.
In the coming sections, you??™ll learn about the configuration directives and functions
responsible for carrying out this process.
Configuration Directives
Almost 30 configuration directives are responsible for tweaking PHP??™s session-handling
behavior. Because many of these directives play such an important role in determining
this behavior, you should take some time to become familiar with the directives and
their possible settings.


Pages:
503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527