当前位置: 首页>>代码示例>>PHP>>正文


PHP WCFACP类代码示例

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


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

示例1: show

 /**
  * @see Page::show()
  */
 public function show()
 {
     // enable menu item
     WCFACP::getMenu()->setActiveMenuItem('wcf.acp.menu.link.admintools.spider');
     // show page
     parent::show();
 }
开发者ID:Maggan22,项目名称:wbb3addons,代码行数:10,代码来源:AdminToolsSpiderListPage.class.php

示例2: show

 /**
  * @see Page::show()
  */
 public function show()
 {
     // enable menu item
     WCFACP::getMenu()->setActiveMenuItem('wot.acp.menu.link.game.fleet.search');
     $this->readCache();
     parent::show();
 }
开发者ID:sonicmaster,项目名称:RPG,代码行数:10,代码来源:FleetSearchForm.class.php

示例3: execute

 /**
  * @see Action::execute()
  */
 public function execute()
 {
     AbstractAction::execute();
     // check permission
     WCF::getUser()->checkPermission('admin.user.canBanUser');
     if (count($this->userIDs) > 0) {
         // check permission
         $sql = "SELECT\tDISTINCT groupID\n\t\t\t\tFROM\twcf" . WCF_N . "_user_to_groups\n\t\t\t\tWHERE\tuserID IN (" . implode(',', $this->userIDs) . ")";
         $result = WCF::getDB()->sendQuery($sql);
         while ($row = WCF::getDB()->fetchArray($result)) {
             if (!Group::isAccessibleGroup($row['groupID'])) {
                 throw new PermissionDeniedException();
             }
         }
         // update user
         $sql = "UPDATE\twcf" . WCF_N . "_user\n\t\t\t\tSET\tbanned = 0\n\t\t\t\tWHERE\tuserID IN (" . implode(',', $this->userIDs) . ")";
         WCF::getDB()->sendQuery($sql);
         // unmark users
         UserEditor::unmarkAll();
         // reset sessions
         Session::resetSessions($this->userIDs);
     }
     $this->executed();
     if (!empty($this->url)) {
         HeaderUtil::redirect($this->url);
     } else {
         // set active menu item
         WCFACP::getMenu()->setActiveMenuItem('wcf.acp.menu.link.user.management');
         // show succes message
         WCF::getTPL()->assign('message', 'wcf.acp.user.unban.success');
         WCF::getTPL()->display('success');
     }
     exit;
 }
开发者ID:joaocustodio,项目名称:EmuDevstore-1,代码行数:37,代码来源:UserUnbanAction.class.php

示例4: show

 /**
  * @see Page::show()
  */
 public function show()
 {
     // enable menu item
     WCFACP::getMenu()->setActiveMenuItem('wcf.acp.menu.link.user.rank.view');
     // check permission
     WCF::getUser()->checkPermission(array('admin.user.rank.canEditRank', 'admin.user.rank.canDeleteRank'));
     parent::show();
 }
开发者ID:joaocustodio,项目名称:EmuDevstore-1,代码行数:11,代码来源:UserRankListPage.class.php

示例5: show

 /**
  * @see Page::show()
  */
 public function show()
 {
     // enable menu item
     if (!empty($this->activeMenuItem)) {
         WCFACP::getMenu()->setActiveMenuItem($this->activeMenuItem);
     }
     parent::show();
 }
开发者ID:CaribeSoy,项目名称:contest-wcf,代码行数:11,代码来源:ACPForm.class.php

示例6: show

 /**
  * @see Page::show()
  */
 public function show()
 {
     // enable menu item
     WCFACP::getMenu()->setActiveMenuItem('wcf.acp.menu.link.package.server.view');
     // check permission.
     WCF::getUser()->checkPermission('admin.system.package.canEditServer');
     parent::show();
 }
开发者ID:CaribeSoy,项目名称:contest-wcf,代码行数:11,代码来源:UpdateServerListPage.class.php

示例7: show

 /**
  * @see Page::show()
  */
 public function show()
 {
     // enable menu item
     WCFACP::getMenu()->setActiveMenuItem('wcf.acp.menu.link.style.view');
     // check permission
     WCF::getUser()->checkPermission(array('admin.style.canEditStyle', 'admin.style.canDeleteStyle', 'admin.style.canExportStyle'));
     parent::show();
 }
开发者ID:joaocustodio,项目名称:EmuDevstore-1,代码行数:11,代码来源:StyleListPage.class.php

示例8: show

 /**
  * @see Page::show()
  */
 public function show()
 {
     // set active menu item.
     WCFACP::getMenu()->setActiveMenuItem('wcf.acp.menu.link.admintools.cronjobs');
     // check permission
     WCF::getUser()->checkPermission(array('admin.system.cronjobs.canEditCronjob', 'admin.system.cronjobs.canDeleteCronjob', 'admin.system.cronjobs.canEnableDisableCronjob'));
     SortablePage::show();
 }
开发者ID:Maggan22,项目名称:wbb3addons,代码行数:11,代码来源:AdminToolsCronjobsListPage.class.php

示例9: show

 /**
  * @see Page::show()
  */
 public function show()
 {
     // permission
     WCF::getUser()->checkPermission('admin.system.adminTools.canView');
     // enable menu item
     WCFACP::getMenu()->setActiveMenuItem('wcf.acp.menu.link.adminTools');
     // show page
     parent::show();
 }
开发者ID:Maggan22,项目名称:wbb3addons,代码行数:12,代码来源:AdminToolsLinkPage.class.php

示例10: show

 /**
  * @see Page::show()
  */
 public function show()
 {
     // set active menu item
     WCFACP::getMenu()->setActiveMenuItem('wcf.acp.menu.link.autoupdate');
     // check permission
     WCF::getUser()->checkPermission('admin.system.package.canUpdatePackage');
     // check master password
     WCFACP::checkMasterPassword();
     parent::show();
 }
开发者ID:CaribeSoy,项目名称:contest-wcf,代码行数:13,代码来源:PackageAutoUpdateListPage.class.php

示例11: show

 /**
  * @see	Page::show()
  */
 public function show()
 {
     // check module option
     if (!MODULE_CMSSTATISTICS) {
         throw new IllegalLinkException();
     }
     // enable menu entry
     WCFACP::getMenu()->setActiveMenuItem('wcf.acp.menu.link.content.host.statistics');
     parent::show();
 }
开发者ID:Evil-Co-Legacy,项目名称:Evil-Co.de-CMS,代码行数:13,代码来源:CMSStatisticsPage.class.php

示例12: execute

 /**
  * @see Action::execute()
  */
 public function execute()
 {
     parent::execute();
     // check permission.
     WCF::getUser()->checkPermission('admin.system.package.canEditServer');
     // check master password
     WCFACP::checkMasterPassword();
     // delete server
     $this->updateServer->delete();
     $this->executed();
     // redirect to the view page.
     HeaderUtil::redirect('index.php?page=UpdateServerList&deletedPackageUpdateServerID=' . $this->packageUpdateServerID . "&packageID=" . PACKAGE_ID . SID_ARG_2ND_NOT_ENCODED);
 }
开发者ID:CaribeSoy,项目名称:contest-wcf,代码行数:16,代码来源:UpdateServerDeleteAction.class.php

示例13: execute

 /**
  * @see Action::execute()
  */
 public function execute()
 {
     parent::execute();
     // check permission
     WCF::getUser()->checkPermission('admin.user.canDeleteGroup');
     require_once WCF_DIR . 'lib/data/user/group/GroupEditor.class.php';
     if ($this->groupID !== 0) {
         $this->groupIDs[] = $this->groupID;
     }
     // check permission
     if (!Group::isAccessibleGroup($this->groupIDs)) {
         throw new PermissionDeniedException();
     }
     // check master password
     WCFACP::checkMasterPassword();
     $deletedGroups = GroupEditor::deleteGroups($this->groupIDs);
     $this->executed();
     HeaderUtil::redirect('index.php?page=GroupList&deletedGroups=' . $deletedGroups . '&packageID=' . PACKAGE_ID . SID_ARG_2ND_NOT_ENCODED);
     exit;
 }
开发者ID:CaribeSoy,项目名称:contest-wcf,代码行数:23,代码来源:GroupDeleteAction.class.php

示例14: show

 /**
  * @see Page::show()
  */
 public function show()
 {
     $wcfPackageID = WCFACP::getWcfPackageID();
     // check package installation queue
     if ($wcfPackageID == 0) {
         PackageInstallationQueue::checkPackageInstallationQueue();
     }
     if (WCFACP::getWcfPackageID() == PACKAGE_ID) {
         $packages = WCF::getCache()->get('packages');
         foreach ($packages as $packageID => $package) {
             break;
         }
         if (isset($packageID) && $packageID != PACKAGE_ID) {
             HeaderUtil::redirect('../' . $packages[$packageID]['packageDir'] . 'acp/index.php' . SID_ARG_1ST, false);
             exit;
         }
     }
     // show page
     parent::show();
 }
开发者ID:CaribeSoy,项目名称:contest-wcf,代码行数:23,代码来源:IndexPage.class.php

示例15: execute

 /**
  * @see Action::execute()
  */
 public function execute()
 {
     AbstractAction::execute();
     // check permission
     WCF::getUser()->checkPermission('admin.user.canEnableUser');
     if (count($this->userIDs) > 0) {
         // check permission
         $sql = "SELECT\tDISTINCT groupID\n\t\t\t\tFROM\twcf" . WCF_N . "_user_to_groups\n\t\t\t\tWHERE\tuserID IN (" . implode(',', $this->userIDs) . ")";
         $result = WCF::getDB()->sendQuery($sql);
         while ($row = WCF::getDB()->fetchArray($result)) {
             if (!Group::isAccessibleGroup($row['groupID'])) {
                 throw new PermissionDeniedException();
             }
         }
         // update groups
         $sql = "DELETE FROM\twcf" . WCF_N . "_user_to_groups\n\t\t\t\tWHERE\t\tuserID IN (" . implode(',', $this->userIDs) . ")\n\t\t\t\t\t\tAND groupID <> " . Group::getGroupIdByType(Group::EVERYONE);
         WCF::getDB()->sendQuery($sql);
         $sql = "INSERT IGNORE INTO\twcf" . WCF_N . "_user_to_groups\n\t\t\t\t\t\t\t(userID, groupID)\n\t\t\t\tVALUES\t\t\t(" . implode(', ' . Group::getGroupIdByType(Group::GUESTS) . '),(', $this->userIDs) . ", '" . Group::getGroupIdByType(Group::GUESTS) . "')";
         WCF::getDB()->sendQuery($sql);
         // update activation code
         foreach ($this->userIDs as $userID) {
             $sql = "UPDATE\twcf" . WCF_N . "_user\n\t\t\t\t\tSET\tactivationCode = " . UserRegistrationUtil::getActivationCode() . "\n\t\t\t\t\tWHERE\tuserID = " . $userID;
             WCF::getDB()->sendQuery($sql);
         }
         // unmark users
         UserEditor::unmarkAll();
         // reset sessions
         Session::resetSessions($this->userIDs);
     }
     $this->executed();
     if (!empty($this->url)) {
         HeaderUtil::redirect($this->url);
     } else {
         // set active menu item
         WCFACP::getMenu()->setActiveMenuItem('wcf.acp.menu.link.user.management');
         // show succes message
         WCF::getTPL()->assign('message', 'wcf.acp.user.disable.success');
         WCF::getTPL()->display('success');
     }
     exit;
 }
开发者ID:joaocustodio,项目名称:EmuDevstore-1,代码行数:44,代码来源:UserDisableAction.class.php


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