[buddypress-trac] [BuddyPress Trac] #7117: CREATE TABLE not setting table collation
buddypress-trac
noreply at wordpress.org
Sat Jun 11 22:19:44 UTC 2016
#7117: CREATE TABLE not setting table collation
--------------------------+----------------------------
Reporter: DJPaul | Owner:
Type: defect (bug) | Status: new
Priority: normal | Milestone: Future Release
Component: API | Version:
Severity: normal | Keywords: good-first-bug
--------------------------+----------------------------
When creating a table, we use `bp_core_set_charset()` to set the charset.
This function dates back to 1.5, despite its PHPDoc which says 1.1 or
something. We do not set the collation, resulting that being set to
whatever the default for the version of MySQL is, resulting in mismatches
on new installs against the collation that WordPress uses.
Reported on https://buddypress.org/support/topic/db-collation-
utf8mb4_general_ci/
In the years since BP 1.5, WordPress 3.5 added a convenience function
`wpdb->get_charset_collate()` which does both charset and collation. We
should switch out our `bp_core_set_charset()` function with calls to
`get_charset_collate`, and soft-deprecate it.
--
Ticket URL: <https://buddypress.trac.wordpress.org/ticket/7117>
BuddyPress Trac <http://buddypress.org/>
BuddyPress Trac
More information about the buddypress-trac
mailing list