* Fix wrong setting of sessionVar.
This commit is contained in:
@@ -2,3 +2,5 @@
|
||||
$config->misc->api = 'https://api.zentao.net';
|
||||
$config->misc->enApi = 'https://api.zentao.pm';
|
||||
$config->misc->qucheng = 'https://www.qucheng.com';
|
||||
|
||||
$config->misc->disabledSessionVar = array('user', 'tutorialmode');
|
||||
|
||||
@@ -179,7 +179,7 @@ class misc extends control
|
||||
/**
|
||||
* Show version changelog
|
||||
* @access public
|
||||
* @return viod
|
||||
* @return void
|
||||
*/
|
||||
public function changeLog($version = '')
|
||||
{
|
||||
@@ -224,13 +224,13 @@ class misc extends control
|
||||
* Show captcha and save to session.
|
||||
*
|
||||
* @param string $sessionVar
|
||||
* @param string $uuid
|
||||
* @access public
|
||||
* @return void
|
||||
*/
|
||||
public function captcha($sessionVar = 'captcha', $uuid = '')
|
||||
public function captcha($sessionVar = 'captcha')
|
||||
{
|
||||
if($sessionVar == 'user') die('The string user is not allowed to be defined as a session field.');
|
||||
if(in_array(strtolower($sessionVar), $this->config->misc->disabledSessionVar)) die("The string {$sessionVar} is not allowed to be defined as a session field.");
|
||||
|
||||
$obLevel = ob_get_level();
|
||||
for($i = 0; $i < $obLevel; $i++) ob_end_clean();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user