function show_admins($user, $teamid) { page_head("Add or remove Team Admins"); echo "\n\t\tYou can select team members as 'Team Admins'.\n\t\tTeam Admins can:\n\t\t<ul>\n\t\t<li>Edit team information (name, URL, description, country).</li>\n\t\t<li>View the team's join/quit history.</li>\n\t\t<li>Moderate the team forum, if any (admins get emails notification of moderation events and red X reports).</li>\n\t\t</ul>\n\t\tTeam Admins cannot:\n\t\t<ul>\n\t\t<li>Change the team founder.</li>\n\t\t<li>Remove members.</li>\n\t\t<li>Add or remove Team Admins.</li>\n\t\t</ul>\n\t\tIf a Team Admin quits the team, they cease to be a Team Admin.\n\t\t<p>\n\t\tWe recommend that you select only people\n\t\tyou know and trust very well as Team Admins.\n\t"; $admins = BoincTeamAdmin::enum("teamid={$teamid}"); start_table(); if (count($admins) == 0) { row1("There are currently no Team Admins"); } else { row1("Current Team Admins", 3); table_header("Name", "Became Team Admin on", ""); foreach ($admins as $admin) { show_admin($user, $admin); } } end_table(); echo ' <p> <form action="team_admins.php"> <input type="hidden" name="action" value="add"> <input type="hidden" name="teamid" value="$teamid"> '; echo form_tokens($user->authenticator); start_table(); row1("Add Team Admin"); row2('Email address of team member:', '<input name="email_addr">'); row2('', '<input type="submit" action value="Add">'); end_table(); echo "</form>"; page_tail(); }
function show_admins($user, $teamid) { page_head(tra("Add or remove Team Admins")); echo tra("You can select team members as 'Team Admins'. Team Admins can:") . "\n <ul>\n <li>" . tra("Edit team information (name, URL, description, country)") . "\n <li>" . tra("View the team's join/quit history") . "\n <li>" . tra("Moderate the team forum, if any (admins get email notification of moderation events and red X reports)") . "\n </ul>\n " . tra("Team Admins cannot:") . "\n <ul>\n <li>" . tra("Change the team founder") . "\n <li>" . tra("Remove members") . "\n <li>" . tra("Add or remove Team Admins") . "\n </ul>\n " . tra("If a Team Admin quits the team, they cease to be a Team Admin.") . "\n <br /><br />" . tra("We recommend that you select only people you know and trust very well as Team Admins."); $admins = BoincTeamAdmin::enum("teamid={$teamid}"); start_table(); if (count($admins) == 0) { row1(tra("There are currently no Team Admins")); } else { row1(tra("Current Team Admins"), 3); table_header(tra("Name"), tra("Became Team Admin on"), ""); foreach ($admins as $admin) { show_admin($user, $admin); } } end_table(); echo "\n <p>\n <form action=team_admins.php>\n <input type=hidden name=action value=add>\n <input type=hidden name=teamid value={$teamid}>\n "; echo form_tokens($user->authenticator); start_table(); row1(tra("Add Team Admin")); row2(tra("Email address of team member:"), "<input name=email_addr>"); row2("", "<input type=submit action value=\"" . tra("Add") . "\">"); end_table(); echo "</form>"; page_tail(); }
break; //------------------------------------------------------------------------------ // CREATE ARCHIVE //------------------------------------------------------------------------------ // CREATE ARCHIVE case "arch": require "./.include/fun_archive.php"; archive_items($GLOBALS["dir"]); break; //------------------------------------------------------------------------------ // USER-ADMINISTRATION //------------------------------------------------------------------------------ // USER-ADMINISTRATION case "admin": require "./.include/fun_admin.php"; show_admin($GLOBALS["dir"]); break; //------------------------------------------------------------------------------ // DEFAULT: LIST FILES & DIRS //------------------------------------------------------------------------------ // DEFAULT: LIST FILES & DIRS case "list": default: require "./.include/fun_list.php"; list_dir($GLOBALS["dir"]); //------------------------------------------------------------------------------ } // end switch-statement //------------------------------------------------------------------------------ show_footer(); //------------------------------------------------------------------------------
break; //------------------------------------------------------------------------------ // SEARCH FOR FILE(S)/DIR(S) //------------------------------------------------------------------------------ // SEARCH FOR FILE(S)/DIR(S) case "search": require_once _EXT_PATH . "/include/search.php"; search_items($dir); break; //------------------------------------------------------------------------------ // USER-ADMINISTRATION //------------------------------------------------------------------------------ // USER-ADMINISTRATION case "admin": require_once _EXT_PATH . "/include/admin.php"; show_admin($dir); break; //------------------------------------------------------------------------------ // BOOKMARKS //------------------------------------------------------------------------------ // BOOKMARKS case 'modify_bookmark': $task = extGetParam($_REQUEST, 'task'); require_once _EXT_PATH . '/include/bookmarks.php'; modify_bookmark($task, $dir); break; //------------------------------------------------------------------------------ //------------------------------------------------------------------------------ case 'show_error': ext_Result::sendResult('', false, ''); break;
// SEARCH FOR FILE(S)/DIR(S) case "search": require "./_include/search.php"; search_items($current_dir); break; // CREATE ARCHIVE // CREATE ARCHIVE case "arch": require "./_include/archive.php"; archive_items($current_dir); break; // USER-ADMINISTRATION // USER-ADMINISTRATION case "admin": require "./_include/admin.php"; show_admin($current_dir); break; case "login": _debug("doing login"); login(); require "./_include/list.php"; list_dir($current_dir); break; case "logout": _debug("doing logout"); logout(); // DEFAULT: LIST FILES & DIRS // DEFAULT: LIST FILES & DIRS case "list": default: require "./_include/list.php";