織夢DEDECMS首頁報錯:Warning: Illegal string offset ‘url’ in

今天在訪問網(wǎng)站首頁時,發(fā)現(xiàn)頂部有錯誤代碼顯示 :

Warning: Illegal string offset 'url' in /www/include/taglib/flink.lib.php on line 139
Warning: Illegal string offset 'webname' in /www/include/include\taglib\flink.lib.php on line 140
Warning: Illegal string offset 'logo' in /www/include/include\taglib\flink.lib.php on line 141

解決方法:打開“\include\taglib\flink.lib.php”文件把里面的“$row[‘url’]”、“$row[‘webname’]”、“$row[‘logo’]”按下面代碼進行替換即可。

原代碼:

$rbtext = preg_replace("/\[field:url([\/\s]{0,})\]/isU", $row['url'], $innertext);
$rbtext = preg_replace("/\[field:webname([\/\s]{0,})\]/isU", $row['webname'], $rbtext);
$rbtext = preg_replace("/\[field:logo([\/\s]{0,})\]/isU", $row['logo'], $rbtext);
$rbtext = preg_replace("/\[field:link([\/\s]{0,})\]/isU", $link, $rbtext);
$revalue .= $rbtext;

修改后的代碼:

$rbtext = preg_replace("/\[field:url([\/\s]{0,})\]/isU", $dbrow->url, $innertext);
$rbtext = preg_replace("/\[field:webname([\/\s]{0,})\]/isU", $dbrow->webname, $rbtext);
$rbtext = preg_replace("/\[field:logo([\/\s]{0,})\]/isU", $dbrow->logo, $rbtext);
$rbtext = preg_replace("/\[field:link([\/\s]{0,})\]/isU", $link, $rbtext);
$revalue .= $rbtext;

替換后,問題解決。

紅色部分即修改后的代碼:

THE END
亚洲中文色欧另类欧美,久久久久久久激情,亚洲 日韩 欧美 另类 国产,中文字幕高清无码男人的天堂 www.sucaiwu.net