function admin() { if (!is_admin()) { soft_error(_('You must be logged in as an admin.')); } return tag('div', options_form(), new_user_form()); }
if ($svr) { $src = array("{SERVER}"); $dst = array($svr); echo "<p>" . str_replace($src, $dst, _AM_FETCH_DESCRIPTION) . "</p>"; } echo "</fieldset>\n"; reglist_packages(); break; case 'detail': $view = isset($_GET['view']) ? $_GET['view'] : false; $new = isset($_GET['new']) ? intval($_GET['new']) : 0; detail_package(intval($_GET['pkgid']), $view, $new); break; case 'opts': // options select in a package options_form(); break; } xoops_cp_footer(); // bind current installed and HEAD function check_packages() { global $xoopsDB, $xoopsModuleConfig, $xoopsConfig; $res = $xoopsDB->query("SELECT p1.*, p2.vcheck dirname, p2.pversion ppversion FROM " . UPDATE_PKG . " p1 LEFT JOIN " . UPDATE_PKG . " p2 ON p1.parent=p2.pkgid WHERE p1.pversion='HEAD' ORDER BY p1.vcheck"); $pkgs = get_packages('all', false); echo "<h3>" . _AM_CHECK_LIST . "</h3>\n"; echo "<table cellspacing='1' class='outer'>\n"; echo "<tr><th>" . _AM_PKG_PNAME . "</th><th>" . _AM_PKG_CURRENT . "</th><th>" . _AM_PKG_DIRNAME . "</th><th>" . _AM_PKG_NEW . "</th><th>" . _AM_PKG_DTIME . "</th><th>" . _AM_CHANGES . "</th><th>" . _AM_MODIFYS . "</th><th></th></tr>\n"; $n = 0; $update = false; // find update package?