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'); }
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); }
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); }
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); }
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(); }
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)); } }
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); }
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); }
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); }
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); }
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)); }
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'); }
public function execute() { if (false !== ($state = Common::getGet('rightpanel'))) { GWF_Session::set('WC_RIGHT_PANEL', $state > 0); GWF_Website::redirectBack(); } }
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)); }
public function __construct($basepath = NULL, array $config = array()) { self::init($basepath); self::onDefineWebRoot(); GWF_Language::initEnglish(); GWF_Website::init(false); }
private function templateRepertoire() { $l = new GWF_LangTrans($this->module->getModuleFilePath('lang/repertoire')); GWF_Website::setPageTitle($l->lang('page_title')); $tVars = array('text' => $l->lang('text'), 'rep' => $l->lang('repertoire'), 't1' => $l->lang('t1'), 'altimg' => $l->lang('altimg')); return $this->module->template('repertoire.tpl', $tVars); }
private function templateSponsoren() { $l = new GWF_LangTrans($this->module->getModuleFilePath('lang/sponsoren')); GWF_Website::setPageTitle($l->lang('page_title')); $tVars = array('title' => $l->lang('title'), 'subtitle' => $l->lang('subtitle')); return $this->module->template('sponsoren.tpl', $tVars); }
public function execute() { if (false === ($page = GWF_Page::getByID(Common::getGetString('pageid')))) { return $this->module->error('err_page'); } $user = GWF_User::getStaticOrGuest(); $this->is_author = $this->module->isAuthor($user); $this->is_owner = $this->is_author || $page->isOwner($user); if (!$this->is_owner && !$this->is_author) { return GWF_HTML::err('ERR_NO_PERMISSION'); } $this->page = $page; $this->user = $user; $this->is_oowner = $this->is_author ? true : $page->getOtherPage()->isOwner($user); $back = ''; if (isset($_POST['edit'])) { $back .= $this->onEdit(); } elseif (isset($_POST['unlock'])) { return $this->onUnlock() . $this->templateEdit(); } elseif (isset($_POST['delete'])) { return $this->onDelete() . $this->templateEdit(); } elseif (isset($_POST['translate'])) { GWF_Website::redirect($this->module->getMethodURL('Translate', '&pageid=' . $page->getID())); die; } elseif (isset($_POST['upload'])) { require_once GWF_CORE_PATH . 'module/PageBuilder/PB_Uploader.php'; $back .= PB_Uploader::onUpload($this->module) . $this->templateEdit(); } return $back . $this->templateEdit(); }
private function templateExklusiv() { $l = new GWF_LangTrans($this->module->getModuleFilePath('lang/exklusiv')); GWF_Website::setPageTitle($l->lang('page_title')); $tVars = array('l' => $l); return $this->module->template('exklusiv.tpl', $tVars); }
private function templateAbout() { $l = new GWF_LangTrans($this->module->getModuleFilePath('lang/about_meli')); GWF_Website::setPageTitle($l->lang('page_title')); $tVars = array('l' => $l); return $this->module->template('about_melanie.tpl', $tVars); }
public function onStartup() { self::$instance = $this; $this->onLoadLanguage(); $this->onInclude(); GWF_Website::addMetaTags(',' . $this->lang('mt_main')); GWF_Website::addMetaDescr(' ' . $this->lang('md_main')); }
public function execute() { $user = GWF_User::getStaticOrGuest(); GWF_Website::addJavascriptInline($this->getInlineJS($user)); $tVars = array('worlds' => $this->getWorlds($user)); GWF3::setDesign('jqmsl4'); return $this->module->template('shadowclient.tpl', $tVars); }
public function templateReplay(GWF_AuditLog $log) { GWF_Website::addJavascriptInline('var al_script=' . $log->getAjaxScript() . ';'); GWF_Website::addJavascriptInline('var al_times=' . $log->getAjaxTimes() . ';'); GWF_Website::addJavascriptOnload('alReplay();'); $tVars = array('log' => $log); return $this->module->template('replay.tpl', $tVars); }
public function onStartup() { $this->onLoadLanguage(); GWF_Website::addJavascript(GWF_WEB_ROOT . 'tpl/konz/js/konzert.js?v=5'); GWF_Website::addJavascriptOnload('initKonzert();'); GWF_Website::setMetaTags($this->lang('meta_tags')); GWF_Website::setMetaDescr($this->lang('meta_descr')); }
public function templateSearch(array $matches, $term) { GWF_Website::setPageTitle($this->module->lang('pt_search')); GWF_Website::setMetaTags($this->module->lang('mt_search')); GWF_Website::setMetaDescr($this->module->lang('md_search')); $tVars = array('cloud' => $this->module->templateCloud(), 'matches' => $this->module->templateLinks($matches, '#', '', ''), 'form' => $this->templateQuickSearch(), 'term' => $term); return $this->module->templatePHP('search.php', $tVars); }
public function execute() { $lang = new GWF_LangTrans(GWF_CORE_PATH . 'module/WeChall/lang/about/_wc_about'); GWF_Website::setPageTitle($lang->lang('about_pagetitle')); GWF_Website::setMetaTags($lang->lang('about_meta')); $tVars = array('about_08' => $lang->lang('about_08')); return $this->module->template('about.tpl', $tVars); }
public function execute() { GWF_Website::setPageTitle($this->module->lang('pt_main')); // GWF_Website::setMetaTags($this->module->lang('mt_main')); // GWF_Website::setMetaDescr($this->module->lang('md_main')); $tVars = array(); return $this->module->templatePHP('main.php', $tVars); }
public function execute() { GWF_Website::addJavascript(GWF_WEB_ROOT . 'js/jq/color.js'); GWF_Website::addJavascript(GWF_WEB_ROOT . 'js/jq/ghostwriter.js'); GWF_Website::addJavascriptOnload('initGhostwriter();'); GWF_Website::setPageTitle($this->module->lang('page_title')); $this->module->setNextHREF(GWF_WEB_ROOT . 'melanie_gobbo.html'); return $this->templateIntro(); }
function html_head($title = "WeChall", $withSidebar = false, $strict = true, $scripts = array(), $xhtml = true, $css = array()) { GWF_Website::setPageTitle($title); WC_HTML::$LEFT_PANEL = $withSidebar; WC_HTML::$RIGHT_PANEL = $withSidebar; foreach ($css as $path) { GWF_Website::addCSS($path); } }
public function execute() { GWF_Website::setPageTitle($this->module->lang('page_title')); GWF_Website::setMetaTags($this->module->lang('page_meta')); if (false !== Common::getPost('contact')) { return $this->onSend(); } return $this->templateForm(); }