帝国cms提示Warning: Illegal string offset 'docanhtml' in \e\class\functions.php on line 612
小编在开发时遇到帝国cms提示Warning: Illegal string offset 'docanhtml' in eclassfunctions.php on line 6121
查看此处发现是if($gr['docanhtml']),由于没有$gr变量,所以此处出现了一个提示性的错误。
往前追溯,发现是由于没有$lur变量,$lur变量用于存储后台管理员ID、账号、用户组ID等信息。我们只需要在开发文件前部加入以下语句即可解决问题。
$lur=$empire->fetch1("select * from {$dbtbpre}enewsuser where `userid`='$add[userid]'");