联系官方销售客服

1835022288

028-61286886

搜索带表情符号的内容时,会出现以下的错误:

Illegal mix of collations for operation 'UNION'
Illegal mix of collations (utf8mb4_general_ci,IMPLICIT) and (utf8_general_ci,COERCIBLE) for operation 'like'

解决方案:

mysql数据库的字符集需要改成:utf8mb4_general_ci


操作步骤

1、使用phpmyadmin工具,选择当前的数据库

2、然后一下图的选项,点执行

{xunruicms_img_title}

这样就把格式批量转换了。


3、打开数据库配置文件config/database.php

加上以下参数

'charset'      => 'utf8mb4',
'DBCollat'     => 'utf8mb4_general_ci',

{xunruicms_img_title}


-----------------------------------阿里云虚拟主机设置方法-------------------------------

NLN[0%(USHEEVUEV}B`RLSX


本文地址:https://www.xunruicms.com/doc/1043.html