Stopped PHP sessions from blocking HTTP requests.
git-svn-id: https://svn.code.sf.net/p/xcat/code/xcat-core/trunk@11001 8638fb3e-16cb-4fca-ae20-7b5d299a9bcd
This commit is contained in:
		| @@ -5,6 +5,7 @@ | ||||
|  | ||||
| // Retain session variables across page requests | ||||
| session_start(); | ||||
| session_write_close();	// Do not block HTTP requests | ||||
|  | ||||
| // The settings below display error on the screen, | ||||
| // instead of giving blank pages. | ||||
| @@ -307,7 +308,6 @@ function logout() { | ||||
|  | ||||
| 	// Clear server store of data | ||||
| 	$_SESSION=array(); | ||||
| 	session_destroy(); | ||||
| } | ||||
|  | ||||
| /** | ||||
|   | ||||
| @@ -3,6 +3,8 @@ $TOPDIR = '..'; | ||||
| require_once "$TOPDIR/lib/functions.php"; | ||||
| require_once "$TOPDIR/lib/jsonwrapper.php"; | ||||
|  | ||||
| session_start(); | ||||
|  | ||||
| header("Last-Modified: " . gmdate("D, d M Y H:i:s") . " GMT"); | ||||
| header("Cache-Control: no-store, no-cache, must-revalidate"); | ||||
| header("Cache-Control: post-check=0, pre-check=0", false); | ||||
|   | ||||
| @@ -5,6 +5,7 @@ | ||||
|  | ||||
| // Retain session variables across page requests | ||||
| session_start(); | ||||
| session_write_close();	// Do not block HTTP requests | ||||
|  | ||||
| // The settings below display error on the screen, | ||||
| // instead of giving blank pages. | ||||
| @@ -319,6 +320,5 @@ function logout() { | ||||
|  | ||||
| 	// Clear server store of data | ||||
| 	$_SESSION=array(); | ||||
| 	session_destroy(); | ||||
| } | ||||
| ?> | ||||
|   | ||||
| @@ -3,6 +3,8 @@ $TOPDIR = '..'; | ||||
| require_once "$TOPDIR/lib/srv_functions.php"; | ||||
| require_once "$TOPDIR/lib/jsonwrapper.php"; | ||||
|  | ||||
| session_start(); | ||||
|  | ||||
| header("Last-Modified: " . gmdate("D, d M Y H:i:s") . " GMT"); | ||||
| header("Cache-Control: no-store, no-cache, must-revalidate"); | ||||
| header("Cache-Control: post-check=0, pre-check=0", false); | ||||
|   | ||||
		Reference in New Issue
	
	Block a user