Commit f48480bf authored by lindonb's avatar lindonb

[FIX] feedback: allow feedback from $varcheck_errors to show with ajax

parent 6cfcac86
Pipeline #48955260 failed with stages
in 42 minutes and 6 seconds
......@@ -208,9 +208,14 @@ if ($prefs['feature_sefurl'] == 'y' && ! defined('TIKI_CONSOLE')) {
}
if (! empty($varcheck_errors)) {
$smarty->assign('msg', $varcheck_errors);
$smarty->display('error_raw.tpl');
die;
if (isset($_SERVER['HTTP_X_REQUESTED_WITH'])
&& $_SERVER['HTTP_X_REQUESTED_WITH'] == 'XMLHttpRequest') {
Feedback::error($varcheck_errors, true);
die;
} else {
$varcheck_errors['tpl'] = 'error_raw.tpl';
Feedback::errorPage($varcheck_errors);
}
}
if ($prefs['feature_usermenu'] == 'y') {
require_once('lib/setup/usermenu.php');
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment