Beispiel #1
0
            return showMe();
            break;
          case 'block':
            return hideMe();
            break;
          default:
            alert('display = ' + display);
        }
      }
//-->
    </script>
endScript;
$post_vars = filter_input_array(INPUT_POST);
$msg = '';
if (isset($post_vars['action']) && $post_vars['action'] == "teach") {
    $msg = insertAIML();
}
$teachContent = $template->getSection('TeachBotForm');
$showHelp = $template->getSection('TeachShowHelp');
$topNav = $template->getSection('TopNav');
$leftNav = $template->getSection('LeftNav');
$main = $template->getSection('Main');
$navHeader = $template->getSection('NavHeader');
$FooterInfo = getFooter();
$errMsgClass = !empty($msg) ? "ShowError" : "HideError";
$errMsgStyle = $template->getSection($errMsgClass);
$noLeftNav = '';
$noTopNav = '';
$noRightNav = $template->getSection('NoRightNav');
$headerTitle = 'Actions:';
$pageTitle = 'My-Program O - Teaching Interface';
Beispiel #2
0
    $session_name = 'PGO_Admin';
    session_name($session_name);
    session_start();
    $bot_id = isset($_SESSION['poadmin']['bot_id']) ? $_SESSION['poadmin']['bot_id'] : 1;
    if (empty($_SESSION) || !isset($_SESSION['poadmin']['uid']) || $_SESSION['poadmin']['uid'] == "") {
        error_log('Session vars: ' . print_r($_SESSION, true), 3, _LOG_PATH_ . 'session.txt');
        exit(json_encode(array('error' => "No session found")));
    }
    // Open the DB
    $dbConn = db_open();
}
if (isset($get_vars['action']) && $get_vars['action'] == "search") {
    $group = isset($get_vars['group']) ? $get_vars['group'] : 1;
    exit(runSearch());
} elseif (isset($get_vars['action']) && $get_vars['action'] == "add") {
    exit(insertAIML());
} elseif (isset($get_vars['action']) && $get_vars['action'] == "update") {
    exit(updateAIML());
} elseif (isset($get_vars['action']) && $get_vars['action'] == "del" && isset($get_vars['id']) && $get_vars['id'] != "") {
    exit(delAIML($get_vars['id']));
} else {
    $mainContent = $template->getSection('EditAimlPage');
}
$topNav = $template->getSection('TopNav');
$leftNav = $template->getSection('LeftNav');
$rightNav = $template->getSection('RightNav');
$main = $template->getSection('Main');
$navHeader = $template->getSection('NavHeader');
$FooterInfo = getFooter();
$errMsgClass = !empty($msg) ? "ShowError" : "HideError";
$errMsgStyle = $template->getSection($errMsgClass);