|
[EQDKP] 报错 Strict Standards: Resource ID#10 used as offset, casting to integer (10)
安装eqdkp的最后环节出现报错信息 Strict Standards: Resource ID#10 used as offset, casting to integer (10)
原因出在源代码里,代码包里的 eqdkp\dbal\mysql.php 要修改代码
在该文件里搜索 function fetch_record($query_id = 0) \\大概在260行上下
把以下代码- function fetch_record($query_id = 0)
- {
- if ( !$query_id )
- {
- $query_id = $this->query_id;
- }
-
- if ( $query_id )
- {
- $this->record[$query_id] = @mysql_fetch_array($query_id);
- return $this->record[$query_id];
- }
- else
- {
- return false;
- }
- }
Copy Code 改为以下代码- function fetch_record($query_id = 0)
- {
- if ( !$query_id )
- {
- $query_id = $this->query_id;
- }
-
- if ( $query_id )
- {
- $id = (int) $query_id; //If you want to use $query_id as an integer I think you can cast it to an integer before using it
-
- $this->record[$id] = @mysql_fetch_array($query_id); // 原来的LINE 272
- return $this->record[$id]; // 原来的LINE 273
- }
- else
- {
- return false;
- }
- }
Copy Code 解决方法来自外文论坛
http://stackoverflow.com/questions/22946193/strict-standards-resource-id73-used-as-offset-casting-to-integer |
EQ中文世纪地图集地址:
www.ceqmap.com |
|