WordPress.org

Make WordPress Core

Changeset 15141


Ignore:
Timestamp:
06/04/10 19:18:09 (4 years ago)
Author:
ryan
Message:

Don't call wp_tag_cloud() at all for hierarchical taxonomies.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-admin/edit-tags.php

    r15140 r15141  
    356356 
    357357<?php 
    358 if ( current_user_can( $tax->cap->edit_terms ) ) 
    359     $tag_cloud = wp_tag_cloud( array( 'taxonomy' => $taxonomy, 'echo' => false, 'link' => 'edit' ) ); 
    360 else 
    361     $tag_cloud = wp_tag_cloud( array( 'taxonomy' => $taxonomy, 'echo' => false ) ); 
    362  
    363 if ( $tag_cloud && !is_taxonomy_hierarchical($taxonomy) ) : 
    364 ?> 
     358 
     359if ( !is_taxonomy_hierarchical($taxonomy) ) { 
     360    if ( current_user_can( $tax->cap->edit_terms ) ) 
     361        $tag_cloud = wp_tag_cloud( array( 'taxonomy' => $taxonomy, 'echo' => false, 'link' => 'edit' ) ); 
     362    else 
     363        $tag_cloud = wp_tag_cloud( array( 'taxonomy' => $taxonomy, 'echo' => false ) ); 
     364 
     365    if ( $tag_cloud ) : 
     366    ?> 
    365367<div class="tagcloud"> 
    366368<h3><?php echo $tax->labels->popular_items; ?></h3> 
     
    369371<?php 
    370372endif; 
     373} 
    371374 
    372375if ( current_user_can($tax->cap->edit_terms) ) { 
Note: See TracChangeset for help on using the changeset viewer.