plugins/SpecialPageFuncs.php
changeset 1356 e80b5733ce9d
parent 1352 d97cf005f674
child 1377 fa2b0825bbc5
equal deleted inserted replaced
1355:12c23b83c79d 1356:e80b5733ce9d
   714 		session_start();
   714 		session_start();
   715 		header('Content-type: text/javascript');
   715 		header('Content-type: text/javascript');
   716 		$key = "upload_progress_{$_GET['uploadstatus']}";
   716 		$key = "upload_progress_{$_GET['uploadstatus']}";
   717 		$info = isset($_SESSION[$key]) ? $_SESSION[$key] : array();
   717 		$info = isset($_SESSION[$key]) ? $_SESSION[$key] : array();
   718 		if ( isset($_SESSION[$key]) && $_SESSION[$key]['done'] )
   718 		if ( isset($_SESSION[$key]) && $_SESSION[$key]['done'] )
       
   719 		{
   719 			unset($_SESSION[$key]);
   720 			unset($_SESSION[$key]);
       
   721 		}
       
   722 		
       
   723 		if ( !isset($_SESSION[$key]) )
       
   724 		{
       
   725 			// workaround to cause stuck uploads on the client side to shut up
       
   726 			$info['done'] = true;
       
   727 		}
   720 		
   728 		
   721 		if ( is_array($info) )
   729 		if ( is_array($info) )
   722 		{
   730 		{
   723 			$info['current_time'] = time();
   731 			$info['current_time'] = time();
   724 			if ( !empty($_GET['cancel']) )
   732 			if ( !empty($_GET['cancel']) )