check_user_permissions('manage_categories'); global $wp_http_referer, $user_ID, $wp_roles; if ( file_exists( ABSPATH . 'wp-admin/admin-functions.php' ) ) require_once( ABSPATH . 'wp-admin/admin-functions.php' ); else require_once( ABSPATH . 'wp-admin/includes/taxonomy.php' ); $cat_ID = (int) $_GET['cat_ID']; $category = get_category_to_edit($cat_ID); if ( !empty($cat_ID) ) { $heading = __('Edit Category'); $submit_text = __('Edit Category »'); $action = 'editedcat'; $form_id = 'editcat'; $nonce_action = 'update-category_' . $cat_ID; do_action('edit_category_form_pre', $category); if ( $this->iscompat ) $selected_form = ' selected="true"'; } else { $heading = __('Add Category'); $submit_text = __('Add Category »'); $action = 'addcat'; $form_id = $action; $nonce_action = 'add-category'; do_action('add_category_form_pre', $category); } if ( ! $this->iscompat ) { // note we need this one conditional because the same form is used in multiple contexts echo '

' . $form_title . "

\n"; } ?>
>



cat_ID . '&hide_empty=0&class=widefield&orderby=name&hierarchical=1&name=category_parent&orderby=name&hierarchical=1&selected=' . $category->category_parent . '&hierarchical=1&show_option_none=' . __('None')); ?>

panel_button( 'submit', 'submit', $submit_text ); if ($this->context == 'edit') { $default_cat_id = (int) get_option( 'default_category' ); $default_link_cat_id = (int) get_option( 'default_link_category' ); $question = sprintf( __("You are about to delete the category '%s'.\nAll posts that were only assigned to this category will be assigned to the '%s' category.\nAll links that were only assigned to this category will be assigned to the '%s' category.\n'OK' to delete, 'Cancel' to stop." ), $category->name, get_catname( $default_cat_id ), get_catname( $default_link_cat_id ) ); $url = wp_nonce_url( "categories.php?action=delete&cat_ID=$category->term_id", 'delete-category_' . $category->term_id ); $this->panel_delete_button(__('Delete'), $question, $url ); } ?>