From 939c01e410286691fd80029bed811406ede3f1e5 Mon Sep 17 00:00:00 2001 From: plegall Date: Fri, 19 Aug 2005 17:00:20 +0000 Subject: - improvement : standardization of categories navigation bar on top of administration screen element_set_(global|unit), cat_modify, cat_list, cat_perm. - new : direct link to admin/cat_modify from category.php. git-svn-id: http://piwigo.org/svn/trunk@834 68402e56-0260-453c-a942-63ccdbb3a9ee --- category.php | 29 ++++++++++++++++++++++++++--- 1 file changed, 26 insertions(+), 3 deletions(-) (limited to 'category.php') diff --git a/category.php b/category.php index 9c597b23a..cfef60065 100644 --- a/category.php +++ b/category.php @@ -171,8 +171,7 @@ $template->assign_vars(array( 'U_REGISTER' => add_session_id( PHPWG_ROOT_PATH.'register.php' ), 'U_LOGOUT' => PHPWG_ROOT_PATH.'category.php?act=logout', 'U_ADMIN'=>add_session_id( PHPWG_ROOT_PATH.'admin.php' ), - 'U_PROFILE'=>add_session_id(PHPWG_ROOT_PATH.'profile.php'), - 'U_CADDIE'=>add_session_id(PHPWG_ROOT_PATH.'category.php'.get_query_string_diff(array('caddie')).'&caddie=1') + 'U_PROFILE'=>add_session_id(PHPWG_ROOT_PATH.'profile.php') ) ); //-------------------------------------------------------------- external links @@ -313,6 +312,22 @@ $template->assign_block_vars( 'U_SUMMARY'=>add_session_id(PHPWG_ROOT_PATH.'notification.php') )); +if (isset($page['cat']) + and is_numeric($page['cat']) + and 'admin' == $user['status']) +{ + $template->assign_block_vars( + 'edit', + array( + 'URL' => + add_session_id( + PHPWG_ROOT_PATH.'admin.php?page=cat_modify' + .'&cat_id='.$page['cat'] + ) + ) + ); +} + //------------------------------------------------------ main part : thumbnails if (isset($page['cat']) and ((is_numeric($page['cat']) and $page['cat_nb_images'] != 0) @@ -329,7 +344,15 @@ if (isset($page['cat']) if ('admin' == $user['status']) { - $template->assign_block_vars('caddie', array()); + $template->assign_block_vars( + 'caddie', + array( + 'URL' => + add_session_id( + PHPWG_ROOT_PATH.'category.php' + .get_query_string_diff(array('caddie')).'&caddie=1') + ) + ); } } elseif (isset($page['cat']) and $page['cat'] == 'calendar') -- cgit v1.2.3