本文整理汇总了PHP中view::loadTemplate方法的典型用法代码示例。如果您正苦于以下问题:PHP view::loadTemplate方法的具体用法?PHP view::loadTemplate怎么用?PHP view::loadTemplate使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类view
的用法示例。
在下文中一共展示了view::loadTemplate方法的6个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: getTools
/**
* Return Tools-Page as HTML-View (only Logout)
*/
public function getTools()
{
require 'classes/view.php';
$view = new view();
$view->setTemplate('admin/tools');
return $view->loadTemplate(new stdClass());
}
示例2: getMain
/**
* Return Highscore-Page as HTML-View
*/
public function getMain()
{
require_once 'classes/person.php';
require_once 'classes/view.php';
person::startSession();
$view = new view();
return $view->loadTemplate($this->getModel());
}
示例3: getMain
/**
* Returns Login-Page as HTML-View
* @param unknown_type $succesLocation
*/
public function getMain($succesLocation = '')
{
require 'classes/view.php';
$view = new view();
$view->setTemplate('login');
$model = new stdClass();
$model->submitUrl = 'Admin';
return $view->loadTemplate($model);
}
示例4: getMain
/**
* Return Kategorien-Page as HTML-View
*/
public function getMain()
{
require 'classes/SQL.php';
require 'classes/view.php';
$model = new stdClass();
$model->template = 'admin/KategorieTable';
$sql = new SQL();
$sql->connect();
$model->data = $sql->get("SELECT * FROM quizCategories");
$view = new view();
return $view->loadTemplate($model);
}
示例5: getQuestionTable
/**
* Return QuestionTable-Page as HTML-View
* parameters = POST: CategorieID
*/
public function getQuestionTable()
{
require 'classes/SQL.php';
require 'classes/view.php';
$categorie = htmlentities($_POST['katID']);
$model = new stdClass();
$model->template = 'admin/QuestionTable';
$sql = new SQL();
$sql->connect();
$model->data = $sql->get("SELECT * FROM ViewQuestionQuote WHERE categorie='" . $categorie . "' ORDER BY question");
$view = new view();
return $view->loadTemplate($model);
}
示例6: getMain
/**
* Return Gamer-Main-Page as HTML-View
*/
public function getMain()
{
if (person::getPermissionName() != 'admin' && person::getPermissionName() != 'gameuser') {
$login = Uri::getAction('Login');
header("Location: {$login}");
} else {
require 'classes/view.php';
$model = new stdClass();
$model->template = 'game/main';
$model->hasFrage = isset($_SESSION['tmpFrage']['id']);
$model->user = $_SESSION['username'];
$model->points = 0;
$model->message = $model->hasFrage ? 'Welcome back' : 'Welcome';
$view = new view();
return $view->loadTemplate($model);
}
}