帝国cms 使用php sql 使用 join in 来调用案例
<ul class="hot_rwap sideMen bj_mt20">';
$mesql_artib=$empire->query("select a.*,c.classname from {$dbtbpre}ecms_news as a left join {$dbtbpre}enewsclass as c on a.classid = c.classid where a.classid=".$proMenu[classid]." order by a.onclick desc limit 8");
$renmen_i=0;
$renmen_on='';
while($renmen_arti=$empire->fetch($mesql_artib)){
$classurlb=sys_ReturnBqClassname($renmen_arti[classid],9);
$renmen_i++;
if ($renmen_i==1){$renmen_on='on';}else {$on='';}
echo '<li class="lb_w1 '.$renmen_i.'"><a href="'.$renmen_arti[titleurl].'" title="'.$renmen_arti[title].'" target="_blank" class="lb_wimg"><em class="icon"></em></a>
<div class="lb_nr"><span>'.$renmen_i.'</span>
<a href="'.$renmen_arti[titleurl].'" title="'.$renmen_arti[title].'" target="_blank" class="lb_bt chao2">'.$renmen_arti[title].'</a>
<a href="'.$classurlb.'" target="_blank" title="'.$proMenu[classname].'" class="lb_lm">'.$renmen_arti[classname].'</a></div></li>';
}
echo '</ul>