Rumah >pembangunan bahagian belakang >tutorial php >weiphp如何移植PHP7.0实例
Call to undefined function Think\simplexml_load_string()
simplexml扩展包的问题,需要安装扩展包
sudo apt-get install php7.0-xml
_STORAGE_WRITE_ERROR_:./Runtime/Cache/Install
路径权限的问题,需要设置跟目录权限可写,这个错误是由于创建Runtime目录没有可写权限造成
SQLSTATE[42000]: Syntax error or access violation: 1055 Expression #1 of SELECT list is not in GROUP BY clause and contains nonaggregated column 'wp_db.wp_material_news.id' which is not functionally dependent on columns in GROUP BY clause; this is incompatible with sql_mode=only_full_group_by
出现这个错误的原因是mysql数据库里面默认将sql_mode增加了 only_full_group_by 的配置,导致无法使用group by来查询。
使用如下命令在mysql的终端中查询sql_mode:
select @@sql_mode;
修改sql_mode是在配置文件 /etc/mysql/mysql.conf.d/mysqld.cnf 中增加如下内容
sql_mode=STRICT_TRANS_TABLES,NO_ZERO_IN_DATE,NO_ZERO_DATE,ERROR_FOR_pISION_BY_ZERO,NO_AUTO_CREATE_USER,NO_ENGINE_SUBSTITUTION
修改后查询结果为:
mysql> select @@sql_mode; +------------------------------------------------------------------------------------------------------------------------+ | @@sql_mode | +------------------------------------------------------------------------------------------------------------------------+ | STRICT_TRANS_TABLES,NO_ZERO_IN_DATE,NO_ZERO_DATE,ERROR_FOR_pISION_BY_ZERO,NO_AUTO_CREATE_USER,NO_ENGINE_SUBSTITUTION | +------------------------------------------------------------------------------------------------------------------------+ 1 row in set (0.00 sec)
相关推荐:
Atas ialah kandungan terperinci weiphp如何移植PHP7.0实例. Untuk maklumat lanjut, sila ikut artikel berkaitan lain di laman web China PHP!