Changeset 15586
- Timestamp:
- 09/07/2010 04:29:00 AM (14 years ago)
- Location:
- trunk/wp-includes
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/wp-includes/classes.php
r15409 r15586 1341 1341 extract($args); 1342 1342 1343 $cat_name = esc_attr( $category->name );1343 $cat_name = esc_attr( $category->name ); 1344 1344 $cat_name = apply_filters( 'list_cats', $cat_name, $category ); 1345 $link = '<a href="' . get_term_link( $category, $category->taxonomy) . '" ';1345 $link = '<a href="' . esc_attr( get_term_link($category) ) . '" '; 1346 1346 if ( $use_desc_for_title == 0 || empty($category->description) ) 1347 1347 $link .= 'title="' . sprintf(__( 'View all posts filed under %s' ), $cat_name) . '"'; -
trunk/wp-includes/taxonomy.php
r15583 r15586 2482 2482 * 2483 2483 * @param object|int|string $term 2484 * @param string $taxonomy 2484 * @param string $taxonomy (optional if $term is object) 2485 2485 * @return string HTML link to taxonomy term archive 2486 2486 */ 2487 function get_term_link( $term, $taxonomy ) {2487 function get_term_link( $term, $taxonomy = '') { 2488 2488 global $wp_rewrite; 2489 2489 … … 2501 2501 if ( is_wp_error( $term ) ) 2502 2502 return $term; 2503 2504 $taxonomy = $term->taxonomy; 2503 2505 2504 2506 // use legacy functions for core taxonomies until they are fully plugged in … … 2598 2600 2599 2601 foreach ( $terms as $term ) 2600 $links[] = "<a href='" . esc_attr( get_term_link($term, $taxonomy)) . "'>$term->name</a>";2602 $links[] = "<a href='" . esc_attr( get_term_link($term) ) . "'>$term->name</a>"; 2601 2603 2602 2604 if ( $links )
Note: See TracChangeset
for help on using the changeset viewer.