Update of /cvsroot/phplib/php-lib/php/session
In directory usw-pr-cvs1:/tmp/cvs-serv4113/session
Modified Files:
session3.inc
Log Message:
fix a few undefined variable access warnings
Track changes to session from -stable tree
Index: session3.inc
===================================================================
RCS file: /cvsroot/phplib/php-lib/php/session/session3.inc,v
retrieving revision 1.3
retrieving revision 1.4
diff -C2 -d -r1.3 -r1.4
*** session3.inc 2000/09/07 15:56:08 1.3
--- session3.inc 2001/08/12 04:58:36 1.4
***************
*** 32,36 ****
## page_close() guaranteed.
! var $allowcache = "passive"; ## "passive", "no", "private" or "public"
var $allowcache_expire = 1440; ## If you allowcache, data expires in this
## many minutes.
--- 32,36 ----
## page_close() guaranteed.
! var $allowcache = "no"; ## "passive", "no", "private" or "public"
var $allowcache_expire = 1440; ## If you allowcache, data expires in this
## many minutes.
***************
*** 64,68 ****
function is_registered($name) {
! if ($this->pt[$name] == true)
return true;
return false;
--- 64,68 ----
function is_registered($name) {
! if (isset($this->pt[$name]) && $this->pt[$name] == true)
return true;
return false;
***************
*** 264,270 ****
}
! ## serialize($prefix,&$str):
##
! ## appends a serialized representation of $$prefix
## at the end of $str.
##
--- 264,270 ----
}
! ## serialize($var,&$str):
##
! ## appends a serialized representation of $$var
## at the end of $str.
##
***************
*** 466,472 ****
# Note that in HTTP/1.1 the Cache-Control headers override the Expires
# headers and HTTP/1.0 ignores headers it does not recognize (e.g,
! # Cache-Control). Mulitple Cache-Control directives are contained
! # in a single header(), since PHP only sends one HTTP header per
! # header field-name (e.g., cache-control, Expires...)
switch ($this->allowcache) {
--- 466,475 ----
# Note that in HTTP/1.1 the Cache-Control headers override the Expires
# headers and HTTP/1.0 ignores headers it does not recognize (e.g,
! # Cache-Control). Mulitple Cache-Control directives are split into
! # mulitple headers to better support MSIE 4.x.
! #
! # Added pre- and post-check for MSIE 5.x as suggested by R.C.Winters,
! # see http://msdn.microsoft.com/workshop/author/perf/perftips.asp#Use%20Cache-Control%20Extensions
! # for details
switch ($this->allowcache) {
***************
*** 474,477 ****
--- 477,482 ----
$mod_gmt = gmdate("D, d M Y H:i:s", getlastmod()) . " GMT";
header("Last-Modified: " . $mod_gmt);
+ # possibly ie5 needs the pre-check line. This needs testing.
+ header("Cache-Control: post-check=0, pre-check=0");
break;
***************
*** 481,485 ****
header("Expires: " . $exp_gmt);
header("Last-Modified: " . $mod_gmt);
! header("Cache-Control: public, max-age=" . $this->allowcache_expire * 60);
break;
--- 486,491 ----
header("Expires: " . $exp_gmt);
header("Last-Modified: " . $mod_gmt);
! header("Cache-Control: public");
! header("Cache-Control: max-age=" . $this->allowcache_expire * 60);
break;
***************
*** 488,492 ****
header("Expires: Mon, 26 Jul 1997 05:00:00 GMT");
header("Last-Modified: " . $mod_gmt);
! header("Cache-Control: private, max-age=" . $this->allowcache_expire * 60);
break;
--- 494,500 ----
header("Expires: Mon, 26 Jul 1997 05:00:00 GMT");
header("Last-Modified: " . $mod_gmt);
! header("Cache-Control: private");
! header("Cache-Control: max-age=" . $this->allowcache_expire * 60);
! header("Cache-Control: pre-check=" . $this->allowcache_expire * 60);
break;
***************
*** 495,498 ****
--- 503,507 ----
header("Last-Modified: " . gmdate("D, d M Y H:i:s") . " GMT");
header("Cache-Control: no-cache");
+ header("Cache-Control: post-check=0, pre-check=0");
header("Pragma: no-cache");
break;
|