Make WordPress Core


Ignore:
Timestamp:
08/08/2012 06:13:48 AM (14 years ago)
Author:
nacin
Message:

Introduce wpdb::get_charset_collate() to return the DEFAULT CHARACTER SET and COLLATE for use in table schemas.

props simonwheatley, pento. fixes #18451.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-admin/includes/schema.php

    r20363 r21471  
    1818 * @name $charset_collate
    1919 */
    20 $charset_collate = '';
    21 
    22 if ( ! empty( $wpdb->charset ) )
    23     $charset_collate = "DEFAULT CHARACTER SET $wpdb->charset";
    24 if ( ! empty( $wpdb->collate ) )
    25     $charset_collate .= " COLLATE $wpdb->collate";
     20$charset_collate = $wpdb->get_charset_collate();
    2621
    2722/**
Note: See TracChangeset for help on using the changeset viewer.