Changeset 10150 for trunk/wp-includes/taxonomy.php
- Timestamp:
- 12/09/2008 06:03:31 PM (16 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/wp-includes/taxonomy.php
r9737 r10150 530 530 * hide_empty - Default is true. Will not return empty terms, which means 531 531 * terms whose count is 0 according to the given taxonomy. 532 * 532 * 533 533 * exclude - Default is an empty string. A comma- or space-delimited string 534 * of term ids to exclude from the return array. If 'include' is non-empty, 534 * of term ids to exclude from the return array. If 'include' is non-empty, 535 535 * 'exclude' is ignored. 536 536 * 537 537 * include - Default is an empty string. A comma- or space-delimited string 538 538 * of term ids to include in the return array. 539 * 539 * 540 540 * number - The maximum number of terms to return. Default is empty. 541 * 541 * 542 542 * offset - The number by which to offset the terms query. 543 543 * 544 * fields - Default is 'all', which returns an array of term objects. 544 * fields - Default is 'all', which returns an array of term objects. 545 545 * If 'fields' is 'ids' or 'names', returns an array of 546 546 * integers or strings, respectively. 547 547 * 548 548 * slug - Returns terms whose "slug" matches this value. Default is empty string. 549 * 549 * 550 550 * hierarchical - Whether to include terms that have non-empty descendants 551 551 * (even if 'hide_empty' is set to true). 552 * 552 * 553 553 * search - Returned terms' names will contain the value of 'search', 554 554 * case-insensitive. Default is an empty string. … … 564 564 * 565 565 * The 'child_of' argument, when used, should be set to the integer of a term ID. Its default 566 * is 0. If set to a non-zero value, all returned terms will be descendants 567 * of that term according to the given taxonomy. Hence 'child_of' is set to 0 568 * if more than one taxonomy is passed in $taxonomies, because multiple taxonomies 566 * is 0. If set to a non-zero value, all returned terms will be descendants 567 * of that term according to the given taxonomy. Hence 'child_of' is set to 0 568 * if more than one taxonomy is passed in $taxonomies, because multiple taxonomies 569 569 * make term ancestry ambiguous. 570 570 * 571 571 * The 'parent' argument, when used, should be set to the integer of a term ID. Its default is 572 572 * the empty string '', which has a different meaning from the integer 0. 573 * If set to an integer value, all returned terms will have as an immediate 573 * If set to an integer value, all returned terms will have as an immediate 574 574 * ancestor the term whose ID is specified by that integer according to the given taxonomy. 575 575 * The 'parent' argument is different from 'child_of' in that a term X is considered a 'parent' … … 782 782 } 783 783 reset ( $terms ); 784 784 785 785 $_terms = array(); 786 786 if ( 'ids' == $fields ) { … … 1953 1953 * @param array $terms The set of terms---either an array of term objects or term IDs---from which those that are descendants of $term_id will be chosen. 1954 1954 * @param string $taxonomy The taxonomy which determines the hierarchy of the terms. 1955 * @return array The subset of $terms that are descendants of $term_id. 1955 * @return array The subset of $terms that are descendants of $term_id. 1956 1956 */ 1957 1957 function &_get_term_children($term_id, $terms, $taxonomy) { … … 2037 2037 $term_items[$id][$row->object_id] = isset($term_items[$id][$row->object_id]) ? ++$term_items[$id][$row->object_id] : 1; 2038 2038 } 2039 2039 2040 2040 // Touch every ancestor's lookup row for each post in each term 2041 2041 foreach ( $term_ids as $term_id ) {
Note: See TracChangeset
for help on using the changeset viewer.