Make WordPress Core

Ticket #5172: category-template.php.diff

File category-template.php.diff, 1.0 KB (added by chmac, 16 years ago)
  • category-template.php

    old new  
    372372
    373373        $rel = ( is_object($wp_rewrite) && $wp_rewrite->using_permalinks() ) ? ' rel="tag"' : '';
    374374
     375        $c = 0;
     376
    375377        foreach ( $counts as $tag => $count ) {
    376378                $tag_id = $tag_ids[$tag];
    377379                $tag_link = clean_url($tag_links[$tag]);
     380                $tag_size = round($smallest + ( ( $count - $min_count ) * $font_step ),0);
    378381                $tag = str_replace(' ', ' ', wp_specialchars( $tag ));
    379                 $a[] = "<a href='$tag_link' class='tag-link-$tag_id' title='" . attribute_escape( sprintf( __('%d topics'), $count ) ) . "'$rel style='font-size: " .
    380                         ( $smallest + ( ( $count - $min_count ) * $font_step ) )
    381                         . "$unit;'>$tag</a>";
     382                $a[] = '<a href="' . $tag_link . '" class="tag-link-' . $tag_id . ' tag-cloud-item-' . ++$c . ' tag-cloud-size-' . $tag_size . '" title="' . attribute_escape( sprintf( __('%d topics'), $count ) ) . '"' . $rel . ' style="font-size: ' . $tag_size . $unit . ';">' . $tag . '</a>';
    382383        }
    383384
    384385        switch ( $format ) :