日前給一個政府機關作個小的門戶網站,用的是wordpress+主題開發,部署時發現導入數據庫sql文本時出現Unknown collation: 'utf8mb4_unicode_ci'的錯誤,查了下緣由:php
I had the same issue as all of our servers run older versions of MySQL. This can be solved by running a PHP script. Save this code to a file and run it entering the database name, user and password and it'll change the collation from utf8mb4/utf8mb4_unicode_ci to utf8/utf8_general_cisql
緣由就是MySql的版本太老了,解決方法就是把 utf8mb4/utf8mb4_unicode_ci
替換成 utf8/utf8_general_ci
數據庫
MySql版本不夠,相信php的版本也沒會夠,三條黑線|||wordpress
http://stackoverflow.com/questions/29916610/1273-unknown-collation-utf8mb4-unicode-ci-cpanel網站