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


PHP GWF_Website類代碼示例

本文整理匯總了PHP中GWF_Website的典型用法代碼示例。如果您正苦於以下問題:PHP GWF_Website類的具體用法?PHP GWF_Website怎麽用?PHP GWF_Website使用的例子?那麽, 這裏精選的類代碼示例或許可以為您提供幫助。


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

示例1: Upgrade_Slaytags_1_01

function Upgrade_Slaytags_1_01(Module_Slaytags $module)
{
    GWF_Website::addDefaultOutput(GWF_HTML::message('Slaytags', "BPM and Key"));
    $songs = GDO::table('Slay_Song');
    $songs->createColumn('ss_bpm');
    $songs->createColumn('ss_key');
}
開發者ID:sinfocol,項目名稱:gwf3,代碼行數:7,代碼來源:Upgrade_Slaytags_1_01.php

示例2: templateEnsemble

 private function templateEnsemble()
 {
     $l = new GWF_LangTrans($this->module->getModuleFilePath('lang/ensemble'));
     GWF_Website::setPageTitle($l->lang('page_title'));
     $tVars = array('title' => $l->lang('title'), 'text' => $l->lang('text'), 'text2' => $l->lang('text2'), 'types' => $l->lang('types'), 'other' => $l->lang('other'), 't1' => $l->lang('t1'), 't2' => $l->lang('t2'), 'altimg1' => $l->lang('altimg1'), 'altimg2' => $l->lang('altimg2'));
     return $this->module->template('ensemble.tpl', $tVars);
 }
開發者ID:sinfocol,項目名稱:gwf3,代碼行數:7,代碼來源:Ensemble.php

示例3: templateBiography

 private function templateBiography()
 {
     $l = new GWF_LangTrans($this->module->getModuleFilePath('lang/biography'));
     GWF_Website::setPageTitle($l->lang('page_title'));
     $tVars = array('title' => $l->lang('title'), 'name' => $l->lang('name'), 'sopran' => $l->lang('sopran'), 'text' => $l->lang('text'), 't1' => $l->lang('t1'), 'altimg' => $l->lang('t1'));
     return $this->module->template('biography.tpl', $tVars);
 }
開發者ID:sinfocol,項目名稱:gwf3,代碼行數:7,代碼來源:Biography.php

示例4: templateAdd

 private function templateAdd()
 {
     GWF_Website::setPageTitle($this->module->lang('ft_add'));
     $form = $this->getForm();
     $tVars = array('preview' => '', 'form' => $form->templateY($this->module->lang('ft_add')));
     return $this->module->templatePHP('add.php', $tVars);
 }
開發者ID:sinfocol,項目名稱:gwf3,代碼行數:7,代碼來源:Add.php

示例5: execute

 public function execute()
 {
     if (false !== ($error = $this->sanitize())) {
         return $error;
     }
     $nav = $this->module->templateNav();
     $back = '';
     # Enable
     if (false !== Common::getPost('enable')) {
         $back .= $this->onEnable('enabled');
     } elseif (false !== Common::getPost('disable')) {
         $back .= $this->onEnable('disabled');
     } elseif (false !== Common::getPost('defaults')) {
         $back .= $this->onDefaults();
     } elseif (false !== Common::getPost('update')) {
         $back .= $this->onUpdate();
     } elseif (false !== Common::getPost('admin_sect')) {
         if ($this->mod->hasAdminSection()) {
             GWF_Website::redirect($this->mod->getAdminSectionURL());
             return '';
         } else {
             $back .= $this->module->error('err_no_admin_sect');
         }
     }
     # Form
     return $nav . $back . $this->templateModule();
 }
開發者ID:sinfocol,項目名稱:gwf3,代碼行數:27,代碼來源:Module.php

示例6: execute

 public function execute()
 {
     GWF_Website::plaintext();
     $input = trim(Common::getGetString('username', ''));
     if (false !== ($onsitename = Common::getGet('onsitename')) && false !== ($sitename = Common::getGet('sitename'))) {
         die($this->rawOnSiteStats($sitename, $onsitename));
     }
     require_once GWF_CORE_PATH . 'module/WeChall/WC_RegAt.php';
     if (Common::getGet('wechall') === 'yes') {
         die($this->wechallChalls($input));
     }
     if ($input === '') {
         $message = sprintf('Try %s?username=name/rank. New: ?username=!sitename username/rank. Or: ?username=!sites usernname', 'wechall.php');
         die($message);
     }
     if (strpos($input, '!sites') === 0) {
         $this->showSites($input);
     } elseif (strpos($input, '!site') === 0) {
         $this->showSiteDetail($input);
     } elseif (strpos($input, '!') === 0) {
         $this->showSite($input);
     } else {
         die($this->showGlobal($input));
     }
 }
開發者ID:sinfocol,項目名稱:gwf3,代碼行數:25,代碼來源:API_Bot.php

示例7: templateArrangements

 private function templateArrangements()
 {
     $l = new GWF_LangTrans($this->module->getModuleFilePath('lang/arrangements'));
     GWF_Website::setPageTitle($l->lang('page_title'));
     $tVars = array('title' => $l->lang('title'), 'h1' => $l->lang('h1'), 't1' => $l->lang('t1'), 'h2' => $l->lang('h2'), 't2' => $l->lang('t2'), 'h3' => $l->lang('h3'), 't3' => $l->lang('t3'), 'title2' => $l->lang('title2'), 'text2' => $l->lang('text2'));
     return $this->module->template('arrangements.tpl', $tVars);
 }
開發者ID:sinfocol,項目名稱:gwf3,代碼行數:7,代碼來源:Arrangements.php

示例8: templatePresse

 private function templatePresse()
 {
     $l = new GWF_LangTrans($this->module->getModuleFilePath('lang/presse'));
     GWF_Website::setPageTitle($l->lang('page_title'));
     $tVars = array('title' => $l->lang('title'), 'subtitle' => $l->lang('subtitle'), 'text' => $l->lang('text'), 'altimg' => $l->lang('altimg'), 't1' => $l->lang('t1'), 't2' => $l->lang('t2'), 't3' => $l->lang('t3'), 't4' => $l->lang('t4'), 't5' => $l->lang('t5'));
     return $this->module->template('presse.tpl', $tVars);
 }
開發者ID:sinfocol,項目名稱:gwf3,代碼行數:7,代碼來源:Presse.php

示例9: execute

 public function execute()
 {
     GWF_Website::setPageTitle($this->module->lang('pt_scorefaq'));
     GWF_Website::setMetaTags($this->module->lang('mt_scorefaq'));
     $tVars = array('scoring' => new GWF_LangTrans(GWF_CORE_PATH . 'module/WeChall/lang/scoring/_wc_scoring'));
     return $this->module->templatePHP('scoring_faq.php', $tVars);
 }
開發者ID:sinfocol,項目名稱:gwf3,代碼行數:7,代碼來源:ScoringFAQ.php

示例10: templateLicense

 private function templateLicense()
 {
     $lang = new GWF_LangTrans(GWF_CORE_PATH . 'module/WeChall/lang/tos/_wc_tos');
     GWF_Website::setPageTitle($lang->lang('pt_license'));
     $tVars = array('license' => $lang);
     return $this->module->templatePHP('license.php', $tVars);
 }
開發者ID:sinfocol,項目名稱:gwf3,代碼行數:7,代碼來源:License.php

示例11: execute

 public function execute()
 {
     GWF_Website::plaintext();
     GWF3::setConfig('store_last_url', false);
     $lat = $this->module->lat();
     $lon = $this->module->lon();
     $descr = trim(Common::getGetString('pp_descr'));
     $descr = $descr === '' ? null : $descr;
     $id = Common::getGetInt('pp_id', 0);
     $user = GWF_User::getStaticOrGuest();
     $uid = $user->getID();
     if (!GWF_ProfilePOI::changeAllowed($id, $uid)) {
         $this->module->ajaxError('Permission error!');
     }
     $count = $id === 0 ? GWF_ProfilePOI::getPOICount($uid) : 0;
     $max_pois = $this->module->cfgAllowedPOIs();
     if ($count >= $max_pois) {
         $this->module->ajaxErr('err_poi_exceed');
     }
     $poi = new GWF_ProfilePOI(array('pp_id' => $id, 'pp_uid' => $uid, 'pp_lat' => $lat, 'pp_lon' => $lon, 'pp_descr' => $descr));
     $poi->replace();
     $data = $poi->getGDOData();
     $data['user_name'] = $user->getVar('user_name');
     die(json_encode($data));
 }
開發者ID:sinfocol,項目名稱:gwf3,代碼行數:25,代碼來源:POISAdd.php

示例12: onRegister

 private function onRegister()
 {
     $form = $this->getForm();
     $errorsA = $errorsB = '';
     if (false !== ($errorsA = $form->validate($this->module)) || false !== ($errorsB = $this->onRegisterB())) {
         return $errorsA . $errorsB . $this->templateForm();
     }
     $username = Common::getPost('username');
     $password = Common::getPost('password');
     $email = Common::getPost('email');
     $birthdate = sprintf('%04d%02d%02d', Common::getPost('birthdatey'), Common::getPost('birthdatem'), Common::getPost('birthdated'));
     $default_country = $this->module->cfgDetectCountry() ? GWF_IP2Country::detectCountryID() : 0;
     $countryid = $form->getVar('countryid', $default_country);
     require_once GWF_CORE_PATH . 'module/Register/GWF_UserActivation.php';
     $token = GWF_UserActivation::generateToken();
     $ua = new GWF_UserActivation(array('username' => $username, 'email' => $email, 'token' => $token, 'birthdate' => $birthdate, 'countryid' => $countryid, 'password' => GWF_Password::hashPasswordS($password), 'timestamp' => time(), 'ip' => GWF_IP6::getIP(GWF_IP_EXACT)));
     if (false === $ua->insert()) {
         return GWF_HTML::err('ERR_DATABASE', array(__FILE__, __LINE__)) . $this->templateForm();
     }
     if ($this->module->wantEmailActivation()) {
         return $this->sendEmail($username, $email, $token, $password);
     } else {
         GWF_Website::redirect(GWF_WEB_ROOT . 'quick_activate/' . $token);
     }
     return $this->module->message('msg_registered');
 }
開發者ID:sinfocol,項目名稱:gwf3,代碼行數:26,代碼來源:Form.php

示例13: execute

 public function execute()
 {
     if (false !== ($state = Common::getGet('rightpanel'))) {
         GWF_Session::set('WC_RIGHT_PANEL', $state > 0);
         GWF_Website::redirectBack();
     }
 }
開發者ID:sinfocol,項目名稱:gwf3,代碼行數:7,代碼來源:Sidebar2.php

示例14: display

 public static function display()
 {
     $y1 = substr(GWF_Website::getBirthdate(), 0, 4);
     $y2 = date('Y');
     $years = $y1 === $y2 ? $y1 : "{$y1}-{$y2}";
     return GWF_HTML::lang('copy', array($years));
 }
開發者ID:sinfocol,項目名稱:gwf3,代碼行數:7,代碼來源:GWF_Copyright.php

示例15: __construct

 public function __construct($basepath = NULL, array $config = array())
 {
     self::init($basepath);
     self::onDefineWebRoot();
     GWF_Language::initEnglish();
     GWF_Website::init(false);
 }
開發者ID:sinfocol,項目名稱:gwf3,代碼行數:7,代碼來源:GWF3.php


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