當前位置: 首頁>>代碼示例>>PHP>>正文


PHP tform_actions::onShowNew方法代碼示例

本文整理匯總了PHP中tform_actions::onShowNew方法的典型用法代碼示例。如果您正苦於以下問題:PHP tform_actions::onShowNew方法的具體用法?PHP tform_actions::onShowNew怎麽用?PHP tform_actions::onShowNew使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在tform_actions的用法示例。


在下文中一共展示了tform_actions::onShowNew方法的6個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。

示例1: onShowNew

 function onShowNew()
 {
     global $app, $conf, $wb;
     // Only admins can add domains, so we don't need any check
     $app->tpl->setVar($wb);
     parent::onShowNew();
 }
開發者ID:falkbizz,項目名稱:ispconfig3,代碼行數:7,代碼來源:domain_edit.php

示例2: onShowNew

 function onShowNew()
 {
     global $app, $conf;
     // we will check only users, not admins
     if ($_SESSION["s"]["user"]["typ"] == 'user') {
         if (!$app->tform->checkClientLimit('limit_web_aliasdomain', "type = 'alias'")) {
             $app->error($app->tform->wordbook["limit_web_aliasdomain_txt"]);
         }
         if (!$app->tform->checkResellerLimit('limit_web_aliasdomain', "type = 'alias'")) {
             $app->error('Reseller: ' . $app->tform->wordbook["limit_web_aliasdomain_txt"]);
         }
     }
     parent::onShowNew();
 }
開發者ID:shoaibali,項目名稱:ispconfig3,代碼行數:14,代碼來源:web_aliasdomain_edit.php

示例3: onShowNew

 function onShowNew()
 {
     global $app, $conf;
     // we will check the limits only when the email address belongs to a client and not the admin
     if ($_SESSION["s"]["user"]["default_group"] > 0) {
         if (!$app->tform->checkClientLimit('limit_mailfilter', "")) {
             $app->error($app->tform->lng("limit_mailfilter_txt"));
         }
         if (!$app->tform->checkResellerLimit('limit_mailfilter', "")) {
             $app->error('Reseller: ' . $app->tform->lng("limit_mailfilter_txt"));
         }
     }
     parent::onShowNew();
 }
開發者ID:shoaibali,項目名稱:ispconfig3,代碼行數:14,代碼來源:mail_user_filter_edit.php

示例4: onShowNew

 function onShowNew()
 {
     global $app, $conf;
     // we will check only users, not admins
     if ($_SESSION["s"]["user"]["typ"] == 'user') {
         if (!$app->tform->checkClientLimit('limit_spamfilter_policy')) {
             $app->error($app->tform->wordbook["limit_spamfilter_policy_txt"]);
         }
         if (!$app->tform->checkResellerLimit('limit_spamfilter_policy')) {
             $app->error('Reseller: ' . $app->tform->wordbook["limit_spamfilter_policy_txt"]);
         }
     }
     parent::onShowNew();
 }
開發者ID:istrwei,項目名稱:ISPCluster,代碼行數:14,代碼來源:spamfilter_policy_edit.php

示例5: onShowNew

 function onShowNew()
 {
     global $app, $conf;
     // we will check only users, not admins
     if ($_SESSION["s"]["user"]["typ"] == 'user') {
         // Get the limits of the client
         $client_group_id = $app->functions->intval($_SESSION["s"]["user"]["default_group"]);
         $client = $app->db->queryOneRecord("SELECT limit_client FROM sys_group, client WHERE sys_group.client_id = client.client_id and sys_group.groupid = {$client_group_id}");
         // Check if the user may add another website.
         if ($client["limit_client"] >= 0) {
             $tmp = $app->db->queryOneRecord("SELECT count(client_id) as number FROM client WHERE sys_groupid = {$client_group_id}");
             if ($tmp["number"] >= $client["limit_client"]) {
                 $app->error($app->tform->wordbook["limit_client_txt"]);
             }
         }
     }
     parent::onShowNew();
 }
開發者ID:istrwei,項目名稱:ISPCluster,代碼行數:18,代碼來源:client_edit.php

示例6: onShowNew

 function onShowNew()
 {
     global $app, $conf;
     // we will check only users, not admins
     if ($_SESSION["s"]["user"]["typ"] == 'user') {
         if (!$app->tform->checkClientLimit('limit_web_domain', "type = 'vhost'")) {
             $app->error($app->tform->wordbook["limit_web_domain_txt"]);
         }
         if (!$app->tform->checkResellerLimit('limit_web_domain', "type = 'vhost'")) {
             $app->error('Reseller: ' . $app->tform->wordbook["limit_web_domain_txt"]);
         }
         // Get the limits of the client
         $client_group_id = $app->functions->intval($_SESSION["s"]["user"]["default_group"]);
         $client = $app->db->queryOneRecord("SELECT client.default_webserver FROM sys_group, client WHERE sys_group.client_id = client.client_id and sys_group.groupid = {$client_group_id}");
         $app->tpl->setVar("server_id_value", $client['default_webserver']);
     }
     $app->tform->formDef['tabs']['domain']['readonly'] = false;
     parent::onShowNew();
 }
開發者ID:istrwei,項目名稱:ISPCluster,代碼行數:19,代碼來源:web_domain_edit.php


注:本文中的tform_actions::onShowNew方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。