帝國CMS批量修改審核文章未審核狀態,批量自定義指定文件上線時間!
用法:
后臺增加自定義頁面 PHP CODE:
$infouptime=to_time('2016-06-12 10:50:19'); //上線時間$sql=$empire->query("select * from {$dbtbpre}ecms_".$class_r[2][tbname]." where id BETWEEN 1 and 100");while($r=$empire->fetch($sql)){$id=$r[id];$classid=$r[classid];$nihao=$empire->query("update {$dbtbpre}ecms_".$class_r[2][tbname]."_index set checked=0 where id=$r[id]");MoveCheckInfoData($class_r[2][tbname],1,$r['stb'],"id=$r[id]");$pubid=ReturnInfoPubid($classid,$id);$copyids='';$num=$empire->gettotal("select count(*) as total from {$dbtbpre}enewsinfovote where pubid='$pubid' limit 1");if($num) //修改{$empire->query("update {$dbtbpre}enewsinfovote set copyids='$copyids',infouptime='$infouptime' where pubid='$pubid' limit 1");}else //增加{$intime=$empire->query("insert into {$dbtbpre}enewsinfovote(pubid,id,classid,infouptime,copyids) values('$pubid','$id','$classid','$infouptime','$copyids');");}AddClassInfos($classid,'','-1');} |
新聞熱點
疑難解答