本文整理汇总了PHP中GWF_Website::getDefaultOutput方法的典型用法代码示例。如果您正苦于以下问题:PHP GWF_Website::getDefaultOutput方法的具体用法?PHP GWF_Website::getDefaultOutput怎么用?PHP GWF_Website::getDefaultOutput使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类GWF_Website
的用法示例。
在下文中一共展示了GWF_Website::getDefaultOutput方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: onLoadModule
/**
* Load the $_GET['mo'] or GWF_DEFAULT_MODULE and execute it
* @return GWF3
*/
public function onLoadModule()
{
# Load the module
$db = gdo_db();
if (false === (self::$MODULE = GWF_Module::loadModuleDB($_GET['mo']))) {
if (false === (self::$MODULE = GWF_Module::loadModuleDB(GWF_DEFAULT_MODULE))) {
self::logDie('No module found.');
}
$_GET['me'] = GWF_DEFAULT_METHOD;
}
# Module is enabled?
if (true === self::$MODULE->isEnabled()) {
# Execute the method
self::$MODULE->onInclude();
self::$MODULE->onLoadLanguage();
$db = gdo_db();
$db->transactionStart();
self::$page = self::$MODULE->execute($_GET['me']);
if (true === isset($_GET['ajax'])) {
self::$page = GWF_Website::getDefaultOutput() . self::$page;
}
} else {
# TODO: HTTP Response code (by GWF_Exception(?))
self::$page = GWF_HTML::err('ERR_MODULE_DISABLED', array(self::$MODULE->display('module_name')));
}
return $this;
}
示例2: define
define('GWF_PAGE_TITLE', 'Time to Reset II');
require_once 'challenge/html_head.php';
# output start of website
require_once GWF_CORE_PATH . 'module/WeChall/solutionbox.php';
# Get the challenge
if (false === ($chall = WC_Challenge::getByTitle(GWF_PAGE_TITLE))) {
$chall = WC_Challenge::dummyChallenge(GWF_PAGE_TITLE, 7, 'challenge/time_to_reset2/index.php', false);
}
require_once 'challenge/time_to_reset2/TTR2_Form.include';
require_once 'challenge/time_to_reset2/TTR2_Tokens.include';
# And display the header
$chall->showHeader();
if (isset($_POST['solve'])) {
ttr2_submit($chall);
}
echo GWF_Website::getDefaultOutput();
$noother = sprintf('<a href="/profile/noother">noother</a>');
echo GWF_Box::box($chall->lang('info', array($noother, 'reset.php', 'index.php?show=source', 'index.php?highlight=christmas')), $chall->lang('title'));
if (Common::getGetString('highlight') === 'christmas') {
$source = '[PHP title=reset.php]' . trim(file_get_contents('challenge/time_to_reset2/reset.php')) . '[/PHP]';
echo GWF_Box::box(GWF_BBCode::decode($source));
}
formSolutionbox($chall);
# Print Challenge Footer
echo $chall->copyrightFooter();
# Print end of website
require_once 'challenge/html_foot.php';
function ttr2_submit(WC_Challenge $chall)
{
if ('' === ($answer = Common::getPostString('answer', ''))) {
return;