Make WordPress Core

Changeset 5554


Ignore:
Timestamp:
05/26/2007 06:59:58 PM (18 years ago)
Author:
ryan
Message:

cat2tag fixes. see #4189

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-admin/import/wp-cat2tag.php

    r5553 r5554  
    120120               
    121121                // Set the category itself to $type from above
    122                 $wpdb->query("UPDATE $wpdb->term_taxonomy SET taxonomy = '$type' WHERE term_id = '{$category->term_id}' AND taxonomy = 'category'");
     122                $wpdb->query("UPDATE $wpdb->term_taxonomy SET taxonomy = 'post_tag' WHERE term_id = '{$category->term_id}' AND taxonomy = 'category'");
    123123               
    124124                // Set all parents to 0 (root-level) if their parent was the converted tag
     
    154154        global $wpdb;
    155155
    156         $wpdb->query("UPDATE $wpdb->term_taxonomy SET taxonomy = '$type', parent = 0 WHERE taxonomy = 'category'");
     156        $wpdb->query("UPDATE $wpdb->term_taxonomy SET taxonomy = 'post_tag', parent = 0 WHERE taxonomy = 'category'");
    157157        clean_category_cache($category->term_id);
    158158    }
Note: See TracChangeset for help on using the changeset viewer.