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


PHP Piwik::getRandomTitle方法代碼示例

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


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

示例1: configureView

 /**
  * This is just a copy-paste of the parent's member.
  * It's sole reason for existence here is the fact that the parent has it
  * defined as "private". See https://github.com/piwik/piwik/pull/8681 for
  * information.
  *
  * @param View $view
  */
 protected function configureView($view)
 {
     $this->setBasicVariablesView($view);
     $view->linkTitle = Piwik::getRandomTitle();
     // crsf token: don't trust the submitted value; generate/fetch it from session data
     $view->nonce = Nonce::getNonce('Login.login');
 }
開發者ID:Joey3000,項目名稱:piwik-LoginEncrypted,代碼行數:15,代碼來源:Controller.php

示例2: handleMaintenanceMode

 protected function handleMaintenanceMode()
 {
     if (Config::getInstance()->General['maintenance_mode'] != 1 || Common::isPhpCliMode()) {
         return;
     }
     Common::sendResponseCode(503);
     $logoUrl = null;
     $faviconUrl = null;
     try {
         $logo = new CustomLogo();
         $logoUrl = $logo->getHeaderLogoUrl();
         $faviconUrl = $logo->getPathUserFavicon();
     } catch (Exception $ex) {
     }
     $logoUrl = $logoUrl ?: 'plugins/Morpheus/images/logo-header.png';
     $faviconUrl = $faviconUrl ?: 'plugins/CoreHome/images/favicon.ico';
     $page = file_get_contents(PIWIK_INCLUDE_PATH . '/plugins/Morpheus/templates/maintenance.tpl');
     $page = str_replace('%logoUrl%', $logoUrl, $page);
     $page = str_replace('%faviconUrl%', $faviconUrl, $page);
     $page = str_replace('%piwikTitle%', Piwik::getRandomTitle(), $page);
     echo $page;
     exit;
 }
開發者ID:drabberhorizon,項目名稱:ActiveNative,代碼行數:23,代碼來源:FrontController.php

示例3: configureView

 /**
  * Configure common view properties
  *
  * @param View $view
  */
 private function configureView($view)
 {
     $this->setBasicVariablesView($view);
     $view->linkTitle = Piwik::getRandomTitle();
     $view->forceSslLogin = Config::getInstance()->General['force_ssl_login'];
     // crsf token: don't trust the submitted value; generate/fetch it from session data
     $view->nonce = Nonce::getNonce('Login.login');
 }
開發者ID:KiwiJuicer,項目名稱:handball-dachau,代碼行數:13,代碼來源:Controller.php


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