1
Antoine
Scope problem?
  • 2005/7/11 13:52

  • Antoine

  • Friend of XOOPS

  • Posts: 112

  • Since: 2004/11/14


Hi,

I am using the following code in my module to render an error page if some data doesn't validate:

if($err_handler->has_errors()) {
    
$xoopsOption['main_template'] = 'survey_error.html';
    include(
XOOPS_ROOT_PATH.'/header.php');
    
$xoopsTpl->assign('errors'$err_handler->getErrors());
    
//$xoopsTpl->display('db:survey_error.html');
    
include(XOOPS_ROOT_PATH.'/footer.php');
    exit();
}


Strange enough this doesn't render the template. When I use $xoopsTpl->display('db:survey_error.html') it does display correctly, but that is a workaround.

edit: using $xoopsOption['template_main'] woulda helped.

Login

Who's Online

244 user(s) are online (199 user(s) are browsing Support Forums)


Members: 0


Guests: 244


more...

Donat-O-Meter

Stats
Goal: $100.00
Due Date: Nov 30
Gross Amount: $0.00
Net Balance: $0.00
Left to go: $100.00
Make donations with PayPal!

Latest GitHub Commits