issue 2367 add code that display error message when occurred error in module.

git-svn-id: http://xe-core.googlecode.com/svn/branches/maserati@11897 201d5d3c-b55e-5fd7-737f-ddc643e51545
This commit is contained in:
devjin 2012-10-25 12:05:38 +00:00
parent a239136c2f
commit afd6f9b5ae
2 changed files with 24 additions and 13 deletions

View file

@ -96,25 +96,32 @@
$oModule = $oModuleHandler->procModule();
}
if($skin)
if($oModule->toBool())
{
$skinDir = ($skinType == 'M') ? 'm.skins' : 'skins';
$template_path = sprintf("%s%s/%s/",$oModule->module_path, $skinDir, $skin);
$oModule->setTemplatePath($template_path);
if(is_array($skinVars))
if($skin)
{
foreach($skinVars as $key => $val)
$skinDir = ($skinType == 'M') ? 'm.skins' : 'skins';
$template_path = sprintf("%s%s/%s/",$oModule->module_path, $skinDir, $skin);
$oModule->setTemplatePath($template_path);
if(is_array($skinVars))
{
$oModule->module_info->{$key} = $val;
foreach($skinVars as $key => $val)
{
$oModule->module_info->{$key} = $val;
}
}
}
}
require_once("./classes/display/HTMLDisplayHandler.php");
$handler = new HTMLDisplayHandler();
$output = $handler->toDoc($oModule);
Context::set('content', $output);
require_once("./classes/display/HTMLDisplayHandler.php");
$handler = new HTMLDisplayHandler();
$output = $handler->toDoc($oModule);
Context::set('content', $output);
}
else
{
Context::set('content', Context::getLang('not_support_layout_preview'));
}
}
else
{