本文整理汇总了PHP中useFirebug函数的典型用法代码示例。如果您正苦于以下问题:PHP useFirebug函数的具体用法?PHP useFirebug怎么用?PHP useFirebug使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了useFirebug函数的11个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的PHP代码示例。
示例1: run
public function run()
{
/*
* Instead of manually rendering scripts after this function returns we
* use the callback. This ensures that scripts are always rendered, even
* if we call exit at some point in the code. (Which we shouldn't, but
* it happens.)
*/
// Ensure to set some var, but script are replaced in SurveyRuntimeHelper
$aLSJavascriptVar = array();
$aLSJavascriptVar['bFixNumAuto'] = (int) (bool) Yii::app()->getConfig('bFixNumAuto', 1);
$aLSJavascriptVar['bNumRealValue'] = (int) (bool) Yii::app()->getConfig('bNumRealValue', 0);
$aLangData = getLanguageData();
$aRadix = getRadixPointData($aLangData[Yii::app()->getConfig('defaultlang')]['radixpoint']);
$aLSJavascriptVar['sLEMradix'] = $aRadix['separator'];
$sLSJavascriptVar = "LSvar=" . json_encode($aLSJavascriptVar) . ';';
App()->clientScript->registerScript('sLSJavascriptVar', $sLSJavascriptVar, CClientScript::POS_HEAD);
App()->clientScript->registerScript('setJsVar', "setJsVar();", CClientScript::POS_BEGIN);
// Ensure all js var is set before rendering the page (User can click before $.ready)
App()->getClientScript()->registerPackage('jqueryui');
App()->getClientScript()->registerPackage('jquery-touch-punch');
App()->getClientScript()->registerScriptFile(Yii::app()->getConfig('generalscripts') . "survey_runtime.js");
useFirebug();
ob_start(function ($buffer, $phase) {
App()->getClientScript()->render($buffer);
App()->getClientScript()->reset();
return $buffer;
});
ob_implicit_flush(false);
$this->action();
ob_flush();
}
开发者ID:rouben,项目名称:LimeSurvey,代码行数:32,代码来源:index.php
示例2: run
public function run()
{
/*
* Instead of manually rendering scripts after this function returns we
* use the callback. This ensures that scripts are always rendered, even
* if we call exit at some point in the code. (Which we shouldn't, but
* it happens.)
*/
// Ensure to set some var, but script are replaced in SurveyRuntimeHelper
$aLSJavascriptVar = array();
$aLSJavascriptVar['bFixNumAuto'] = (int) (bool) Yii::app()->getConfig('bFixNumAuto', 1);
$aLSJavascriptVar['bNumRealValue'] = (int) (bool) Yii::app()->getConfig('bNumRealValue', 0);
$aLangData = getLanguageData();
$aRadix = getRadixPointData($aLangData[Yii::app()->getConfig('defaultlang')]['radixpoint']);
$aLSJavascriptVar['sLEMradix'] = $aRadix['separator'];
$sLSJavascriptVar = "LSvar=" . json_encode($aLSJavascriptVar) . ';';
// Template configuration
$param = $this->_getParameters(func_get_args(), $_POST);
$surveyid = $param['sid'];
// Font awesome
if (!YII_DEBUG) {
App()->getClientScript()->registerCssFile(App()->getAssetManager()->publish(dirname(Yii::app()->request->scriptFile) . '/styles-public/font-awesome-43.min.css'));
} else {
App()->getClientScript()->registerCssFile(Yii::app()->getBaseUrl(true) . '/styles-public/font-awesome-43-debugmode.min.css');
}
global $oTemplate;
$oTemplate = Template::model()->getTemplateConfiguration('', $surveyid);
$this->oTemplate = $oTemplate;
App()->clientScript->registerScript('sLSJavascriptVar', $sLSJavascriptVar, CClientScript::POS_HEAD);
App()->clientScript->registerScript('setJsVar', "setJsVar();", CClientScript::POS_BEGIN);
// Ensure all js var is set before rendering the page (User can click before $.ready)
foreach ($oTemplate->packages as $package) {
App()->getClientScript()->registerPackage($package);
}
App()->getClientScript()->registerScriptFile(Yii::app()->getConfig('generalscripts') . "survey_runtime.js");
if ($oTemplate->cssFramework == 'bootstrap') {
App()->bootstrap->register();
}
useFirebug();
ob_start(function ($buffer, $phase) {
App()->getClientScript()->render($buffer);
App()->getClientScript()->reset();
return $buffer;
});
ob_implicit_flush(false);
$this->action();
ob_flush();
}
开发者ID:kochichi,项目名称:LimeSurvey,代码行数:48,代码来源:index.php
示例3: run
public function run()
{
/*
* Instead of manually rendering scripts after this function returns we
* use the callback. This ensures that scripts are always rendered, even
* if we call exit at some point in the code. (Which we shouldn't, but
* it happens.)
*/
// Ensure to set some var, but script are replaced in SurveyRuntimeHelper
$aLSJavascriptVar = array();
$aLSJavascriptVar['bFixNumAuto'] = (int) (bool) Yii::app()->getConfig('bFixNumAuto', 1);
$aLSJavascriptVar['bNumRealValue'] = (int) (bool) Yii::app()->getConfig('bNumRealValue', 0);
$aLangData = getLanguageData();
$aRadix = getRadixPointData($aLangData[Yii::app()->getConfig('defaultlang')]['radixpoint']);
$aLSJavascriptVar['sLEMradix'] = $aRadix['separator'];
$sLSJavascriptVar = "LSvar=" . json_encode($aLSJavascriptVar) . ';';
// Template configuration
$param = $this->_getParameters(func_get_args(), $_POST);
$surveyid = $param['sid'];
$oTemplate = Template::model()->getInstance('', $surveyid);
$this->oTemplate = $oTemplate;
App()->clientScript->registerScript('sLSJavascriptVar', $sLSJavascriptVar, CClientScript::POS_HEAD);
App()->clientScript->registerScript('setJsVar', "setJsVar();", CClientScript::POS_BEGIN);
// Ensure all js var is set before rendering the page (User can click before $.ready)
foreach ($oTemplate->packages as $package) {
App()->getClientScript()->registerPackage((string) $package);
}
App()->getClientScript()->registerScriptFile(Yii::app()->getConfig('generalscripts') . "survey_runtime.js");
if ($oTemplate->cssFramework == 'bootstrap') {
// We now use the bootstrap package isntead of the Yiistrap TbApi::register() method
// Then instead of using the composer dependency system for templates
// We can use the package dependency system
Yii::app()->getClientScript()->registerMetaTag('width=device-width, initial-scale=1.0', 'viewport');
App()->bootstrap->registerAllScripts();
}
useFirebug();
ob_start(function ($buffer, $phase) {
App()->getClientScript()->render($buffer);
App()->getClientScript()->reset();
return $buffer;
});
ob_implicit_flush(false);
$this->action();
ob_flush();
}
开发者ID:mfavetti,项目名称:LimeSurvey,代码行数:45,代码来源:index.php
示例4: templatereplace
//.........这里部分代码省略.........
} else {
if (file_exists($templatedir . DIRECTORY_SEPARATOR . $cssinclude)) {
$_templatecss .= "<link rel='stylesheet' type='text/css' media='all' href='{$templateurl}{$cssinclude}' />\n";
} else {
$_templatecss .= "<link rel='stylesheet' type='text/css' media='all' href='" . Yii::app()->getConfig('publicstyleurl') . $cssinclude . "' />\n";
}
}
}
}
$_templatecss .= $template_jqueryui_css;
// Template jquery ui after default css
$_templatecss .= "<link rel='stylesheet' type='text/css' media='all' href='{$templateurl}template.css' />\n";
if (getLanguageRTL($clang->langcode)) {
$_templatecss .= "<link rel='stylesheet' type='text/css' media='all' href='{$templateurl}template-rtl.css' />\n";
}
}
if (stripos($line, "{TEMPLATEJS}")) {
$js_header_includes = header_includes(false, 'js');
$_jqueryuijsurl = Yii::app()->getConfig('generalscripts') . "jquery/jquery-ui.js";
$_templatejs .= "<script type='text/javascript' src='" . Yii::app()->getConfig('generalscripts') . "jquery/jquery.js'></script>\n";
$_templatejs .= "<script type='text/javascript' src='{$_jqueryuijsurl}'></script>\n";
$_templatejs .= "<script type='text/javascript' src='" . Yii::app()->getConfig('generalscripts') . "jquery/jquery.ui.touch-punch.min.js'></script>\n";
if ($js_header_includes) {
foreach ($js_header_includes as $jsinclude) {
if (substr($jsinclude, 0, 4) == 'http' || substr($jsinclude, 0, strlen(Yii::app()->getConfig('publicurl'))) == Yii::app()->getConfig('publicurl')) {
$_templatejs .= "<script type='text/javascript' src='{$jsinclude}'></script>\n";
} else {
$_templatejs .= "<script type='text/javascript' src='" . Yii::app()->getConfig('generalscripts') . $jsinclude . "'></script>\n";
}
}
}
$_templatejs .= "<script type='text/javascript' src='" . Yii::app()->getConfig('generalscripts') . "survey_runtime.js'></script>\n";
$_templatejs .= "<script type='text/javascript' src='{$templateurl}template.js'></script>\n";
$_templatejs .= useFirebug();
}
// surveyformat
if (isset($thissurvey['format'])) {
$surveyformat = str_replace(array("A", "S", "G"), array("allinone", "questionbyquestion", "groupbygroup"), $thissurvey['format']);
} else {
$surveyformat = "";
}
if (isset(Yii::app()->session['step']) && Yii::app()->session['step'] % 2 && $surveyformat != "allinone") {
$surveyformat .= " page-odd";
}
if (isset($thissurvey['allowjumps']) && $thissurvey['allowjumps'] == "Y" && $surveyformat != "allinone" && (isset(Yii::app()->session['step']) && Yii::app()->session['step'] > 0)) {
$surveyformat .= " withindex";
}
if (isset($thissurvey['showprogress']) && $thissurvey['showprogress'] == "Y") {
$surveyformat .= " showprogress";
}
if (isset($thissurvey['showqnumcode'])) {
$surveyformat .= " showqnumcode-" . $thissurvey['showqnumcode'];
}
// real survey contact
if (isset($surveylist) && isset($surveylist['contact'])) {
$surveycontact = $surveylist['contact'];
} elseif (isset($surveylist) && isset($thissurvey['admin']) && $thissurvey['admin'] != "") {
$surveycontact = sprintf($clang->gT("Please contact %s ( %s ) for further assistance."), $thissurvey['admin'], $thissurvey['adminemail']);
} else {
$surveycontact = "";
}
// If there are non-bracketed replacements to be made do so above this line.
// Only continue in this routine if there are bracketed items to replace {}
if (strpos($line, "{") === false) {
// process string anyway so that it can be pretty-printed
return LimeExpressionManager::ProcessString($line, $questionNum, NULL, false, 1, 1, true);
开发者ID:rawaludin,项目名称:LimeSurvey,代码行数:67,代码来源:replacements_helper.php
示例5: _getAdminHeader
/**
* Prints Admin Header
*
* @access protected
* @param bool $meta
* @param bool $return
* @return mixed
*/
public function _getAdminHeader($meta = false, $return = false)
{
if (empty(Yii::app()->session['adminlang'])) {
Yii::app()->session["adminlang"] = Yii::app()->getConfig("defaultlang");
}
$data = array();
$data['adminlang'] = Yii::app()->session['adminlang'];
//$data['admin'] = getLanguageRTL;
$data['test'] = "t";
$data['languageRTL'] = "";
$data['styleRTL'] = "";
Yii::app()->loadHelper("surveytranslator");
if (getLanguageRTL(Yii::app()->session["adminlang"])) {
$data['languageRTL'] = " dir=\"rtl\" ";
$data['bIsRTL'] = true;
} else {
$data['bIsRTL'] = false;
}
$data['meta'] = "";
if ($meta) {
$data['meta'] = $meta;
}
$data['baseurl'] = Yii::app()->baseUrl . '/';
$data['datepickerlang'] = "";
if (Yii::app()->session["adminlang"] != 'en') {
$data['datepickerlang'] = "<script type=\"text/javascript\" src=\"" . Yii::app()->getConfig('generalscripts') . "jquery/locale/jquery.ui.datepicker-" . Yii::app()->session["adminlang"] . ".js\"></script>\n";
}
$data['sitename'] = Yii::app()->getConfig("sitename");
$data['admintheme'] = Yii::app()->getConfig("admintheme");
$data['firebug'] = useFirebug();
if (!empty(Yii::app()->session['dateformat'])) {
$data['formatdata'] = getDateFormatData(Yii::app()->session['dateformat']);
}
// Prepare flashmessage
if (!empty(Yii::app()->session['flashmessage']) && Yii::app()->session['flashmessage'] != '') {
$data['flashmessage'] = Yii::app()->session['flashmessage'];
unset(Yii::app()->session['flashmessage']);
}
$data['css_admin_includes'] = $this->_css_admin_includes(array(), true);
return $this->renderPartial("/admin/super/header", $data, $return);
}
开发者ID:rawaludin,项目名称:LimeSurvey,代码行数:49,代码来源:AdminController.php
示例6: getTemplateURL
$data['templateurl'] = getTemplateURL(Yii::app()->getConfig("defaulttemplate")) . "/";
$data['templatename'] = Yii::app()->getConfig("defaulttemplate");
$data['sitename'] = Yii::app()->getConfig("sitename");
$data['languagechanger'] = makeLanguageChanger(App()->lang->langcode);
//A nice exit
sendCacheHeaders();
doHeader();
// Javascript Var
$aLSJavascriptVar = array();
$aLSJavascriptVar['bFixNumAuto'] = (int) (bool) Yii::app()->getConfig('bFixNumAuto', 1);
$aLSJavascriptVar['bNumRealValue'] = (int) (bool) Yii::app()->getConfig('bNumRealValue', 0);
if (isset($thissurvey['surveyls_numberformat'])) {
$radix = getRadixPointData($thissurvey['surveyls_numberformat']);
} else {
$aLangData = getLanguageData();
$radix = getRadixPointData($aLangData[Yii::app()->getConfig('defaultlang')]['radixpoint']);
// or $clang->langcode . defaultlang ensure it's same for each language ?
}
$aLSJavascriptVar['sLEMradix'] = $radix['separator'];
$sLSJavascriptVar = "LSvar=" . json_encode($aLSJavascriptVar);
App()->clientScript->registerScript('sLSJavascriptVar', $sLSJavascriptVar, CClientScript::POS_HEAD);
App()->clientScript->registerScript('setJsVar', "setJsVar();", CClientScript::POS_BEGIN);
// Ensure all js var is set before rendering the page (User can click before $.ready)
App()->getClientScript()->registerPackage('jqueryui');
App()->getClientScript()->registerPackage('jquery-touch-punch');
App()->getClientScript()->registerScriptFile(Yii::app()->getConfig('generalscripts') . "survey_runtime.js");
useFirebug();
echo templatereplace(file_get_contents(getTemplatePath(Yii::app()->getConfig("defaulttemplate")) . "/startpage.pstpl"), array(), $data, 'survey[' . __LINE__ . ']');
echo templatereplace(file_get_contents(getTemplatePath(Yii::app()->getConfig("defaulttemplate")) . "/surveylist.pstpl"), array(), $data, 'survey[' . __LINE__ . ']');
echo templatereplace(file_get_contents(getTemplatePath(Yii::app()->getConfig("defaulttemplate")) . "/endpage.pstpl"), array(), $data, 'survey[' . __LINE__ . ']');
doFooter();
开发者ID:josetorerobueno,项目名称:test_repo,代码行数:31,代码来源:publicSurveyList.php
示例7: _getAdminHeader
/**
* Prints Admin Header
*
* @access protected
* @param bool $meta
* @param bool $return
* @return mixed
*/
public function _getAdminHeader($meta = false, $return = false)
{
if (empty(Yii::app()->session['adminlang'])) {
Yii::app()->session["adminlang"] = Yii::app()->getConfig("defaultlang");
}
$aData = array();
$aData['adminlang'] = Yii::app()->session['adminlang'];
//$data['admin'] = getLanguageRTL;
$aData['test'] = "t";
$aData['languageRTL'] = "";
$aData['styleRTL'] = "";
Yii::app()->loadHelper("surveytranslator");
if (getLanguageRTL(Yii::app()->session["adminlang"])) {
$aData['languageRTL'] = " dir=\"rtl\" ";
$aData['bIsRTL'] = true;
} else {
$aData['bIsRTL'] = false;
}
$aData['meta'] = "";
if ($meta) {
$aData['meta'] = $meta;
}
$aData['baseurl'] = Yii::app()->baseUrl . '/';
$aData['datepickerlang'] = "";
if (Yii::app()->session["adminlang"] != 'en') {
Yii::app()->getClientScript()->registerScriptFile(App()->baseUrl . "/third_party/jqueryui/development-bundle/ui/i18n/jquery.ui.datepicker-" . Yii::app()->session['adminlang'] . ".js");
}
$aData['sitename'] = Yii::app()->getConfig("sitename");
$aData['admintheme'] = Yii::app()->getConfig("admintheme");
$aData['firebug'] = useFirebug();
if (!empty(Yii::app()->session['dateformat'])) {
$aData['formatdata'] = getDateFormatData(Yii::app()->session['dateformat']);
}
//ajax popup call
$cs = Yii::app()->clientScript;
$cs->coreScriptPosition = CClientScript::POS_HEAD;
$cs->scriptMap = array();
$cs->registerCoreScript('jquery');
$cs->registerCoreScript('jquery.ui');
//$baseU = Yii::app()->getModule('gii')->assetsUrl; //the assets of existing module
$cs->registerScriptFile(Yii::app()->request->baseUrl . '/scripts/fancybox/jquery.fancybox-1.3.1.pack.js');
$cs->registerCssFile(Yii::app()->request->baseUrl . '/scripts/fancybox/jquery.fancybox-1.3.1.css');
$cs->registerScriptFile(Yii::app()->request->baseUrl . '/scripts/popup.js');
//end ajax popup call
$sOutput = $this->renderPartial("/admin/super/header", $aData, true);
if ($return) {
return $sOutput;
} else {
echo $sOutput;
}
}
开发者ID:jdbaltazar,项目名称:survey-office,代码行数:59,代码来源:AdminController.php
示例8: _getAdminHeader
/**
* Prints Admin Header
*
* @access protected
* @param bool $meta
* @param bool $return
* @return mixed
*/
public function _getAdminHeader($meta = false, $return = false)
{
if (empty(Yii::app()->session['adminlang'])) {
Yii::app()->session["adminlang"] = Yii::app()->getConfig("defaultlang");
}
$aData = array();
$aData['adminlang'] = Yii::app()->language;
$aData['languageRTL'] = "";
$aData['styleRTL'] = "";
Yii::app()->loadHelper("surveytranslator");
if (getLanguageRTL(Yii::app()->language)) {
$aData['languageRTL'] = " dir=\"rtl\" ";
$aData['bIsRTL'] = true;
} else {
$aData['languageRTL'] = " dir=\"ltr\" ";
$aData['bIsRTL'] = false;
}
$aData['meta'] = "";
if ($meta) {
$aData['meta'] = $meta;
}
$aData['baseurl'] = Yii::app()->baseUrl . '/';
$aData['datepickerlang'] = "";
$aData['sitename'] = Yii::app()->getConfig("sitename");
$aData['firebug'] = useFirebug();
if (!empty(Yii::app()->session['dateformat'])) {
$aData['formatdata'] = getDateFormatData(Yii::app()->session['dateformat']);
}
// Register admin theme package with asset manager
$oAdminTheme = AdminTheme::getInstance();
$aData['sAdmintheme'] = $oAdminTheme->name;
$aData['aPackageScripts'] = $aData['aPackageStyles'] = array();
//foreach ($aData['aPackageStyles'] as &$filename)
//{
//$filename = str_replace('.css', '-rtl.css', $filename);
//}
//echo '<pre>'; var_dump($aData); echo '</pre>';die;
$sOutput = $this->renderPartial("/admin/super/header", $aData, true);
if ($return) {
return $sOutput;
} else {
echo $sOutput;
}
}
开发者ID:sickpig,项目名称:LimeSurvey,代码行数:52,代码来源:AdminController.php
示例9: _getAdminHeader
/**
* Prints Admin Header
*
* @access protected
* @param bool $meta
* @param bool $return
* @return mixed
*/
public function _getAdminHeader($meta = false, $return = false)
{
if (empty(Yii::app()->session['adminlang'])) {
Yii::app()->session["adminlang"] = Yii::app()->getConfig("defaultlang");
}
$aData = array();
$aData['adminlang'] = Yii::app()->language;
$aData['languageRTL'] = "";
$aData['styleRTL'] = "";
Yii::app()->loadHelper("surveytranslator");
if (getLanguageRTL(Yii::app()->language)) {
$aData['languageRTL'] = " dir=\"rtl\" ";
$aData['bIsRTL'] = true;
} else {
$aData['languageRTL'] = " dir=\"ltr\" ";
$aData['bIsRTL'] = false;
}
$aData['meta'] = "";
if ($meta) {
$aData['meta'] = $meta;
}
$aData['baseurl'] = Yii::app()->baseUrl . '/';
$aData['datepickerlang'] = "";
if ($aData['adminlang'] != 'en') {
Yii::app()->getClientScript()->registerScriptFile(App()->baseUrl . "/third_party/jqueryui/development-bundle/ui/i18n/jquery.ui.datepicker-" . $aData['adminlang'] . ".js");
}
$aData['sitename'] = Yii::app()->getConfig("sitename");
$aData['firebug'] = useFirebug();
if (!empty(Yii::app()->session['dateformat'])) {
$aData['formatdata'] = getDateFormatData(Yii::app()->session['dateformat']);
}
// Register admin theme package with asset manager
$oAdmintheme = Template::model()->getAdminTheme();
// We get the package datas from the model
$aData['sAdmintheme'] = $oAdmintheme->name;
$aData['sAdminthemePackageName'] = $oAdmintheme->packagename;
$aData['aPackageScripts'] = (array) $oAdmintheme->config->files->js->filename;
$aData['aPackageStyles'] = (array) $oAdmintheme->config->files->css->filename;
if ($aData['bIsRTL']) {
foreach ($aData['aPackageStyles'] as &$filename) {
$filename = str_replace('.css', '-rtl.css', $filename);
}
}
$sOutput = $this->renderPartial("/admin/super/header", $aData, true);
// Define images url
define('LOGO_URL', App()->getAssetManager()->publish(dirname(Yii::app()->request->scriptFile) . '/styles/' . $oAdmintheme->name . '/images/logo.png'));
// Define presentation text on welcome page
if ($oAdmintheme->config->metadatas->presentation) {
define('PRESENTATION', $oAdmintheme->config->metadatas->presentation);
} else {
define('PRESENTATION', gT('This is the LimeSurvey admin interface. Start to build your survey from here.'));
}
if ($return) {
return $sOutput;
} else {
echo $sOutput;
}
}
开发者ID:CSCI-462-01-2016,项目名称:LimeSurvey,代码行数:66,代码来源:AdminController.php
示例10: _getAdminHeader
/**
* Prints Admin Header
*
* @access protected
* @param bool $meta
* @param bool $return
* @return mixed
*/
public function _getAdminHeader($meta = false, $return = false)
{
if (empty(Yii::app()->session['adminlang'])) {
Yii::app()->session["adminlang"] = Yii::app()->getConfig("defaultlang");
}
$aData = array();
$aData['adminlang'] = Yii::app()->language;
$aData['languageRTL'] = "";
$aData['styleRTL'] = "";
Yii::app()->loadHelper("surveytranslator");
if (getLanguageRTL(Yii::app()->language)) {
$aData['languageRTL'] = " dir=\"rtl\" ";
$aData['bIsRTL'] = true;
} else {
$aData['languageRTL'] = " dir=\"ltr\" ";
$aData['bIsRTL'] = false;
}
$aData['meta'] = "";
if ($meta) {
$aData['meta'] = $meta;
}
$aData['baseurl'] = Yii::app()->baseUrl . '/';
$aData['datepickerlang'] = "";
if ($aData['adminlang'] != 'en') {
Yii::app()->getClientScript()->registerScriptFile(App()->baseUrl . "/third_party/jqueryui/development-bundle/ui/i18n/jquery.ui.datepicker-" . $aData['adminlang'] . ".js");
}
$aData['sitename'] = Yii::app()->getConfig("sitename");
$aData['admintheme'] = Yii::app()->getConfig("admintheme");
$aData['firebug'] = useFirebug();
if (!empty(Yii::app()->session['dateformat'])) {
$aData['formatdata'] = getDateFormatData(Yii::app()->session['dateformat']);
}
$sOutput = $this->renderPartial("/admin/super/header", $aData, true);
if ($return) {
return $sOutput;
} else {
echo $sOutput;
}
}
开发者ID:kasutori,项目名称:LimeSurvey,代码行数:47,代码来源:AdminController.php
示例11: display
/**
* Display needed public page
* @param $iSurveyId
*/
private function display($iSurveyId)
{
$sLanguage = Yii::app()->language;
$aData['surveyid'] = $surveyid = $iSurveyId;
$aData['thissurvey'] = getSurveyInfo($iSurveyId, $sLanguage);
$sTemplate = getTemplatePath($aData['thissurvey']['template']);
Yii::app()->setConfig('surveyID', $iSurveyId);
//Needed for languagechanger
$aData['sitename'] = Yii::app()->getConfig('sitename');
$aData['aRegisterErrors'] = $this->aRegisterErrors;
$aData['sMessage'] = $this->sMessage;
sendCacheHeaders();
doHeader();
$aViewData['sTemplate'] = $sTemplate;
if (!$this->sMessage) {
$aData['languagechanger'] = makeLanguageChangerSurvey($sLanguage);
// Only show language changer shown the form is shown, not after submission
$aViewData['content'] = self::getRegisterForm($iSurveyId);
} else {
$aViewData['content'] = templatereplace($this->sMessage);
}
$aViewData['aData'] = $aData;
// Test if we come from index or from register
if (empty(App()->clientScript->scripts)) {
App()->getClientScript()->registerPackage('jqueryui');
App()->getClientScript()->registerPackage('jquery-touch-punch');
App()->getClientScript()->registerScriptFile(Yii::app()->getConfig('generalscripts') . "survey_runtime.js");
useFirebug();
$this->render('/register/display', $aViewData);
} else {
// urvey/index need renderPartial
$this->renderPartial('/register/display', $aViewData);
}
doFooter();
}
开发者ID:BertHankes,项目名称:LimeSurvey,代码行数:39,代码来源:RegisterController.php
注:本文中的useFirebug函数示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论