wpdb::get_charset_collate() public WP 3.5.0
Retrieves the database character collate.
{} It's a method of the class: wpdb{}
No Hooks.
Return
String. The database character collate.
Usage
global $wpdb; $wpdb->get_charset_collate();
Changelog
Since 3.5.0 | Introduced. |
Code of wpdb::get_charset_collate() wpdb::get charset collate WP 5.6
public function get_charset_collate() {
$charset_collate = '';
if ( ! empty( $this->charset ) ) {
$charset_collate = "DEFAULT CHARACTER SET $this->charset";
}
if ( ! empty( $this->collate ) ) {
$charset_collate .= " COLLATE $this->collate";
}
return $charset_collate;
}