Exemple #1
0
         }
     }
     if ($ret && !is_wp_error($ret)) {
         $location = add_query_arg('message', 3, $location);
     } else {
         $location = add_query_arg('message', 5, $location);
     }
     wp_redirect($location);
     exit;
     break;
 default:
     if (!empty($_REQUEST['_wp_http_referer'])) {
         wp_redirect(remove_query_arg(array('_wp_http_referer', '_wpnonce'), stripslashes($_SERVER['REQUEST_URI'])));
         exit;
     }
     $wp_list_table->prepare_items();
     wp_enqueue_script('admin-tags');
     if (current_user_can($tax->cap->edit_terms)) {
         wp_enqueue_script('inline-edit-tax');
     }
     if ('category' == $taxonomy || 'post_tag' == $taxonomy) {
         if ('category' == $taxonomy) {
             $help = '<p>' . sprintf(__('You can use categories to define sections of your site and group related posts. The default category is &#8220;Uncategorized&#8221; until you change it in your <a href="%s">writing settings</a>.'), 'options-writing.php') . '</p>';
         } else {
             $help = '<p>' . __('You can assign keywords to your posts using Post Tags. Unlike categories, tags have no hierarchy, meaning there&#8217;s no relationship from one tag to another.') . '</p>';
         }
         $help .= '<p>' . __('What&#8217;s the difference between categories and tags? Normally, tags are ad-hoc keywords that identify important information in your post (names, subjects, etc) that may or may not recur in other posts, while categories are pre-determined sections. If you think of your site like a book, the categories are like the Table of Contents and the tags are like the terms in the index.') . '</p>';
         if ('category' == $taxonomy) {
             $help .= '<p>' . __('When adding a new category on this screen, you&#8217;ll fill in the following fields:') . '</p>';
         } else {
             $help .= '<p>' . __('When adding a new tag on this screen, you&#8217;ll fill in the following fields:') . '</p>';