function replace_section()
{
    $boot = new boostrap_form();
    $tpl = new templates();
    $page = CurrentPageName();
    $servername = $_GET["servername"];
    $folderid = $_GET["folderid"];
    $q = new mysql_squid_builder();
    $sock = new sockets();
    $ARRAY = unserialize(base64_decode($sock->getFrameWork("nginx.php?status-infos=yes")));
    if (!is_array($ARRAY["MODULES"])) {
        $ARRAY["MODULES"] = array();
    }
    $COMPAT = FALSE;
    while (list($a, $b) = each($ARRAY["MODULES"])) {
        if (preg_match("#http_substitutions_filter#", $a)) {
            $COMPAT = true;
            break;
        }
    }
    if (!$COMPAT) {
        $error = $tpl->_ENGINE_parse_body("<p class=text-error>{error_nginx_substitutions_filter}</p>");
    }
    $EXPLAIN["BUTTONS"][] = $tpl->_ENGINE_parse_body(button("{new_rule}", "Loadjs('{$page}?replace-js=yes&servername={$servername}&replaceid=0&folderid={$folderid}')"));
    echo $error . $boot->SearchFormGen("rulename", "replace-search", "&servername={$servername}&folderid={$folderid}", $EXPLAIN);
}
function vlan_section()
{
    $page = CurrentPageName();
    $boot = new boostrap_form();
    $OPTIONS["BUTTONS"][] = button("{new_virtual_ip}", "Loadjs('{$page}?virtid-js=0')", 16);
    echo $boot->SearchFormGen(null, "search-virtip", null, $OPTIONS);
}
function section_websites()
{
    $boot = new boostrap_form();
    $tpl = new templates();
    $page = CurrentPageName();
    echo $boot->SearchFormGen("familysite", "sites-search", null, $EXPLAIN);
}
function section_start()
{
    $boot = new boostrap_form();
    $tpl = new templates();
    $page = CurrentPageName();
    echo $boot->SearchFormGen("searchstring", "session-search", null, null);
}
function syslog_section()
{
    $EXPLAIN = array();
    $boot = new boostrap_form();
    $tpl = new templates();
    //$EXPLAIN["BUTTONS"][]=$tpl->_ENGINE_parse_body(button("{new_website}", "YahooWin5('690','freewebs.HTTrack.php?item-id=0&t=0','WebCopy::{new_website}');"));
    echo $boot->SearchFormGen("service", "search", null);
}
function etchostss_section()
{
    $page = CurrentPageName();
    $boot = new boostrap_form();
    $tpl = new templates();
    $OPTIONS["BUTTONS"][] = button("{add_new_entry}", "Loadjs('{$page}?etchosts-js=yes')", 16);
    echo $tpl->_ENGINE_parse_body("<div class=text-info>{etc_hosts_explain}</div>") . $boot->SearchFormGen("ipaddr,hostname", "search-etchosts", null, $OPTIONS);
}
function section()
{
    $page = CurrentPageName();
    $boot = new boostrap_form();
    $SearchQuery = $boot->SearchFormGen(null, "search", null);
    $tpl = new templates();
    echo $tpl->_ENGINE_parse_body($SearchQuery);
}
function artica_section()
{
    $EXPLAIN = array();
    $boot = new boostrap_form();
    $tpl = new templates();
    //$EXPLAIN["BUTTONS"][]=$tpl->_ENGINE_parse_body(button("{new_website}", "YahooWin5('690','freewebs.HTTrack.php?item-id=0&t=0','WebCopy::{new_website}');"));
    echo $boot->SearchFormGen("context,text,process,content", "search", "&context={$_GET["context"]}&category={$_GET["category"]}");
}
function bridges_section()
{
    $page = CurrentPageName();
    $boot = new boostrap_form();
    $OPTIONS["BUTTONS"][] = button("{new_net_bridge}", "Loadjs('{$page}?bridge-js=0')", 16);
    $expl = "<div class=text-info>{firewall_bridges_explain}</div>";
    echo $expl . $boot->SearchFormGen("nic_inbound,nic_linked", "search-bridge", null, $OPTIONS);
}
Exemplo n.º 10
0
function popup()
{
    $sock = new sockets();
    $boot = new boostrap_form();
    $tpl = new templates();
    $page = CurrentPageName();
    $t = time();
    echo $boot->SearchFormGen("MAC", "search-records") . "<script>\n\tExecuteByClassName('SearchFunction');\n\t</script>";
}
Exemplo n.º 11
0
function section_search_ad()
{
    $boot = new boostrap_form();
    $tpl = new templates();
    $page = CurrentPageName();
    $ou = $_SESSION["ou"];
    $callback = urlencode($_GET["CallBack"]);
    echo $boot->SearchFormGen(null, "search-users-ad", "&CallBack={$callback}");
}
Exemplo n.º 12
0
function bridges_section()
{
    $page = CurrentPageName();
    $boot = new boostrap_form();
    $OPTIONS["BUTTONS"][] = button("{new_net_bridge}", "Loadjs('{$page}?bridge-js=0')", 16);
    $tpl = new templates();
    $expl = "<div class=text-info>{interface_bridges_explain}</div>";
    echo $expl . $boot->SearchFormGen("ipaddr,name", "search-bridge", null, $OPTIONS);
}
function master_content()
{
    $page = CurrentPageName();
    $tpl = new templates();
    $t = time();
    $boot = new boostrap_form();
    $SearchQuery = $boot->SearchFormGen("sitename,familysite,domain,country", "search-websites") . "\n\t<script>\n\t\tfunction RefreshNotCategorizedTitle(){\n\t\t\tLoadAjaxTiny('title-not-categorized','{$page}?title-not-categorized=yes');\n\t\t}\n\t\tRefreshNotCategorizedTitle();\n\t</script>\n\t\t\t";
    echo $SearchQuery;
}
function events_section()
{
    $boot = new boostrap_form();
    $page = CurrentPageName();
    $explain = null;
    $tpl = new templates();
    $suffix = suffix();
    echo $boot->SearchFormGen("description,filename,function", "events-search", "&ID={$_GET["ID"]}");
}
function page()
{
    $boot = new boostrap_form();
    $q = new mysql_squid_builder();
    $explain = $q->tasks_explain_array[$_GET["TaskID"]];
    $tpl = new templates();
    $explain = $tpl->_ENGINE_parse_body($explain);
    $form = $boot->SearchFormGen("TimeDescription", "SearchTask", "&TaskID={$_GET["TaskID"]}", "<div class=text-info>{$explain}</div>");
    echo $form;
}
function section_events()
{
    $suffix = suffix();
    $page = CurrentPageName();
    $tpl = new templates();
    $t = time();
    $boot = new boostrap_form();
    $form = $boot->SearchFormGen("subject", "events-search", $suffix);
    echo $form;
}
function who()
{
    $page = CurrentPageName();
    $tpl = new templates();
    $t = time();
    $boot = new boostrap_form();
    $form = $boot->SearchFormGen("uid,zDate,MAC", "who-items", "&youtubeid={$_GET["youtubeid"]}");
    echo $form;
    return;
}
Exemplo n.º 18
0
function section_search()
{
    $boot = new boostrap_form();
    $tpl = new templates();
    $page = CurrentPageName();
    $ou = $_SESSION["ou"];
    $ou_encoded = base64_encode($ou);
    $EXPLAIN["BUTTONS"][] = $tpl->_ENGINE_parse_body(button("{new_member}", "Loadjs('{$page}?add-user-js=yes&ou=" . urlencode($ou) . "')"));
    $EXPLAIN["BUTTONS"][] = $tpl->_ENGINE_parse_body(button("{groups2}", "Loadjs('domains.edit.group.php?ou={$ou_encoded}&js=yes')"));
    $ou = urlencode($ou);
    echo $boot->SearchFormGen(null, "search-users", "&ou={$ou}", $EXPLAIN);
}
Exemplo n.º 19
0
function page()
{
    $page = CurrentPageName();
    $tpl = new templates();
    $sock = new sockets();
    $boot = new boostrap_form();
    $rescan = $tpl->_ENGINE_parse_body("{rescan}");
    $button = button($rescan, "rescan{$t}()", 16);
    //$OPTIONS["BUTTONS"][]=$button;
    $SearchQuery = $boot->SearchFormGen("description", "search-records", null, array());
    echo $SearchQuery;
}
Exemplo n.º 20
0
function page()
{
    $page = CurrentPageName();
    $tpl = new templates();
    $sock = new sockets();
    $boot = new boostrap_form();
    $t = time();
    $rescan = $tpl->_ENGINE_parse_body("{rescan}");
    $button = button($rescan, "rescan{$t}()", 16);
    $OPTIONS["BUTTONS"][] = $button;
    $SearchQuery = $boot->SearchFormGen("hostname,ipaddr,mac", "search-records", null, $OPTIONS);
    echo $SearchQuery . "\n\t\t\t<script>\n\t\t\t\tfunction rescan{$t}(){\n\t\t\t\t\tLoadjs('dhcpd.leases.php?action-rescan=yes');\n\t\t\t\t}\n\t\t\t</script>\n\t\t\t\n\t\t\t";
}
function section_sessions()
{
    $page = CurrentPageName();
    $tpl = new templates();
    $boot = new boostrap_form();
    $sock = new sockets();
    $t = time();
    $ID = $_GET["parent-options"];
    $new_account = $tpl->_ENGINE_parse_body("{new_account}");
    $EXPLAIN["BUTTONS"][] = $tpl->_ENGINE_parse_body(button("{$new_account}", "YahooWin4('600','miniadmin.hotspot.php?uid=&t={$t}','{$new_account}');"));
    unset($EXPLAIN);
    echo $boot->SearchFormGen("uid", "search-sessions", "", $EXPLAIN);
}
function content()
{
    $sock = new sockets();
    $boot = new boostrap_form();
    $tpl = new templates();
    $page = CurrentPageName();
    $t = time();
    $button = button("{link_mac_to_uid}", "NewMacLink{$t}()", 16);
    $button2 = button("{apply_changes}", "Apply{$t}()", 16);
    $SearchQuery = $boot->SearchFormGen("MAC,uid,hostname", "search-records");
    $apply_changes_mactouid_explain = $tpl->javascript_parse_text("{apply_changes_mactouid_explain}");
    $html = "\n\t<div class=text-info>{mactouid_explain}</div>\n\t<table style='width:100%'>\n\t<tr>\n\t<td>{$button} {$button2}</td>\n\t<td></td>\n\t</tr>\n\t</table>\n\t{$SearchQuery}\n\t<script>\n\tExecuteByClassName('SearchFunction');\n\t\n\tfunction NewMacLink{$t}(){\n\t\tLoadjs('{$page}?NewMacLink-js=yes')\n\t\n\t}\n\tvar x_Apply{$t}= function (obj) {\n\t\tvar results=obj.responseText;\n\t\tif(results.length>3){alert(results);}\n\t}\t\t\n\t\n\tfunction Apply{$t}(){\n\t\tif(!confirm('{$apply_changes_mactouid_explain}')){return;}\n\t\tvar XHR = new XHRConnection();\n\t\tXHR.appendData('apply-changes','yes');\n\t\tXHR.sendAndLoad('{$page}', 'POST',x_Apply{$t});\t\t\t\n\t\t\n\t}\n\t\n\t</script>\n\t";
    echo $tpl->_ENGINE_parse_body($html);
}
Exemplo n.º 23
0
function content()
{
    $q = new mysql();
    $tpl = new templates();
    $t = time();
    $page = CurrentPageName();
    if (!$q->TABLE_EXISTS("records", "powerdns")) {
        echo $tpl->_ENGINE_parse_body(FATAL_ERROR_SHOW_128("{error_missing_tables_click_to_repair}") . "\n\t\t<hr>\n\t\t<center id='{$t}'>" . button("{repair}", "RepairPDNSTables()", "22px") . "</center>\n\t\t<script>\n\tvar x_RepairPDNSTables=function (obj) {\n\t\t\tvar results=obj.responseText;\n\t\t\tif(results.length>0){alert(results);}\n\t\t\tMyHref('{$page}');\n\t}\n\tfunction RepairPDNSTables(){\n\t\tvar XHR = new XHRConnection();\n\t\tXHR.appendData('RepairPDNSTables','yes');\n\t\tAnimateDiv('{$t}');\n\t\tXHR.sendAndLoad('pdns.mysql.php', 'POST',x_RepairPDNSTables);\n\t}\n\t</script>\n\t");
        return;
    }
    $sock = new sockets();
    $boot = new boostrap_form();
    $button = button("{new_item}", "NewPDNSEntry2()", 16);
    $SearchQuery = $boot->SearchFormGen("name,content,explainthis", "search-records");
    $EnablePDNS = $sock->GET_INFO("EnablePDNS");
    if (!is_numeric($EnablePDNS)) {
        $EnablePDNS = 0;
    }
    if ($EnablePDNS == 0) {
        $error = "<div class=text-infoWarn>{EnablePDNS_disable_text}</div>";
    }
    $html = "\n\t {$error}\n\t <table style='width:100%'>\n\t <tr>\n\t <td>{$button}</td>\n\t <td></td>\n\t </tr>\n\t </table>\n\t {$SearchQuery}\n\t <script>\n\t \tExecuteByClassName('SearchFunction');\n\t </script>\n\t ";
    echo $tpl->_ENGINE_parse_body($html);
}
Exemplo n.º 24
0
function table_all_videos()
{
    $page = CurrentPageName();
    $tpl = new templates();
    $t = time();
    $boot = new boostrap_form();
    $_GET["member-value"] = urlencode($_GET["member-value"]);
    $LINKS["LINKS"][] = array("LABEL" => "{advanced_search}", "JS" => "Loadjs('{$page}?videos-search-js=yes')");
    $form = $boot->SearchFormGen("title", "videos-search", null, $LINKS);
    echo $form;
}
function section_table_sites()
{
    $suffix = suffix();
    $page = CurrentPageName();
    $tpl = new templates();
    $t = time();
    $boot = new boostrap_form();
    $form = $boot->SearchFormGen("zDate", "category-search", $suffix);
    echo $form;
}
function section_members_sites()
{
    $suffix = suffix();
    $page = CurrentPageName();
    $tpl = new templates();
    $t = time();
    $boot = new boostrap_form();
    $form = $boot->SearchFormGen("uid", "uid-search", $suffix);
    echo $form;
}
Exemplo n.º 27
0
function section_webrules()
{
    $page = CurrentPageName();
    $tpl = new templates();
    $refresh_pattern_intro = $tpl->_ENGINE_parse_body("{refresh_pattern_intro}");
    if (!$_SESSION["CORP"]) {
        $tpl = new templates();
        $onlycorpavailable = $tpl->_ENGINE_parse_body("{onlycorpavailable}");
        $content = "<div class=text-info style='font-size:16px'>{$refresh_pattern_intro}</div> <p class=text-error>{$onlycorpavailable}</p>";
        echo $content;
        return;
    }
    $t = time();
    $boot = new boostrap_form();
    $EXPLAIN["BUTTONS"][] = $tpl->_ENGINE_parse_body(button("{new_rule}", "Loadjs('{$page}?section_webrules_add_js=yes')"));
    $EXPLAIN["BUTTONS"][] = $tpl->_ENGINE_parse_body(button("{apply}", "Loadjs('squid.restart.php?onlySquid=yes&ApplyConfToo=yes');"));
    echo $tpl->_ENGINE_parse_body("<div class=text-info style='font-size:16px'>{$refresh_pattern_intro}</div>") . $boot->SearchFormGen("sitename", "search-webrules", null, $EXPLAIN);
}
function items_section()
{
    $boot = new boostrap_form();
    $tpl = new templates();
    $page = CurrentPageName();
    $error = null;
    $EXPLAIN["BUTTONS"][] = $tpl->_ENGINE_parse_body(button("{new_item}", "Loadjs('{$page}?js-item=yes&ID=0&groupid={$_GET["groupid"]}&servername={$_GET["servername"]}')"));
    echo $boot->SearchFormGen("pattern", "items-search", "&servername={$_GET["servername"]}&groupid={$_GET["groupid"]}", $EXPLAIN);
}
function webstats_middle_table()
{
    $page = CurrentPageName();
    $tpl = new templates();
    $users = new usersMenus();
    $TB_HEIGHT = 500;
    $TB_WIDTH = 910;
    $uid = $_GET["uid"];
    $boot = new boostrap_form();
    $tablename_members = date("Ymd", $_GET["xtime"]) . "_members";
    if ($_GET["FILTER"] == null) {
        $_GET["FILTER"] = which_filter($tablename_members);
    }
    $SearchQuery = $boot->SearchFormGen("{$_GET["FILTER"]}", "items", "&t={$_GET["t"]}&uid={$uid}&year={$_GET["year"]}&month={$_GET["month"]}&day={$_GET["day"]}&tablename={$_GET["tablename"]}&xtime={$_GET["xtime"]}&FILTER={$_GET["FILTER"]}");
    echo $SearchQuery;
}
Exemplo n.º 30
0
function today()
{
    $boot = new boostrap_form();
    echo $boot->SearchFormGen("uid,ipaddr,sitename,words", "search-today");
}