Changeset 6190 for branches/2.3/wp-includes/query.php
- Timestamp:
- 10/05/2007 04:28:42 PM (17 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/2.3/wp-includes/query.php
r6187 r6190 1058 1058 $q[$item] = array_unique($q[$item]); 1059 1059 $tsql = "SELECT p.ID FROM $wpdb->posts p LEFT JOIN $wpdb->term_relationships tr ON (p.ID = tr.object_id) LEFT JOIN $wpdb->term_taxonomy tt ON (tr.term_taxonomy_id = tt.term_taxonomy_id) LEFT JOIN $wpdb->terms t ON (tt.term_id = t.term_id)"; 1060 $tsql .= " WHERE tt.taxonomy = '$taxonomy' AND t.$taxonomy_field IN ('" . implode("', '", $q[$item]) . "')";1061 $tsql .= " GROUP BY p.ID HAVING count(p.ID) = " . count($q[$item]);1060 $tsql .= " WHERE tt.taxonomy = '$taxonomy' AND t.$taxonomy_field IN ('" . implode("', '", $q[$item]) . "')"; 1061 $tsql .= " GROUP BY p.ID HAVING count(p.ID) = " . count($q[$item]); 1062 1062 1063 1063 $post_ids = $wpdb->get_col($tsql);
Note: See TracChangeset
for help on using the changeset viewer.