TheMinusWorld / forum-improvements

Organize suggestions and other details related to improving the phpBB iteration of the Minus World
BSD 3-Clause "New" or "Revised" License
0 stars 0 forks source link

Imported: Emoji throw MySQL errors #78

Open wtl420 opened 8 years ago

wtl420 commented 8 years ago

Sun Aug 23, 2015 08:05 PM Emoji throw MySQL errors by World'sTallestLadder:

fix your goddamn collations

Mon Aug 24, 2015 12:48 AM Re: Emoji throw MySQL errors by Bitteh:

yeah i want to be able to post that "⬜⬜⬜⬜⬜⬜⬜⬜⬜⬜ good @!$% go౦ԁ @!$%⬜ thats ✔ some good⬜⬜@!$% right⬜⬜there⬜⬜⬜ right✔there ✔✔if i do ƽaү so my self ⬜ i say so ⬜ thats what im talking about right there right there (chorus: ʳᶦᵍʰᵗ ᵗʰᵉʳᵉ) mMMMMᎷМ⬜ ⬜⬜ ⬜НO0ОଠOOOOOОଠଠOoooᵒᵒᵒᵒᵒᵒᵒᵒᵒ⬜ ⬜⬜ ⬜ ⬜ ⬜ ⬜ ⬜ ⬜ ⬜⬜Good @!$%" copypasta

Mon Aug 24, 2015 11:05 PM Re: Emoji throw MySQL errors by Yrr:

woah they really do break the board when you try to submit

Tue Aug 25, 2015 12:23 AM Re: Emoji throw MySQL errors by Todestrieb:

1) kaomoji are better

2) white people should be banned from using more than 1 emoji per message (゜~゜) (disclaimer: im white 2)

Tue Aug 25, 2015 05:41 AM Re: Emoji throw MySQL errors by World'sTallestLadder:

since emoji require utf-8 support I'm sure any kaomoji or whatever would work fine just as well

backstory for this: mysql is horrible and @!$% up and especially so since Oracle acquired it. basically the default collation is swedish for whatever reason, ok fine, whatever, but then you'd think you can just switch it to utf8? wrong!! first off, there's two reasonable utf-8 options: utf8_general_ci and utf8_unicode_ci (there's also utf8_bin for case-sensitive stuff but you don't need that most of the time). utf8_general_ci is some @!$% up weird thing that should be avoided but still gets recommended for whatever reason. so utf8_unicode_ci it is right?? nope. mysql @!$% up the utf8 implementation and it doesn't support the full collection of utf8 characters- oops. so you have to use utf8mb4. mysql is the only thing out there that calls it that, everywhere else its just utf8... cuz thats what utf8 is.

so basically collate the tables/columns so they're utf8mb4_unicode_ci or utf8mb4_bin instead of latin_swedish_ci or whatever and this will give us actual utf8 support, which has its advantages outside of emoji

you can use phpmyadmin to collate the tables/columns or write some php script to automate it maybe, google will be your friend in either case if needed

short version: its @!$% 2015 we live in a cyberpunk dystopia and technology is awful but get your minus together world anyway