} } $iTotal = count($output["aaData"]); $output["iTotalRecords"] = $iTotal; $output["iTotalDisplayRecords"] = $iTotal; header('Content-type: application/json'); echo json_encode($output); exit; } if ($action == 'confirm_delete' && $confirm == "yes") { if ($user->admin) { $object->id = $id; $object->delete(); Header("Location: index.php"); exit; } else { $langs->load("errors"); $message = '<div class="error">' . $langs->trans('ErrorForbidden') . '</div>'; } } if ($action == 'commit' ) { if ($user->admin) { $object->id = $id; $object->commit(); Header("Location: index.php"); exit; } else {