<?php
$sql=$empire->query("select classid,classname,islast from {$dbtbpre}enewsclass where bclassid=0 and showclass=0 order by myorder,myorder asc");
while($s=$empire->fetch($sql)){
$tclass="";
$tclass2="";
$fr=explode('|',$class_r[$GLOBALS[navclassid]][featherclass]);
$topbclassid=$fr[1]?$fr[1]:$GLOBALS[navclassid];
if($topbclassid==$s[classid]){
$tclass='active';
}
if(!$s[islast]){$tclass2='<i class="fa fa-angle-down"></i>';}
$classurl=sys_ReturnBqClassname($s,9);
echo '<li class="'.$tclass.'"><a href="'.$classurl.'">'.$s[classname].''.$tclass2.'</a>';
if(!$s[islast]){
$sql2=$empire->query("select classid,classname from {$dbtbpre}enewsclass where bclassid=$s[classid] and showclass=0 order by myorder,myorder asc");
$str="";
while($s2=$empire->fetch($sql2)){
$classurl2=sys_ReturnBqClassname($s2,9);
$str.='<li><a href="'.$classurl2.'">'.$s2[classname].'</a></li>';
}
echo '<ul>'.$str.'</ul>';
}
echo '</li>';
}
?>