[wp-hackers] Re: [wp-svn] [5148] trunk/wp-admin/admin-db.php: Don't dupe categories when adding new ones, use the existing ID.

Ryan Boren ryan at boren.nu
Sat Mar 31 06:47:25 GMT 2007


On 3/30/07, m at wordpress.org <m at wordpress.org> wrote:
>
>
>  Revision 5148 Author matt Date 2007-03-31 05:22:10 +0000 (Sat, 31 Mar 2007)
> Log Message Don't dupe categories when adding new ones, use the existing ID.
> + // Let's check if we have this category already, if so just do an update
> + if ( $cat_ID = $wpdb->get_var( "SELECT cat_ID FROM $wpdb->categories WHERE
> category_nicename = '$category_nicename' " ) )

category_exists()


More information about the wp-hackers mailing list