帝国cms完美解决,灵动免费领取一个qq现金红包e:loop中获取父栏目id问题

作者: 来源: 时间: 2018-03-04 23:39 阅读: 次
帝国cms完美解决,灵动免费领取一个qq现金红包e:loop中获取父栏目id问题
  <?

  echo $nclassid =$GLOBALS[navclassid];//获取当前栏目ID

  echo $bclassid = $class_r[$GLOBALS[navclassid]][bclassid]; //获取当前父栏目ID

  $islast=$empire->fetch1(“select * from {$dbtbpre}enewsclass where classid=’$nclassid'”); //判断当前栏目是否是终极栏目

  if($islast[islast]==1){

  ?>

  [e:loop={“select classid,classname,classpath from [!db。pre!]enewsclass where bclassid = ‘$bclassid’ order by classid”,0,24,0}]

  ”>

  [/e:loop]

  
  }else{

  ?>

  [e:loop={“select classid,classname,classpath from [!db.pre!]enewsclass where bclassid = ‘$nclassid’ order by classid”,0,24,0}]

  ”>

  [/e:loop]

  
  }

  ?>

赞助推荐