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


PHP Templates::displayPage方法代碼示例

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


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

示例1:

// used in the settings page
$pageParams["allCountryPlugins"] = Core::$countryPlugins;
$pageParams["allExportTypes"] = $exportTypes;
$pageParams["groupedDataTypes"] = Core::$dataTypePlugins;
$pageParams["allDataTypes"] = $dataTypes;
$pageParams["allTranslations"] = Core::$translations->getList();
$useMinifiedResources = Core::isUsingMinifiedResources();
$pageParams["useMinifiedResources"] = $useMinifiedResources;
if ($useMinifiedResources) {
    $pageParams["minifiedResourcePaths"] = Minification::getMinifiedResourcePaths();
}
$pageParams["dataTypeJSModules"] = $dataTypeJSModules;
$pageParams["exportTypeJSModules"] = $exportTypeJSModules;
$pageParams["exportTypeAdditionalSettings"] = $exportTypeAdditionalSettings;
$pageParams["settings"] = $settings;
$pageParams["cssIncludes"] = $cssIncludes;
$pageParams["codeMirrorIncludes"] = ExportTypePluginHelper::getExportTypeCodeMirrorModes($exportTypes);
$pageParams["defaultExportType"] = Core::$user->getDefaultExportType();
$pageParams["defaultNumRows"] = Core::getDefaultNumRows();
if (Core::checkIsLoggedIn()) {
    $pageParams["isLoggedIn"] = true;
    $pageParams["accountType"] = Core::$user->getAccountType();
    $pageParams["selectedDataTypes"] = Core::$user->getSelectedDataTypes();
    $pageParams["selectedExportTypes"] = Core::$user->getSelectedExportTypes();
    $pageParams["selectedCountries"] = Core::$user->getSelectedCountries();
} else {
    $pageParams["isLoggedIn"] = false;
    $pageParams["accountType"] = "";
}
Templates::displayPage("resources/templates/index.tpl", $pageParams);
開發者ID:CicadaMikoto,項目名稱:generatedata,代碼行數:30,代碼來源:index.php

示例2: header

<?php

require_once "library.php";
Core::init();
// if need be, redirect to the install instructions page
Utils::maybeShowInstallationPage();
if (Core::checkIsLoggedIn()) {
    header("location: ./");
    exit;
}
$pageParams = array();
Templates::displayPage("resources/templates/login.tpl", $pageParams);
開發者ID:GrimDerp,項目名稱:vagrant-synthetic-data-machine,代碼行數:12,代碼來源:login.php

示例3: header

<?php

require_once "library.php";
Core::init("installation");
// if the script is already installed, redirect them to the index page.
if (Core::checkIsInstalled()) {
    header("location: index.php");
    exit;
}
$currentPage = 1;
if (Core::checkSettingsFileExists()) {
    $currentPage = 3;
    if (Settings::getSetting("installationStepComplete_Core") == "yes") {
        $currentPage = 4;
    }
}
$params = array();
$params["theme"] = Core::getDefaultTheme();
$params["randomPassword"] = Utils::generateRandomAlphanumericStr("CVxxCxV");
$params["tablePrefix"] = Core::getDbTablePrefix();
$params["currentPage"] = $currentPage;
Templates::displayPage("resources/templates/install.tpl", $params);
開發者ID:mdb-webdev,項目名稱:generatedata,代碼行數:22,代碼來源:install.php

示例4: evalSmartyTemplate

 /**
  * Helper function for use by any of the modules (or Core). It lets
  * @param string $template the template (.tpl file) and path from the Generate Data root.
  * @param array $placeholders
  * @return string
  */
 public static function evalSmartyTemplate($template, $placeholders)
 {
     return Templates::displayPage($template, $placeholders, "return");
 }
開發者ID:JaeHoYun,項目名稱:generatedata,代碼行數:10,代碼來源:Templates.class.php


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