コード例 #1
0
 public function DoPost()
 {
     if (isset($_POST['next_btn'])) {
         if (5 > strlen(trim(CPost::Get('txtPassword1', '')))) {
             CSession::Set('wm_install_pass_error', 'Minimum password length is 5 characters.');
         } else {
             if (CPost::Get('txtPassword1', '') !== CPost::Get('txtPassword2', '')) {
                 CSession::Set('wm_install_pass_error', 'The password and its confirmation don\'t match.');
             } else {
                 $this->oSettings->SetConf('Common/AdminPassword', md5(CPost::Get('txtPassword1', '')));
                 return $this->oSettings->SaveToXml();
             }
         }
     }
     return false;
 }
コード例 #2
0
ファイル: container.php プロジェクト: Git-Host/email
 /**
  * @param string $sKey
  * @param mixed $mValue
  */
 public function SetSessionValue($sKey, $mValue)
 {
     $sUniqueKey = $this->getSessionUniqueKey();
     $aValues = CSession::get($sUniqueKey, array());
     if (!is_array($aValues)) {
         $aValues = array();
     }
     $aValues[$sKey] = $mValue;
     CSession::Set($sUniqueKey, $aValues);
 }
コード例 #3
0
 /**
  * @param string $sDesc
  */
 public function ShowError($sDesc)
 {
     CSession::Set(AP_SESS_ERROR, $sDesc);
 }
コード例 #4
0
ファイル: storage.php プロジェクト: BertLasker/Catch-design
 /**
  * @param CCalUser $oCalUser
  * @return bool
  */
 public function UpdateCalUser(CCalUser $oCalUser)
 {
     CSession::Set(CApiUsersNodbStorage::SESS_CAL_USERS_STORAGE, $oCalUser);
     return true;
 }
コード例 #5
0
ファイル: standard.php プロジェクト: hallnewman/webmail-lite
 /**
  * @return string
  */
 public function GetCurrentMode()
 {
     if (!isset($this->aMenu[$this->sMode])) {
         $this->sMode = $this->aMenuDefMode;
     }
     if (empty($this->sMode)) {
         $sScreenName = $this->GetScreenName();
         foreach (array_keys($this->aMenu) as $sKeyName) {
             $this->sMode = $sKeyName;
             CSession::Set($sScreenName . self::SESS_MODE, $this->sMode);
             break;
         }
     }
     return $this->sMode;
 }
コード例 #6
0
ファイル: index.php プロジェクト: pkdevboxy/webmail-lite
 /**
  * @param int $iTenantId
  */
 protected function setTenantAccessId($iTenantId)
 {
     CSession::Set(AP_SESS_AUTH_TENANT_ID, $iTenantId);
     $this->oAdminPanel->SetAuthTenantId($iTenantId);
     //		if (0 < $iTenantId)
     //		{
     //			$oTenant = $this->oAdminPanel->GetTenantAdminObject();
     //			if ($oTenant)
     //			{
     //				$this->oAdminPanel->SetTenantTabsInfo($oTenant);
     //			}
     //		}
 }
コード例 #7
0
ファイル: table.php プロジェクト: pkdevboxy/webmail-lite
 /**
  * @return	string
  */
 public function GetSelectedItemKey()
 {
     $aTemp = array();
     foreach (array_keys($this->aList) as $mIndex) {
         if ($mIndex == $this->sSelectedItem) {
             return $this->sSelectedItem;
         }
         $aTemp[] = $mIndex;
     }
     $sScreenName = $this->oTableScreen->GetScreenName();
     CSession::Set($sScreenName . ap_Table_Screen::SESS_FILTER, 0 < count($aTemp) ? $aTemp[0] : '');
     $this->sSelectedItem = CSession::get($sScreenName . ap_Table_Screen::SESS_FILTER, '');
     return $this->sSelectedItem;
 }