Browse Source

修正一出高版本PHP兼容性问题

在PHP7+ 环境下 变量在初始化未字符串类型,在但在后面使用时作为数组使用,没有将变量自动转换为数组而是以字符串存在"[]"作为了运算符
艺术流氓 2 months ago
parent
commit
833b1985de
1 changed files with 1 additions and 1 deletions
  1. 1 1
      install_package/phpcms/modules/member/member_model.php

+ 1 - 1
install_package/phpcms/modules/member/member_model.php

@@ -125,7 +125,7 @@ class member_model extends admin {
 	 */
 	function delete() {
 		$modelidarr = isset($_POST['modelid']) ? $_POST['modelid'] : showmessage(L('illegal_parameters'), HTTP_REFERER);
-		$newmodelarr = '';
+		$newmodelarr = array();
 		foreach ($modelidarr as $modelarr) {
 			if($modelarr!=10) {
 				$newmodelarr[] = intval($modelarr);