adding a Publisher type *minimal* on Skin Engine, to print main layout without any javascript

This commit is contained in:
Erik Amaru Ortiz
2013-08-30 13:57:37 -04:00
parent 4c5cf2b52b
commit ccbe8a4515

View File

@@ -603,7 +603,17 @@ class SkinEngine
$smarty->display($tpl);
}
private function _default()
/**
* this Method prints the same _default() environment except javascript
*/
private function _minimal()
{
$enableJavascript = false;
$this->_default($enableJavascript);
}
private function _default($enableJsScript=true)
{
require_once PATH_THIRDPARTY . 'smarty/libs/Smarty.class.php'; // put full path to Smarty.class.php
global $G_ENABLE_BLANK_SKIN;
@@ -665,7 +675,7 @@ class SkinEngine
if (defined('SYS_SYS')) {
$oHeadPublisher->title = isset($_SESSION['USR_USERNAME']) ? '(' . $_SESSION['USR_USERNAME'] . ' ' . G::LoadTranslation('ID_IN') . ' ' . SYS_SYS . ')' : '';
}
$header = $oHeadPublisher->printHeader();
$header = $enableJsScript ? $oHeadPublisher->printHeader() : '';
$header .= $oHeadPublisher->getExtJsStylesheets($this->cssFileName);
}