diff options
author | Paul S. Owen <psotfx@users.sourceforge.net> | 2001-07-13 17:03:04 +0000 |
---|---|---|
committer | Paul S. Owen <psotfx@users.sourceforge.net> | 2001-07-13 17:03:04 +0000 |
commit | 813016d706d57d5ebd0ca5dd947ac921d3333373 (patch) | |
tree | 3fc6c61ef7e531959a9d020dda391fe6b3184237 /phpBB/admin | |
parent | 8e49899bce210323dae4626138d5465b68c4fc58 (diff) | |
download | forums-813016d706d57d5ebd0ca5dd947ac921d3333373.tar forums-813016d706d57d5ebd0ca5dd947ac921d3333373.tar.gz forums-813016d706d57d5ebd0ca5dd947ac921d3333373.tar.bz2 forums-813016d706d57d5ebd0ca5dd947ac921d3333373.tar.xz forums-813016d706d57d5ebd0ca5dd947ac921d3333373.zip |
Didnt I commit these?
git-svn-id: file:///svn/phpbb/trunk@650 89ea8834-ac86-4346-8a33-228a782c2dd0
Diffstat (limited to 'phpBB/admin')
-rw-r--r-- | phpBB/admin/admin_board.php | 8 | ||||
-rw-r--r-- | phpBB/admin/admin_forumauth.php | 10 | ||||
-rw-r--r-- | phpBB/admin/admin_forums.php | 15 | ||||
-rw-r--r-- | phpBB/admin/admin_groupauth.php | 30 | ||||
-rw-r--r-- | phpBB/admin/admin_userauth.php | 48 | ||||
-rw-r--r-- | phpBB/admin/admin_users.php | 13 | ||||
-rw-r--r-- | phpBB/admin/index.php | 59 |
7 files changed, 115 insertions, 68 deletions
diff --git a/phpBB/admin/admin_board.php b/phpBB/admin/admin_board.php index d9a7e05c07..5c5783d3ef 100644 --- a/phpBB/admin/admin_board.php +++ b/phpBB/admin/admin_board.php @@ -25,15 +25,19 @@ if($setmodules==1) { $file = basename(__FILE__); - $module['board']['config'] = $file; + $module['General']['config'] = $file; //$module['users']['edit'] = $file.'?mode=edit'; //$module['users']['delete'] = $file.'?mode=delete'; + return; } print "Got past the \$setmodules check<br>\n"; print "Requested action was: $mode<br>\n"; +$phpbb_root_path = "./../"; +include($phpbb_root_path . 'extension.inc'); +include($phpbb_root_path . 'common.'.$phpEx); -?> +?>
\ No newline at end of file diff --git a/phpBB/admin/admin_forumauth.php b/phpBB/admin/admin_forumauth.php index cfb3e34c8b..b845f5143a 100644 --- a/phpBB/admin/admin_forumauth.php +++ b/phpBB/admin/admin_forumauth.php @@ -7,11 +7,9 @@ if($setmodules==1) return; } - -chdir("../"); - -include('extension.inc'); -include('common.'.$phpEx); +$phpbb_root_path = "./../"; +include($phpbb_root_path . 'extension.inc'); +include($phpbb_root_path . 'common.'.$phpEx); // // Start session management @@ -424,4 +422,4 @@ Copyright © 2001 phpBB Group, All Rights Reserved</font> <br> </body> -</html> +</html>
\ No newline at end of file diff --git a/phpBB/admin/admin_forums.php b/phpBB/admin/admin_forums.php index 87c7eec98e..171ab3e9ae 100644 --- a/phpBB/admin/admin_forums.php +++ b/phpBB/admin/admin_forums.php @@ -22,18 +22,21 @@ * ***************************************************************************/ -if($setmodules==1) +if( $setmodules == 1 ) { $filename = basename(__FILE__); - $module['forums']['add'] = "$filename?mode=add"; - $module['forums']['edit'] = "$filename?mode=edit"; - $module['forums']['delete'] = "$filename?mode=delete"; + $module['Forums']['add'] = "$filename?mode=add"; + $module['Forums']['edit'] = "$filename?mode=edit"; + $module['Forums']['delete'] = "$filename?mode=delete"; + return; } print "Got past the \$setmodules check<br>\n"; print "Requested action was: $mode<br>\n"; +$phpbb_root_path = "./../"; +include($phpbb_root_path . 'extension.inc'); +include($phpbb_root_path . 'common.'.$phpEx); - -?> +?>
\ No newline at end of file diff --git a/phpBB/admin/admin_groupauth.php b/phpBB/admin/admin_groupauth.php index f780e3f52c..e69aa3f637 100644 --- a/phpBB/admin/admin_groupauth.php +++ b/phpBB/admin/admin_groupauth.php @@ -1,9 +1,16 @@ <?php -chdir("../"); +if($setmodules == 1) +{ + $filename = basename(__FILE__); + $module['Auth']['groups'] = $filename; + + return; +} -include('extension.inc'); -include('common.'.$phpEx); +$phpbb_root_path = "./../"; +include($phpbb_root_path . 'extension.inc'); +include($phpbb_root_path . 'common.'.$phpEx); // // Start session management @@ -41,7 +48,6 @@ $forum_auth_key_fields = array("auth_view", "auth_read", "auth_post", "auth_repl // function a_auth_check_user($type, $key, $u_auth, $is_admin) { - $single_user = 0; $auth_user = array(); @@ -365,9 +371,11 @@ else if(empty($HTTP_GET_VARS[POST_GROUPS_URL])) $select_list .= "</select>"; $template->set_filenames(array( - "body" => "admin/userauth_select_body.tpl")); + "body" => "admin/ug_auth_select_body.tpl")); $template->assign_vars(array( + "L_USER_OR_GROUP" => "Group", + "S_USERAUTH_ACTION" => append_sid("admin_groupauth.$phpEx"), "S_USERS_SELECT" => $select_list, @@ -386,7 +394,7 @@ else if(empty($HTTP_GET_VARS[POST_GROUPS_URL])) // $template->set_filenames(array( - "body" => "admin/userauth_body.tpl") + "body" => "admin/ug_auth_body.tpl") ); $group_id = $HTTP_GET_VARS[POST_GROUPS_URL]; @@ -621,14 +629,20 @@ if($adv == -1) } else { - $t_username_list = "has no members."; + $t_username_list = "<b>Has no members</b>"; } $s_hidden_fields = "<input type=\"hidden\" name=\"" . POST_GROUPS_URL . "\" value=\"$group_id\">"; $template->assign_vars(array( "USERNAME" => $t_groupname, - "USER_GROUP_LIST" => $t_username_list, + "USER_GROUP_MEMBERSHIPS" => "This group has the following members: $t_username_list", + + "L_USER_OR_GROUPNAME" => "Groupname", + "L_USER_OR_GROUP" => "Group", + + "U_USER_OR_GROUP" => append_sid("admin_groupauth.$phpEx"), + "U_FORUMAUTH" => append_sid("admin_forumauth.$phpEx"), "S_USER_AUTH_ACTION" => append_sid("admin_groupauth.$phpEx"), "S_HIDDEN_FIELDS" => $s_hidden_fields) diff --git a/phpBB/admin/admin_userauth.php b/phpBB/admin/admin_userauth.php index e2429b6f36..fc4db47f13 100644 --- a/phpBB/admin/admin_userauth.php +++ b/phpBB/admin/admin_userauth.php @@ -1,16 +1,16 @@ <?php -if($setmodules==1) +if($setmodules == 1) { $filename = basename(__FILE__); - $module['Auth']['users'] = $filename; + $module['Auth']['users'] = $filename; + return; } -chdir("../"); - -include('extension.inc'); -include('common.'.$phpEx); +$phpbb_root_path = "./../"; +include($phpbb_root_path . 'extension.inc'); +include($phpbb_root_path . 'common.'.$phpEx); // // Start session management @@ -400,8 +400,8 @@ if(isset($HTTP_POST_VARS['submit']) && !empty($HTTP_POST_VARS[POST_USERS_URL])) } } -// print_r($valid_auth_acl_sql); -// echo "<BR><BR>"; + print_r($valid_auth_acl_sql); + echo "<BR><BR>"; // // The next part requires that we know whether we're @@ -435,6 +435,8 @@ if(isset($HTTP_POST_VARS['submit']) && !empty($HTTP_POST_VARS[POST_USERS_URL])) } } +exit; + header("Location: admin_userauth.$phpEx?" . POST_USERS_URL . "=$user_id"); } @@ -449,8 +451,8 @@ else if(empty($HTTP_GET_VARS[POST_USERS_URL])) // $sql = "SELECT user_id, username - FROM ".USERS_TABLE . " - WHERE user_id != " . ANONYMOUS; + FROM " . USERS_TABLE . " + WHERE user_id <> " . ANONYMOUS; $u_result = $db->sql_query($sql); $user_list = $db->sql_fetchrowset($u_result); @@ -462,10 +464,12 @@ else if(empty($HTTP_GET_VARS[POST_USERS_URL])) $select_list .= "</select>"; $template->set_filenames(array( - "body" => "admin/userauth_select_body.tpl")); + "body" => "admin/ug_auth_select_body.tpl")); $template->assign_vars(array( - "S_USERAUTH_ACTION" => append_sid("admin_userauth.$phpEx"), + "L_USER_OR_GROUP" => "User", + + "S_USERAUTH_ACTION" => append_sid("admin_userauth.$phpEx"), "S_USERS_SELECT" => $select_list, "U_FORUMAUTH" => append_sid("admin_forumauth.$phpEx")) @@ -483,7 +487,7 @@ else if(empty($HTTP_GET_VARS[POST_USERS_URL])) // $template->set_filenames(array( - "body" => "admin/userauth_body.tpl") + "body" => "admin/ug_auth_body.tpl") ); $user_id = $HTTP_GET_VARS[POST_USERS_URL]; @@ -714,7 +718,7 @@ if($adv == -1) $t_usergroup_list = ""; for($i = 0; $i < count($userinf); $i++) { - $t_usergroup_list .= "<a href=\"groupauth.$phpEx?" . POST_GROUPS_URL . "=" . $group_id[$i] . "\">" . $group_name[$i] . "</a>"; + $t_usergroup_list .= "<a href=\"admin_groupauth.$phpEx?" . POST_GROUPS_URL . "=" . $group_id[$i] . "\">" . $group_name[$i] . "</a>"; if($i < count($group_name) - 1) { $t_usergroup_list .= ", "; @@ -723,19 +727,23 @@ if($adv == -1) } else { - $t_usergroup_list = "belongs to no usergroups."; + $t_usergroup_list = "None"; } $s_hidden_fields = "<input type=\"hidden\" name=\"" . POST_USERS_URL . "\" value=\"$user_id\">"; $s_hidden_fields .= "<input type=\"hidden\" name=\"curadmin\" value=\"" . $is_admin ."\">"; - $s_hidden_fields .= "<input type=\"hidden\" name=\"" . POST_GROUPS_URL . "\" value=\"" . "\">"; $template->assign_vars(array( "USERNAME" => $t_username, - "USER_GROUP_LIST" => $t_usergroup_list, - + "USER_GROUP_MEMBERSHIPS" => "This user is a $s_user_type and belongs to the following groups: $t_usergroup_list", + + "L_USER_OR_GROUPNAME" => "Username", + "L_USER_OR_GROUP" => "User", + + "U_USER_OR_GROUP" => append_sid("admin_userauth.$phpEx"), + "U_FORUMAUTH" => append_sid("admin_forumauth.$phpEx"), + "S_USER_AUTH_ACTION" => append_sid("admin_userauth.$phpEx"), - "S_USER_TYPE_SELECT" => $s_user_type, "S_HIDDEN_FIELDS" => $s_hidden_fields) ); @@ -745,4 +753,4 @@ $template->pparse("body"); exit; -?> +?>
\ No newline at end of file diff --git a/phpBB/admin/admin_users.php b/phpBB/admin/admin_users.php index b4278d1182..10cf6a3f1a 100644 --- a/phpBB/admin/admin_users.php +++ b/phpBB/admin/admin_users.php @@ -22,6 +22,17 @@ * ***************************************************************************/ +if($setmodules == 1) +{ + $filename = basename(__FILE__); + $module['Users']['users'] = $filename; + return; +} -?> + +$phpbb_root_path = "./../"; +include($phpbb_root_path . 'extension.inc'); +include($phpbb_root_path . 'common.'.$phpEx); + +?>
\ No newline at end of file diff --git a/phpBB/admin/index.php b/phpBB/admin/index.php index b729480dd1..a35dd2a71f 100644 --- a/phpBB/admin/index.php +++ b/phpBB/admin/index.php @@ -22,45 +22,53 @@ * ***************************************************************************/ -chdir("../"); -include('extension.inc'); -include('common.'.$phpEx); +$phpbb_root_path = "./../"; +include($phpbb_root_path . 'extension.inc'); +include($phpbb_root_path . 'common.'.$phpEx); + +// +// Start session management +// $userdata = session_pagestart($user_ip, PAGE_INDEX, $session_length); init_userprefs($userdata); - +// +// End sessionmanagement +// if ($pane == 'top') { $page_title = $lang['View_topic'] ." - $topic_title"; $pagetype = "viewtopic"; - include('includes/page_header.'.$phpEx); + + include($phpbb_root_path . 'includes/page_header.'.$phpEx); + } elseif ($pane == 'left') { print "<BASE TARGET=\"main\">"; - // Hmm, should we make this variable? - chdir('admin/'); $dir = opendir("."); - $setmodules=1; + $setmodules = 1; while($file = readdir($dir)) { - if(preg_match("/^admin_.*/", $file)) - { - //print "$file<br>\n"; - include($file); - } + if(preg_match("/^admin_.*/", $file)) + { + //print "$file<br>\n"; + include($file); + } } - while(list($cat, $action_array) = each($module)) + while( list($cat, $action_array) = each($module) ) { - print "<H3>$cat</H3>\n"; - print "<ul>\n"; - while(list($action, $file) = each($action_array)) - { - print "<li><a href=\"$file\">$action</a></li>\n"; - } - print "</ul>\n"; + print "<H3>$cat</H3>\n"; + print "<ul>\n"; + + while( list($action, $file) = each($action_array) ) + { + print "<li><a href=\"$file\">$action</a></li>\n"; + } + + print "</ul>\n"; } //var_dump($module); @@ -69,12 +77,14 @@ elseif ($pane == 'left') elseif ($pane == 'right') { - echo "This the right pane ;)"; } else -{ // Generate frameset +{ + +// Generate frameset + ?> <html> <head> @@ -98,5 +108,4 @@ else } - -?> +?>
\ No newline at end of file |