• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    迪恩网络公众号

PHP runtime_csfr类代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了PHP中runtime_csfr的典型用法代码示例。如果您正苦于以下问题:PHP runtime_csfr类的具体用法?PHP runtime_csfr怎么用?PHP runtime_csfr使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。



在下文中一共展示了runtime_csfr类的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的PHP代码示例。

示例1: doUpdateConfig

 static function doUpdateConfig()
 {
     global $zdbh;
     global $controller;
     runtime_csfr::Protect();
     $sql = "SELECT * FROM x_settings WHERE so_module_vc=:name AND so_usereditable_en = 'true'";
     //$numrows = $zdbh->query($sql);
     $name = ui_module::GetModuleName();
     $numrows = $zdbh->prepare($sql);
     $numrows->bindParam(':name', $name);
     $numrows->execute();
     if ($numrows->fetchColumn() != 0) {
         $sql = $zdbh->prepare($sql);
         $sql->bindParam(':name', $name);
         $sql->execute();
         while ($row = $sql->fetch()) {
             if (!fs_director::CheckForEmptyValue($controller->GetControllerRequest('FORM', $row['so_name_vc']))) {
                 $updatesql = $zdbh->prepare("UPDATE x_settings SET so_value_tx = :name2 WHERE so_name_vc = :so_name_vc");
                 $name2 = $controller->GetControllerRequest('FORM', $row['so_name_vc']);
                 $updatesql->bindParam(':name2', $name2);
                 $updatesql->bindParam(':so_name_vc', $row['so_name_vc']);
                 $updatesql->execute();
             }
         }
     }
     self::$ok = true;
 }
开发者ID:bbspike,项目名称:sentora-core,代码行数:27,代码来源:controller.ext.php


示例2: doUpdateMessage

 static function doUpdateMessage()
 {
     global $controller;
     runtime_csfr::Protect();
     $currentuser = ctrl_users::GetUserDetail();
     $formvars = $controller->GetAllControllerRequests('FORM');
     self::ExectuteUpdateNotice($currentuser['userid'], $formvars['inNotice']);
     header("location: ./?module=" . $controller->GetCurrentModule() . "&saved=true");
     exit;
 }
开发者ID:BIGGANI,项目名称:zpanelx,代码行数:10,代码来源:controller.ext.php


示例3: doShowStats

 static function doShowStats()
 {
     global $controller;
     runtime_csfr::Protect();
     $formvars = $controller->GetAllControllerRequests('FORM');
     if (isset($formvars['inDomain'])) {
         header("location: ./?module=" . $controller->GetCurrentModule() . "&show=true&domain=" . $formvars['inDomain'] . "");
         exit;
     } else {
         return false;
     }
 }
开发者ID:Boter,项目名称:madmin-core,代码行数:12,代码来源:controller.ext.php


示例4: doUpdatePassword

 static function doUpdatePassword()
 {
     global $zdbh;
     global $controller;
     runtime_csfr::Protect();
     $currentuser = ctrl_users::GetUserDetail();
     $current_pass = $controller->GetControllerRequest('FORM', 'inCurPass');
     $newpass = $controller->GetControllerRequest('FORM', 'inNewPass');
     $conpass = $controller->GetControllerRequest('FORM', 'inConPass');
     $crypto = new runtime_hash();
     $crypto->SetPassword($newpass);
     $randomsalt = $crypto->RandomSalt();
     $crypto->SetSalt($randomsalt);
     $new_secure_password = $crypto->CryptParts($crypto->Crypt())->Hash;
     $sql = $zdbh->prepare("SELECT ac_pass_vc, ac_passsalt_vc FROM x_accounts WHERE ac_id_pk= :uid");
     $sql->bindParam(':uid', $currentuser['userid']);
     $sql->execute();
     $result = $sql->fetch();
     $userpasshash = new runtime_hash();
     $userpasshash->SetPassword($current_pass);
     $userpasshash->SetSalt($result['ac_passsalt_vc']);
     $current_secure_password = $userpasshash->CryptParts($userpasshash->Crypt())->Hash;
     if (fs_director::CheckForEmptyValue($newpass)) {
         // Current password is blank!
         self::$error = "error";
     } elseif ($current_secure_password != $result['ac_pass_vc']) {
         // Current password does not match!
         self::$error = "nomatch";
     } else {
         if ($newpass == $conpass) {
             // Check for password length...
             if (strlen($newpass) < ctrl_options::GetSystemOption('password_minlength')) {
                 self::$badpassword = true;
                 return false;
             }
             // Check that the new password matches the confirmation box.
             $sql = $zdbh->prepare("UPDATE x_accounts SET ac_pass_vc=:new_secure_password, ac_passsalt_vc= :randomsalt WHERE ac_id_pk=:userid");
             $sql->bindParam(':randomsalt', $randomsalt);
             $sql->bindParam(':new_secure_password', $new_secure_password);
             $sql->bindParam(':userid', $currentuser['userid']);
             $sql->execute();
             self::$error = "ok";
         } else {
             self::$error = "error";
         }
     }
 }
开发者ID:Boter,项目名称:madmin-core,代码行数:47,代码来源:controller.ext.php


示例5: doUpdateAccountSettings

 static function doUpdateAccountSettings()
 {
     global $zdbh;
     global $controller;
     runtime_csfr::Protect();
     $currentuser = ctrl_users::GetUserDetail();
     $userid = $currentuser['userid'];
     $email = $controller->GetControllerRequest('FORM', 'inEmail');
     $fullname = $controller->GetControllerRequest('FORM', 'inFullname');
     $language = $controller->GetControllerRequest('FORM', 'inLanguage');
     $phone = $controller->GetControllerRequest('FORM', 'inPhone');
     $address = $controller->GetControllerRequest('FORM', 'inAddress');
     $postalCode = $controller->GetControllerRequest('FORM', 'inPostalCode');
     if (!fs_director::CheckForEmptyValue(self::ExecuteUpdateAccountSettings($userid, $email, $fullname, $language, $phone, $address, $postalCode))) {
         runtime_hook::Execute('OnAfterUpdateMyAccount');
         self::$ok = true;
     }
 }
开发者ID:bbspike,项目名称:sentora-core,代码行数:18,代码来源:controller.ext.php


示例6: doShadowUser

 static function doShadowUser()
 {
     global $zdbh;
     global $controller;
     runtime_csfr::Protect();
     $currentuser = ctrl_users::GetUserDetail();
     if ($currentuser['username'] == 'zadmin') {
         $sql = "SELECT * FROM x_accounts WHERE ac_deleted_ts IS NULL ORDER BY ac_user_vc";
         $numrows = $zdbh->prepare($sql);
     } else {
         $sql = "SELECT * FROM x_accounts WHERE ac_reseller_fk = :userid AND ac_deleted_ts IS NULL";
         $numrows = $zdbh->prepare($sql);
         $numrows->bindParam(':userid', $currentuser['userid']);
     }
     if ($numrows->execute()) {
         if ($numrows->fetchColumn() != 0) {
             $sql = $zdbh->prepare($sql);
             if ($currentuser['username'] == 'zadmin') {
                 //no bind needed
             } else {
                 //bind the username
                 $sql->bindParam(':userid', $currentuser['userid']);
             }
             $sql->execute();
             while ($rowclients = $sql->fetch()) {
                 if (!fs_director::CheckForEmptyValue($controller->GetControllerRequest('FORM', 'inShadow_' . $rowclients['ac_id_pk']))) {
                     ctrl_auth::KillCookies();
                     ctrl_auth::SetSession('ruid', $currentuser['userid']);
                     ctrl_auth::SetUserSession($rowclients['ac_id_pk'], runtime_sessionsecurity::getSessionSecurityEnabled());
                     header("location: /");
                     exit;
                 }
             }
         }
     }
 }
开发者ID:BIGGANI,项目名称:zpanelx,代码行数:36,代码来源:controller.ext.php


示例7: getCSFR_Tag

 static function getCSFR_Tag()
 {
     return runtime_csfr::Token();
 }
开发者ID:bbspike,项目名称:Sentastico,代码行数:4,代码来源:controller.ext.php


示例8: doSaveVhost

 static function doSaveVhost()
 {
     global $zdbh;
     global $controller;
     runtime_csfr::Protect();
     $port = $controller->GetControllerRequest('FORM', 'vh_custom_port_in');
     if (empty($port)) {
         $port = NULL;
     } else {
         $port = $controller->GetControllerRequest('FORM', 'vh_custom_port_in');
     }
     $ip = $controller->GetControllerRequest('FORM', 'vh_custom_ip_vc');
     if (empty($ip)) {
         $ip = NULL;
     } else {
         $ip = $controller->GetControllerRequest('FORM', 'vh_custom_ip_vc');
     }
     $sql = $zdbh->prepare("UPDATE x_vhosts SET\n\t\t\tvh_enabled_in  = ?,\n\t\t\tvh_suhosin_in  = ?,\n\t\t\tvh_obasedir_in = ?,\n\t\t\tvh_custom_port_in   = ?,\n                        vh_portforward_in   = ?,\n                        vh_custom_ip_vc   = ?,\n\t\t\tvh_custom_tx   = ?\n\t\t\tWHERE\n\t\t\tvh_id_pk = ?\n\t\t\tAND vh_deleted_ts IS NULL");
     $sql->execute(array(fs_director::GetCheckboxValue($controller->GetControllerRequest('FORM', 'vh_enabled_in')), fs_director::GetCheckboxValue($controller->GetControllerRequest('FORM', 'vh_suhosin_in')), fs_director::GetCheckboxValue($controller->GetControllerRequest('FORM', 'vh_obasedir_in')), $port, fs_director::GetCheckboxValue($controller->GetControllerRequest('FORM', 'vh_portforward_in')), $ip, $controller->GetControllerRequest('FORM', 'vh_custom_tx'), $controller->GetControllerRequest('FORM', 'vh_id_pk')));
     self::SetWriteApacheConfigTrue();
     self::$ok = true;
     return true;
 }
开发者ID:bbspike,项目名称:sentora-core,代码行数:23,代码来源:controller.ext.php


示例9: doUpdateClient

 static function doUpdateClient()
 {
     global $controller;
     runtime_csfr::Protect();
     $currentuser = ctrl_users::GetUserDetail();
     $formvars = $controller->GetAllControllerRequests('FORM');
     if (self::ExecuteUpdateClient($formvars['inClientID'], $formvars['inPackage'], $formvars['inEnabled'], $formvars['inGroup'], $formvars['inFullName'], $formvars['inEmailAddress'], $formvars['inAddress'], $formvars['inPostCode'], $formvars['inPhone'], $formvars['inNewPassword'])) {
         return true;
     }
     return false;
 }
开发者ID:Boter,项目名称:madmin-core,代码行数:11,代码来源:controller.ext.php


示例10: doDeleteCron

 static function doDeleteCron()
 {
     global $zdbh;
     global $controller;
     runtime_csfr::Protect();
     $currentuser = ctrl_users::GetUserDetail();
     $sql = "SELECT COUNT(*) FROM x_cronjobs WHERE ct_acc_fk=:userid AND ct_deleted_ts IS NULL";
     $numrows = $zdbh->prepare($sql);
     $numrows->bindParam(':userid', $currentuser['userid']);
     if ($numrows->execute()) {
         if ($numrows->fetchColumn() != 0) {
             $sql = $zdbh->prepare("SELECT * FROM x_cronjobs WHERE ct_acc_fk=:userid AND ct_deleted_ts IS NULL");
             $sql->bindParam(':userid', $currentuser['userid']);
             $sql->execute();
             while ($rowcrons = $sql->fetch()) {
                 if (!fs_director::CheckForEmptyValue($controller->GetControllerRequest('FORM', 'inDelete_' . $rowcrons['ct_id_pk'] . ''))) {
                     $sql2 = $zdbh->prepare("UPDATE x_cronjobs SET ct_deleted_ts=:time WHERE ct_id_pk=:cronid");
                     $sql2->bindParam(':cronid', $rowcrons['ct_id_pk']);
                     $sql2->bindParam(':time', time());
                     $sql2->execute();
                     (new Cronfile())->writeToFile();
                     self::$ok = TRUE;
                     return;
                 }
             }
         }
     }
     self::$error = TRUE;
     return;
 }
开发者ID:albertkampde,项目名称:sentora-cron-module,代码行数:30,代码来源:controller.ext.php


示例11: doUpdateSettings

 /**
  * Accepts Admin settings form
  * @return null
  */
 static function doUpdateSettings()
 {
     global $controller;
     runtime_csfr::Protect();
     $form = $controller->GetAllControllerRequests('FORM');
     if (!isset($form['inAdminSettings'])) {
         return false;
     }
     ctrl_options::SetSystemOption('whmcs_sendemail_bo', $form['SendEmail']);
     ctrl_options::SetSystemOption('whmcs_link', $form['Link']);
     self::$Results[] = ui_sysmessage::shout('Settings updated!', 'alert-success');
 }
开发者ID:nmsde,项目名称:sentora-whmcs,代码行数:16,代码来源:controller.ext.php


示例12: doUpdateGroup

 static function doUpdateGroup()
 {
     global $controller;
     runtime_csfr::Protect();
     $formvars = $controller->GetAllControllerRequests('FORM');
     if (self::ExectuteUpdateGroup($formvars['inGroupID'], $formvars['inGroupName'], $formvars['inDesc'])) {
         return true;
     }
     return false;
 }
开发者ID:bbspike,项目名称:sentora-core,代码行数:10,代码来源:controller.ext.php


示例13: doAddFaq

 static function doAddFaq()
 {
     global $controller;
     runtime_csfr::Protect();
     $currentuser = ctrl_users::GetUserDetail();
     if (!fs_director::CheckForEmptyValue($controller->GetControllerRequest('FORM', 'inAdd'))) {
         $question = $controller->GetControllerRequest('FORM', 'question');
         $answer = $controller->GetControllerRequest('FORM', 'answer');
         $userid = $currentuser['userid'];
         if ($currentuser['usergroup'] == "Administrators") {
             $global = 1;
         } else {
             $global = 0;
         }
         self::ExecuteAddFaq($question, $answer, $userid, $global);
     }
 }
开发者ID:Boter,项目名称:madmin-core,代码行数:17,代码来源:controller.ext.php


示例14: doDeletePackage

 static function doDeletePackage()
 {
     global $controller;
     runtime_csfr::Protect();
     $formvars = $controller->GetAllControllerRequests('FORM');
     if (self::ExecuteDeletePackage($formvars['inPackageID'], $formvars['inMovePackage'])) {
         return true;
     }
     return false;
 }
开发者ID:Boter,项目名称:madmin-core,代码行数:10,代码来源:controller.ext.php


示例15: doDeleteUser

 static function doDeleteUser()
 {
     global $controller;
     runtime_csfr::Protect();
     $id = self::getId();
     $userId = self::getUserId();
     $file = self::fetchFile($id);
     if (!self::hasFlashErrors()) {
         self::deleteUser($userId);
     }
     if (!self::hasFlashErrors()) {
         self::deleteMapper($id, $userId);
     }
     if (!self::hasFlashErrors()) {
         self::writePasswdUsers($file);
     }
     if (!self::hasFlashErrors()) {
         header("location: ./?module=" . $controller->GetCurrentModule() . "&control=EditProtection&id=" . $id);
     }
 }
开发者ID:bbspike,项目名称:sentora-core,代码行数:20,代码来源:controller.ext.php


示例16: doAddDistList

 static function doAddDistList()
 {
     global $controller;
     runtime_csfr::Protect();
     $currentuser = ctrl_users::GetUserDetail();
     $formvars = $controller->GetAllControllerRequests('FORM');
     return self::ExecuteAddDistList($currentuser['userid'], $formvars['inAddress'], $formvars['inDomain']);
 }
开发者ID:caglaroflazoglu,项目名称:sentora-core,代码行数:8,代码来源:controller.ext.php


示例17: doConfirmDeleteDomain

 static function doConfirmDeleteDomain()
 {
     global $controller;
     runtime_csfr::Protect();
     $currentuser = ctrl_users::GetUserDetail();
     $formvars = $controller->GetAllControllerRequests('FORM');
     foreach (self::ListDomains($currentuser['userid']) as $row) {
         if (isset($formvars['inDelete_' . $row['id'] . ''])) {
             header("location: ./?module=" . $controller->GetCurrentModule() . "&show=Delete&id=" . $row['id'] . "&domain=" . $row['name'] . "");
             exit;
         }
     }
     return false;
 }
开发者ID:bbspike,项目名称:sentora-core,代码行数:14,代码来源:controller.ext.php


示例18: doDeleteBackup

 static function doDeleteBackup()
 {
     global $zdbh;
     global $controller;
     runtime_csfr::Protect();
     $currentuser = ctrl_users::GetUserDetail();
     $userid = $currentuser['userid'];
     $username = $currentuser['username'];
     $files = self::ListBackUps($userid);
     //print_r($_POST);
     foreach ($files as $file) {
         if (!fs_director::CheckForEmptyValue($controller->GetControllerRequest('FORM', 'inDelete_' . $file['backupfile'] . '')) || !fs_director::CheckForEmptyValue($controller->GetControllerRequest('FORM', 'inDelete_' . $file['backupfile'] . '_x')) || !fs_director::CheckForEmptyValue($controller->GetControllerRequest('FORM', 'inDelete_' . $file['backupfile'] . '_y'))) {
             self::ExecuteDeleteBackup($username, $file['backupfile']);
             self::$deleteok = true;
         }
     }
 }
开发者ID:bbspike,项目名称:sentora-core,代码行数:17,代码来源:controller.ext.php


示例19: doConfirmDeleteForwarder

 static function doConfirmDeleteForwarder()
 {
     global $controller;
     runtime_csfr::Protect();
     $formvars = $controller->GetAllControllerRequests('FORM');
     return self::ExecuteDeleteForwarder($formvars['inDelete']);
 }
开发者ID:TGates71,项目名称:Sentora-Windows-Upgrade,代码行数:7,代码来源:controller.ext.php


示例20: doForceDaemon

 static function doForceDaemon()
 {
     global $zdbh;
     global $controller;
     runtime_csfr::Protect();
     $formvars = $controller->GetAllControllerRequests('FORM');
     if (isset($formvars['inForceFull'])) {
         $sql = $zdbh->prepare("UPDATE x_settings set so_value_tx = '0' WHERE so_name_vc = 'daemon_lastrun'");
         $sql->execute();
         $sql = $zdbh->prepare("UPDATE x_settings set so_value_tx = '0' WHERE so_name_vc = 'daemon_dayrun'");
         $sql->execute();
         $sql = $zdbh->prepare("UPDATE x_settings set so_value_tx = '0' WHERE so_name_vc = 'daemon_weekrun'");
         $sql->execute();
         $sql = $zdbh->prepare("UPDATE x_settings set so_value_tx = '0' WHERE so_name_vc = 'daemon_monthrun'");
         $sql->execute();
     }
     self::$ok = true;
 }
开发者ID:remzicelik,项目名称:sentora-core,代码行数:18,代码来源:controller.ext.php



注:本文中的runtime_csfr类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
PHP runtime_hook类代码示例发布时间:2022-05-23
下一篇:
PHP runner类代码示例发布时间:2022-05-23
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap