帝国官方Ajax评论插件显示头像解决方案
1.编辑/e/extend/infocomment/index.php
搜索:
$query="select plid,saytime,sayip,username,zcnum,fdnum,userid,saytext from {$dbtbpre}enewspl_".$n_r['restb']." where pubid='$pubid' and checked=0";
$query.=" order by plid desc limit $offset,$line";
修改为:
$query="select u.userpic,c.plid,c.saytime,c.sayip,c.username,c.zcnum,c.fdnum,c.userid,c.saytext from {$dbtbpre}enewspl_".$n_r['restb']." c left join {$dbtbpre}enewsmemberadd u on c.userid = u.userid where c.id='$id' and c.classid='$classid' and c.pubid='$pubid' and c.checked=0";
2.将
<img src="<?=$r[userpic]?$r[userpic]:'/e/data/images/nouserpic.gif'?>" border="0" />
代码放到
/e/extend/infocomment/template/index.temp.php
就可以显示头像了
无限星辰 , 版权所有丨如未注明 , 均为原创丨本网站采用BY-NC-SA协议进行授权 , 转载请注明帝国官方Ajax评论插件显示头像解决方案!