comdofun.php 32 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133
  1. <?php
  2. //批量更新相关链接
  3. function ChangeInfoOtherLink($start,$classid,$from,$retype,$startday,$endday,$startid,$endid,$tbname,$userid,$username){
  4. global $empire,$public_r,$class_r,$fun_r,$dbtbpre;
  5. //验证权限
  6. CheckLevel($userid,$username,$classid,"changedata");
  7. $start=(int)$start;
  8. $tbname=RepPostVar($tbname);
  9. if(empty($tbname)||!eCheckTbname($tbname))
  10. {
  11. printerror("ErrorUrl","history.go(-1)");
  12. }
  13. //按栏目刷新
  14. $classid=(int)$classid;
  15. if($classid)
  16. {
  17. if(empty($class_r[$classid][islast]))//父栏目
  18. {
  19. $where=ReturnClass($class_r[$classid][sonclass]);
  20. }
  21. else//终极栏目
  22. {
  23. $where="classid='$classid'";
  24. }
  25. $add1=" and (".$where.")";
  26. }
  27. //按ID刷新
  28. if($retype)
  29. {
  30. $startid=(int)$startid;
  31. $endid=(int)$endid;
  32. if($endid)
  33. {
  34. $add1.=" and id>=$startid and id<=$endid";
  35. }
  36. }
  37. else
  38. {
  39. $startday=RepPostVar($startday);
  40. $endday=RepPostVar($endday);
  41. if($startday&&$endday)
  42. {
  43. $add1.=" and truetime>=".to_time($startday." 00:00:00")." and truetime<=".to_time($endday." 23:59:59");
  44. }
  45. }
  46. $b=0;
  47. $sql=$empire->query("select id,classid,checked from {$dbtbpre}ecms_".$tbname."_index where id>$start".$add1." order by id limit ".$public_r[infolinknum]);
  48. while($r=$empire->fetch($sql))
  49. {
  50. $b=1;
  51. $new_start=$r[id];
  52. //手动相关链接
  53. $pubid=ReturnInfoPubid($r['classid'],$r['id']);
  54. $infopr=$empire->fetch1("select diyotherlink from {$dbtbpre}enewsinfovote where pubid='$pubid' limit 1");
  55. if($infopr['diyotherlink'])
  56. {
  57. continue;
  58. }
  59. //返回表
  60. $infotb=ReturnInfoMainTbname($tbname,$r['checked']);
  61. $infor=$empire->fetch1("select stb,keyboard from ".$infotb." where id='$r[id]' limit 1");
  62. //返回表信息
  63. $infodatatb=ReturnInfoDataTbname($tbname,$r['checked'],$infor['stb']);
  64. $newkeyid=GetKeyid($infor[keyboard],$r[classid],$r[id],$class_r[$r[classid]][link_num]);
  65. $usql=$empire->query("update ".$infodatatb." set keyid='$newkeyid' where id='$r[id]' limit 1");
  66. }
  67. if(empty($b))
  68. {
  69. insert_dolog("");//操作日志
  70. printerror("ChangeInfoLinkSuccess",$from);
  71. }
  72. echo $fun_r[OneChangeInfoLinkSuccess]."(ID:<font color=red><b>".$new_start."</b></font>)<script>self.location.href='ecmscom.php?enews=ChangeInfoOtherLink&tbname=$tbname&classid=$classid&start=$new_start&from=".urlencode($from)."&retype=$retype&startday=$startday&endday=$endday&startid=$startid&endid=$endid".hReturnEcmsHashStrHref(0)."';</script>";
  73. exit();
  74. }
  75. //检测目录已存在
  76. function CheckPath($classpath){
  77. global $fun_r;
  78. if(empty($classpath)){
  79. echo $fun_r['EmptyPath'];
  80. }
  81. else{
  82. if(file_exists("../../".$classpath)){
  83. echo $fun_r['RePath'];
  84. }
  85. else{
  86. echo $fun_r['PathNot'];
  87. }
  88. }
  89. exit();
  90. }
  91. //增加自定义页面
  92. function AddUserpage($add,$userid,$username){
  93. global $empire,$dbtbpre;
  94. //操作权限
  95. CheckLevel($userid,$username,$classid,"userpage");
  96. $classid=(int)$add[classid];
  97. $title=$add['title'];
  98. $path=$add['path'];
  99. $pagetext=$add['pagetext'];
  100. if(empty($title)||empty($path))
  101. {
  102. printerror("EmptyUserpagePath","history.go(-1)");
  103. }
  104. $title=hRepPostStr($title,1);
  105. $path=hRepPostStr($path,1);
  106. $pagetext=RepPhpAspJspcode($pagetext);
  107. $pagetitle=RepPhpAspJspcode($add[pagetitle]);
  108. $pagekeywords=RepPhpAspJspcode($add[pagekeywords]);
  109. $pagedescription=RepPhpAspJspcode($add[pagedescription]);
  110. $tempid=(int)$add['tempid'];
  111. $gid=(int)$add['gid'];
  112. $sql=$empire->query("insert into {$dbtbpre}enewspage(title,path,pagetext,classid,pagetitle,pagekeywords,pagedescription,tempid) values('$title','$path','".eaddslashes2($pagetext)."','$classid','".eaddslashes($pagetitle)."','".eaddslashes($pagekeywords)."','".eaddslashes($pagedescription)."','$tempid');");
  113. $id=$empire->lastid();
  114. ReUserpage($id,$pagetext,$path,$title,$pagetitle,$pagekeywords,$pagedescription,$tempid);
  115. if($sql)
  116. {
  117. //操作日志
  118. insert_dolog("id=$id&title=$title");
  119. printerror("AddUserpageSuccess","template/AddPage.php?enews=AddUserpage&gid=$gid&ChangePagemod=$add[pagemod]".hReturnEcmsHashStrHref2(0));
  120. }
  121. else
  122. {
  123. printerror("DbError","history.go(-1)");
  124. }
  125. }
  126. //修改自定义页面
  127. function EditUserpage($add,$userid,$username){
  128. global $empire,$dbtbpre;
  129. //操作权限
  130. CheckLevel($userid,$username,$classid,"userpage");
  131. $id=(int)$add['id'];
  132. $classid=(int)$add[classid];
  133. $title=$add['title'];
  134. $path=$add['path'];
  135. $pagetext=$add['pagetext'];
  136. if(!$id||empty($title)||empty($path))
  137. {
  138. printerror("EmptyUserpagePath","history.go(-1)");
  139. }
  140. //改变地址
  141. if($add['oldpath']<>$path)
  142. {
  143. DelFiletext($add['oldpath']);
  144. }
  145. $title=hRepPostStr($title,1);
  146. $path=hRepPostStr($path,1);
  147. $pagetext=RepPhpAspJspcode($pagetext);
  148. $pagetitle=RepPhpAspJspcode($add[pagetitle]);
  149. $pagekeywords=RepPhpAspJspcode($add[pagekeywords]);
  150. $pagedescription=RepPhpAspJspcode($add[pagedescription]);
  151. $tempid=(int)$add['tempid'];
  152. $gid=(int)$add['gid'];
  153. $sql=$empire->query("update {$dbtbpre}enewspage set title='$title',path='$path',pagetext='".eaddslashes2($pagetext)."',classid='$classid',pagetitle='".eaddslashes($pagetitle)."',pagekeywords='".eaddslashes($pagekeywords)."',pagedescription='".eaddslashes($pagedescription)."',tempid='$tempid' where id='$id'");
  154. ReUserpage($id,$pagetext,$path,$title,$pagetitle,$pagekeywords,$pagedescription,$tempid);
  155. if($sql)
  156. {
  157. //操作日志
  158. insert_dolog("id=$id&title=$title");
  159. printerror("EditUserpageSuccess","template/ListPage.php?classid=$add[cid]&gid=$gid".hReturnEcmsHashStrHref2(0));
  160. }
  161. else
  162. {
  163. printerror("DbError","history.go(-1)");
  164. }
  165. }
  166. //删除自定义页面
  167. function DelUserpage($id,$cid,$userid,$username){
  168. global $empire,$dbtbpre;
  169. //操作权限
  170. CheckLevel($userid,$username,$classid,"userpage");
  171. $id=(int)$id;
  172. if(empty($id))
  173. {
  174. printerror("EmptyDelUserpageid","history.go(-1)");
  175. }
  176. $gid=(int)$_GET['gid'];
  177. $r=$empire->fetch1("select title,id,path from {$dbtbpre}enewspage where id='$id'");
  178. if(empty($r['id']))
  179. {
  180. printerror("NotDelUserpageid","history.go(-1)");
  181. }
  182. $sql=$empire->query("delete from {$dbtbpre}enewspage where id='$id'");
  183. DelFiletext($r['path']);
  184. //moreportdo
  185. $eautodofile=str_replace('../../','',$r['path']);
  186. if($eautodofile)
  187. {
  188. $eautodofname='delfile|'.$eautodofile.'||';
  189. eAutodo_AddDo('eDelFileUserpage',0,0,0,0,0,$eautodofname);
  190. }
  191. if($sql)
  192. {
  193. //操作日志
  194. insert_dolog("id=$id&title=$r[title]");
  195. printerror("DelUserpageSuccess","template/ListPage.php?classid=$cid&gid=$gid".hReturnEcmsHashStrHref2(0));
  196. }
  197. else
  198. {
  199. printerror("DbError","history.go(-1)");
  200. }
  201. }
  202. //刷新自定义页面
  203. function DoReUserpage($add,$userid,$username){
  204. global $empire,$dbtbpre;
  205. //操作权限
  206. CheckLevel($userid,$username,$classid,"userpage");
  207. $id=$add['id'];
  208. $count=count($id);
  209. if(!$count)
  210. {
  211. printerror("EmptyReUserpageid","history.go(-1)");
  212. }
  213. for($i=0;$i<$count;$i++)
  214. {
  215. $id[$i]=(int)$id[$i];
  216. if(empty($id[$i]))
  217. {
  218. continue;
  219. }
  220. $ur=$empire->fetch1("select id,path,pagetext,title,pagetitle,pagekeywords,pagedescription,tempid from {$dbtbpre}enewspage where id='".$id[$i]."'");
  221. ReUserpage($ur[id],$ur[pagetext],$ur[path],$ur[title],$ur[pagetitle],$ur[pagekeywords],$ur[pagedescription],$ur[tempid]);
  222. }
  223. //操作日志
  224. insert_dolog("");
  225. printerror("DoReUserpageSuccess",EcmsGetReturnUrl());
  226. }
  227. //批量替换字段值
  228. function DoRepNewstext($start,$oldword,$newword,$field,$classid,$tid,$tbname,$over,$dozz,$dotxt,$userid,$username){
  229. global $empire,$public_r,$class_r,$fun_r,$dbtbpre,$emod_r;
  230. $tbname=RepPostVar($tbname);
  231. $field=RepPostVar($field);
  232. $tid=(int)$tid;
  233. $dotype=(int)$_POST['dotype'];
  234. $classid=(int)$classid;
  235. if(!$field||empty($tbname)||!$tid)
  236. {
  237. printerror("FailCX","history.go(-1)");
  238. }
  239. if($dotype==0&&strlen($oldword)==0)
  240. {
  241. printerror("FailCX","history.go(-1)");
  242. }
  243. CheckLevel($userid,$username,$classid,"repnewstext");//验证权限
  244. //变量替换
  245. $postoldword=ClearAddsData($oldword);
  246. $postnewword=ClearAddsData($newword);
  247. //替换条件
  248. if($classid)//按栏目替换
  249. {
  250. if(empty($class_r[$classid][islast]))//中级栏目
  251. {
  252. $where=ReturnClass($class_r[$classid][sonclass]);
  253. }
  254. else//终极栏目
  255. {
  256. $where="classid='$classid'";
  257. }
  258. $add1=" and (".$where.")";
  259. $add2=" where (".$where.")";
  260. }
  261. $fr=$empire->fetch1("select tid,savetxt,tbdataf from {$dbtbpre}enewsf where tbname='$tbname' and f='$field' limit 1");
  262. //系统字段
  263. $specialdatafield=',keyid,dokey,newstempid,closepl,haveaddfen,infotags,';
  264. if(!$fr['tid']&&stristr($specialdatafield,','.$field.','))
  265. {
  266. $fr['tbdataf']=1;
  267. }
  268. //覆盖方式
  269. if($dotype==1)
  270. {
  271. $repoldword=addslashes($oldword);
  272. $repnewword=addslashes($newword);
  273. if($over==1)//完全替换
  274. {
  275. if(empty($add2))
  276. {
  277. $and=" where ";
  278. }
  279. else
  280. {
  281. $and=" and ";
  282. }
  283. $add2.=$and.$field."='".$repoldword."'";
  284. }
  285. if($fr['tbdataf'])//副表
  286. {
  287. //已审核
  288. $tbr=$empire->fetch1("select datatbs from {$dbtbpre}enewstable where tbname='$tbname' limit 1");
  289. if($tbr['datatbs'])
  290. {
  291. $dtbr=explode(',',$tbr['datatbs']);
  292. $count=count($dtbr);
  293. for($i=1;$i<$count-1;$i++)
  294. {
  295. $empire->query("update {$dbtbpre}ecms_".$tbname."_data_".$dtbr[$i]." set ".$field."='$repnewword'".$add2);
  296. }
  297. }
  298. //未审核
  299. $empire->query("update {$dbtbpre}ecms_".$tbname."_check_data set ".$field."='$repnewword'".$add2);
  300. }
  301. else//主表
  302. {
  303. $empire->query("update {$dbtbpre}ecms_".$tbname." set ".$field."='$repnewword'".$add2);
  304. //未审核
  305. $empire->query("update {$dbtbpre}ecms_".$tbname."_check set ".$field."='$repnewword'".$add2);
  306. }
  307. //替换完毕
  308. insert_dolog("tbname=".$tbname."&field=".$field."&dotype=1<br>oldword=".$oldword."<br>newword=".$newword);//操作日志
  309. printerror("DoRepNewstextSuccess","db/RepNewstext.php?tid=$tid".hReturnEcmsHashStrHref2(0));
  310. }
  311. //存文本替换
  312. elseif($fr['savetxt'])
  313. {
  314. $repoldword=addslashes($postoldword);
  315. $repnewword=addslashes($postnewword);
  316. //字段
  317. $selectf=$fr['tbdataf']?',stb':','.$field;
  318. $fieldform="<input type='hidden' name='field' value='".$field."'>";
  319. if(empty($public_r[dorepnum]))
  320. {
  321. $public_r[dorepnum]=600;
  322. }
  323. $start=(int)$start;
  324. $b=0;
  325. $sql=$empire->query("select id,checked from {$dbtbpre}ecms_".$tbname."_index where id>$start".$add1." order by id limit ".$public_r[dorepnum]);
  326. while($r=$empire->fetch($sql))
  327. {
  328. $b=1;
  329. $newstart=$r[id];
  330. //返回表
  331. $infotb=ReturnInfoMainTbname($tbname,$r['checked']);
  332. //主表
  333. $infor=$empire->fetch1("select isurl".$selectf." from ".$infotb." where id='$r[id]' limit 1");
  334. if($infor['isurl'])
  335. {
  336. continue;
  337. }
  338. //副表
  339. if($fr['tbdataf'])
  340. {
  341. //返回表信息
  342. $infodatatb=ReturnInfoDataTbname($tbname,$r['checked'],$infor['stb']);
  343. $finfor=$empire->fetch1("select ".$field." from ".$infodatatb." where id='$r[id]' limit 1");
  344. $infor[$field]=$finfor[$field];
  345. }
  346. $value=GetTxtFieldText($infor[$field]);
  347. if(empty($value))
  348. {
  349. continue;
  350. }
  351. if($dozz==1)//正则
  352. {
  353. $newvalue=DoRepNewstextZz($repoldword,$repnewword,$value);//正则替换
  354. }
  355. else//普通
  356. {
  357. if(!stristr($value,$repoldword))
  358. {
  359. continue;
  360. }
  361. $newvalue=str_replace($repoldword,$repnewword,$value);
  362. }
  363. EditTxtFieldText($infor[$field],$newvalue);
  364. }
  365. //替换完毕
  366. if(empty($b))
  367. {
  368. insert_dolog("tbname=".$tbname."&field=".$field."<br>oldword=".$oldword."<br>newword=".$newword);//操作日志
  369. printerror("DoRepNewstextSuccess","db/RepNewstext.php?tid=$tid".hReturnEcmsHashStrHref2(0));
  370. }
  371. EchoRepFieldForm($tid,$tbname,$over,$dozz,$dotxt,$newstart,$fieldform,$classid,$postoldword,$postnewword);
  372. }
  373. //正则替换
  374. elseif($dozz==1)
  375. {
  376. //字段
  377. $selectf=$fr['tbdataf']?',stb':','.$field;
  378. $fieldform="<input type='hidden' name='field' value='".$field."'>";
  379. if(empty($public_r[dorepnum]))
  380. {
  381. $public_r[dorepnum]=600;
  382. }
  383. $start=(int)$start;
  384. $b=0;
  385. $sql=$empire->query("select id,checked from {$dbtbpre}ecms_".$tbname."_index where id>$start".$add1." order by id limit ".$public_r[dorepnum]);
  386. while($r=$empire->fetch($sql))
  387. {
  388. $b=1;
  389. $newstart=$r[id];
  390. //返回表
  391. $infotb=ReturnInfoMainTbname($tbname,$r['checked']);
  392. //主表
  393. $infor=$empire->fetch1("select isurl".$selectf." from ".$infotb." where id='$r[id]' limit 1");
  394. if($infor['isurl'])
  395. {
  396. continue;
  397. }
  398. if($fr['tbdataf'])//副表
  399. {
  400. //返回表信息
  401. $infodatatb=ReturnInfoDataTbname($tbname,$r['checked'],$infor['stb']);
  402. $finfor=$empire->fetch1("select ".$field." from ".$infodatatb." where id='$r[id]' limit 1");
  403. $newvalue=DoRepNewstextZz($oldword,$newword,stripSlashes($finfor[$field]));//正则替换
  404. $empire->query("update ".$infodatatb." set ".$field."='".addslashes($newvalue)."' where id='$r[id]'");
  405. }
  406. else//主表
  407. {
  408. $newvalue=DoRepNewstextZz($oldword,$newword,stripSlashes($infor[$field]));//正则替换
  409. $empire->query("update ".$infotb." set ".$field."='".addslashes($newvalue)."' where id='$r[id]'");
  410. }
  411. }
  412. //替换完毕
  413. if(empty($b))
  414. {
  415. insert_dolog("tbname=".$tbname."&field=".$field."<br>oldword=".$oldword."<br>newword=".$newword);//操作日志
  416. printerror("DoRepNewstextSuccess","db/RepNewstext.php?tid=$tid".hReturnEcmsHashStrHref2(0));
  417. }
  418. EchoRepFieldForm($tid,$tbname,$over,$dozz,$dotxt,$newstart,$fieldform,$classid,$postoldword,$postnewword);
  419. }
  420. //普通替换
  421. else
  422. {
  423. $repoldword=eaddslashes2($oldword);
  424. $repnewword=eaddslashes2($newword);
  425. if($over==1)//完全替换
  426. {
  427. if(empty($add2))
  428. {
  429. $and=" where ";
  430. }
  431. else
  432. {
  433. $and=" and ";
  434. }
  435. $add2.=$and.$field."='".$repoldword."'";
  436. }
  437. if($fr['tbdataf'])//副表
  438. {
  439. //已审核
  440. $tbr=$empire->fetch1("select datatbs from {$dbtbpre}enewstable where tbname='$tbname' limit 1");
  441. if($tbr['datatbs'])
  442. {
  443. $dtbr=explode(',',$tbr['datatbs']);
  444. $count=count($dtbr);
  445. for($i=1;$i<$count-1;$i++)
  446. {
  447. $empire->query("update {$dbtbpre}ecms_".$tbname."_data_".$dtbr[$i]." set ".$field."=REPLACE(".$field.",'$repoldword','$repnewword')".$add2);
  448. }
  449. }
  450. //未审核
  451. $empire->query("update {$dbtbpre}ecms_".$tbname."_check_data set ".$field."=REPLACE(".$field.",'$repoldword','$repnewword')".$add2);
  452. }
  453. else//主表
  454. {
  455. $empire->query("update {$dbtbpre}ecms_".$tbname." set ".$field."=REPLACE(".$field.",'$repoldword','$repnewword')".$add2);
  456. //未审核
  457. $empire->query("update {$dbtbpre}ecms_".$tbname."_check set ".$field."=REPLACE(".$field.",'$repoldword','$repnewword')".$add2);
  458. }
  459. //替换完毕
  460. insert_dolog("tbname=".$tbname."&field=".$field."<br>oldword=".$oldword."<br>newword=".$newword);//操作日志
  461. printerror("DoRepNewstextSuccess","db/RepNewstext.php?tid=$tid".hReturnEcmsHashStrHref2(0));
  462. }
  463. }
  464. //正则替换信息
  465. function DoRepNewstextZz($oldword,$newword,$text){
  466. $zztext=RepInfoZZ($oldword,"empire-cms-wm.chief-phome",0);
  467. $text=preg_replace($zztext,$newword,$text);
  468. return $text;
  469. }
  470. //输出批量替换字段表单
  471. function EchoRepFieldForm($tid,$tbname,$over,$dozz,$dotxt,$newstart,$fieldform,$classid,$oldword,$newword){
  472. global $fun_r;
  473. $dotype=(int)$_POST['dotype'];
  474. ?>
  475. <?=$fun_r['RepOneNewstextSuccess']?>(ID:<font color=red><b><?=$newstart?></b></font>)
  476. <form name="RepFieldForm" method="post" action="ecmscom.php">
  477. <?=hReturnEcmsHashStrForm(0)?>
  478. <input type=hidden name="enews" value="DoRepNewstext">
  479. <input type=hidden name="tid" value="<?=$tid?>">
  480. <input type=hidden name="tbname" value="<?=$tbname?>">
  481. <input type=hidden name="over" value="<?=$over?>">
  482. <input type=hidden name="dozz" value="<?=$dozz?>">
  483. <input type=hidden name="dotxt" value="<?=$dotxt?>">
  484. <input type=hidden name="dotype" value="<?=$dotype?>">
  485. <input type=hidden name="start" value="<?=$newstart?>">
  486. <?=$fieldform?>
  487. <input type=hidden name="classid" value="<?=$classid?>">
  488. <input type=hidden name="oldword" value="<?=ehtmlspecialchars($oldword)?>">
  489. <input type=hidden name="newword" value="<?=ehtmlspecialchars($newword)?>">
  490. </form>
  491. <script>
  492. document.RepFieldForm.submit();
  493. </script>
  494. <?
  495. exit();
  496. }
  497. //返回类别管理操作信息
  498. function ReturnDoclassVar($ecms){
  499. global $dbtbpre;
  500. //标签模板分类
  501. if($ecms=="bqtemp")
  502. {
  503. $r['tbname']=$dbtbpre."enewsbqtempclass";
  504. $r['mess']="Bqtemp";
  505. $r['thelevel']="template";
  506. $r['returnpage']="template/BqtempClass.php";
  507. }
  508. //用户自定义页面分类
  509. elseif($ecms=="page")
  510. {
  511. $r['tbname']=$dbtbpre."enewspageclass";
  512. $r['mess']="Page";
  513. $r['thelevel']="userpage";
  514. $r['returnpage']="template/PageClass.php";
  515. }
  516. //公共模板变量分类
  517. elseif($ecms=="tempvar")
  518. {
  519. $r['tbname']=$dbtbpre."enewstempvarclass";
  520. $r['mess']="Tempvar";
  521. $r['thelevel']="tempvar";
  522. $r['returnpage']="template/TempvarClass.php";
  523. }
  524. //列表模板分类
  525. elseif($ecms=="listtemp")
  526. {
  527. $r['tbname']=$dbtbpre."enewslisttempclass";
  528. $r['mess']="Listtemp";
  529. $r['thelevel']="template";
  530. $r['returnpage']="template/ListtempClass.php";
  531. }
  532. //内容模板分类
  533. elseif($ecms=="newstemp")
  534. {
  535. $r['tbname']=$dbtbpre."enewsnewstempclass";
  536. $r['mess']="Newstemp";
  537. $r['thelevel']="template";
  538. $r['returnpage']="template/NewstempClass.php";
  539. }
  540. //搜索模板分类
  541. elseif($ecms=="searchtemp")
  542. {
  543. $r['tbname']=$dbtbpre."enewssearchtempclass";
  544. $r['mess']="Searchtemp";
  545. $r['thelevel']="template";
  546. $r['returnpage']="template/SearchtempClass.php";
  547. }
  548. //标签分类
  549. elseif($ecms=="bq")
  550. {
  551. $r['tbname']=$dbtbpre."enewsbqclass";
  552. $r['mess']="Bq";
  553. $r['thelevel']="bq";
  554. $r['returnpage']="template/BqClass.php";
  555. }
  556. //JS模板
  557. elseif($ecms=="jstemp")
  558. {
  559. $r['tbname']=$dbtbpre."enewsjstempclass";
  560. $r['mess']="Jstemp";
  561. $r['thelevel']="template";
  562. $r['returnpage']="template/JsTempClass.php";
  563. }
  564. //专题
  565. elseif($ecms=="zt")
  566. {
  567. $r['tbname']=$dbtbpre."enewsztclass";
  568. $r['mess']="Ztclass";
  569. $r['thelevel']="zt";
  570. $r['returnpage']="special/ListZtClass.php";
  571. }
  572. //友情链接
  573. elseif($ecms=="link")
  574. {
  575. $r['tbname']=$dbtbpre."enewslinkclass";
  576. $r['mess']="Linkclass";
  577. $r['thelevel']="link";
  578. $r['returnpage']="tool/LinkClass.php";
  579. }
  580. //单页模板
  581. elseif($ecms=="classtemp")
  582. {
  583. $r['tbname']=$dbtbpre."enewsclasstempclass";
  584. $r['mess']="Classtemp";
  585. $r['thelevel']="template";
  586. $r['returnpage']="template/ClassTempClass.php";
  587. }
  588. //错误报告
  589. elseif($ecms=="error")
  590. {
  591. $r['tbname']=$dbtbpre."enewserrorclass";
  592. $r['mess']="Error";
  593. $r['thelevel']="downerror";
  594. $r['returnpage']="DownSys/ErrorClass.php";
  595. }
  596. //TAGS
  597. elseif($ecms=="tags")
  598. {
  599. $r['tbname']=$dbtbpre."enewstagsclass";
  600. $r['mess']="Tags";
  601. $r['thelevel']="tags";
  602. $r['returnpage']="tags/TagsClass.php";
  603. }
  604. //用户自定义列表
  605. elseif($ecms=="userlist")
  606. {
  607. $r['tbname']=$dbtbpre."enewsuserlistclass";
  608. $r['mess']="Userlist";
  609. $r['thelevel']="userlist";
  610. $r['returnpage']="other/UserlistClass.php";
  611. }
  612. //用户自定义JS
  613. elseif($ecms=="userjs")
  614. {
  615. $r['tbname']=$dbtbpre."enewsuserjsclass";
  616. $r['mess']="Userjs";
  617. $r['thelevel']="userjs";
  618. $r['returnpage']="other/UserjsClass.php";
  619. }
  620. else
  621. {
  622. printerror("ErrorUrl","history.go(-1)");
  623. }
  624. $r['returnpage'].=hReturnEcmsHashStrHref2(1);
  625. return $r;
  626. }
  627. //增加分类
  628. function AddThisClass($add,$userid,$username){
  629. global $empire,$dbtbpre;
  630. //取得返回信息
  631. $thisr=ReturnDoclassVar($add['doing']);
  632. if(!$add['classname'])
  633. {
  634. printerror("Empty".$thisr['mess']."Classname","history.go(-1)");
  635. }
  636. //验证权限
  637. CheckLevel($userid,$username,$classid,$thisr['thelevel']);
  638. $add['classname']=hRepPostStr($add['classname'],1);
  639. $sql=$empire->query("insert into ".$thisr['tbname']."(classname) values('$add[classname]');");
  640. if($sql)
  641. {
  642. $lastid=$empire->lastid();
  643. //操作日志
  644. insert_dolog("classid=".$lastid."<br>classname=".$add[classname]);
  645. printerror("Add".$thisr['mess']."ClassSuccess",$thisr['returnpage']);
  646. }
  647. else
  648. {
  649. printerror("DbError","history.go(-1)");
  650. }
  651. }
  652. //修改分类
  653. function EditThisClass($add,$userid,$username){
  654. global $empire,$dbtbpre;
  655. //取得返回信息
  656. $thisr=ReturnDoclassVar($add['doing']);
  657. $classid=(int)$add['classid'];
  658. if(!$add['classname']||!$classid)
  659. {
  660. printerror("Empty".$thisr['mess']."Classname","history.go(-1)");
  661. }
  662. //验证权限
  663. CheckLevel($userid,$username,$classid,$thisr['thelevel']);
  664. $add['classname']=hRepPostStr($add['classname'],1);
  665. $sql=$empire->query("update ".$thisr['tbname']." set classname='$add[classname]' where classid='$classid'");
  666. if($sql)
  667. {
  668. //操作日志
  669. insert_dolog("classid=".$classid."<br>classname=".$add[classname]);
  670. printerror("Edit".$thisr['mess']."ClassSuccess",$thisr['returnpage']);
  671. }
  672. else
  673. {
  674. printerror("DbError","history.go(-1)");
  675. }
  676. }
  677. //删除分类
  678. function DelThisClass($classid,$doing,$userid,$username){
  679. global $empire,$dbtbpre;
  680. //取得返回信息
  681. $thisr=ReturnDoclassVar($doing);
  682. $classid=(int)$classid;
  683. if(!$classid)
  684. {
  685. printerror("NotChange".$thisr['mess']."Classid","history.go(-1)");
  686. }
  687. //验证权限
  688. CheckLevel($userid,$username,$classid,$thisr['thelevel']);
  689. $r=$empire->fetch1("select classname from ".$thisr['tbname']." where classid=$classid");
  690. $sql=$empire->query("delete from ".$thisr['tbname']." where classid=$classid");
  691. if($sql)
  692. {
  693. //操作日志
  694. insert_dolog("classid=".$classid."<br>classname=".$r[classname]);
  695. printerror("Del".$thisr['mess']."ClassSuccess",$thisr['returnpage']);
  696. }
  697. else
  698. {
  699. printerror("DbError","history.go(-1)");
  700. }
  701. }
  702. //批量替换地址权限
  703. function RepDownLevel($add,$userid,$username){
  704. global $empire,$public_r,$class_r,$fun_r,$dbtbpre;
  705. //验证权限
  706. CheckLevel($userid,$username,$classid,"repdownpath");
  707. $tbname=RepPostVar($add['tbname']);
  708. if(!$tbname||!($add[downpath]||$add[onlinepath])||!($add[dogroup]||$add[dofen]||$add[doqz]||$add[dopath]||$add[doname]))
  709. {printerror("EmptyRepDownLevel","history.go(-1)");}
  710. $start=(int)$add['start'];
  711. //转换变量
  712. if(empty($add[oldgroupid]))
  713. {
  714. $add[oldgroupid]=0;
  715. }
  716. if(empty($add[newgroupid]))
  717. {
  718. $add[newgroupid]=0;
  719. }
  720. if(empty($add[oldfen]))
  721. {
  722. $add[oldfen]=0;
  723. }
  724. if(empty($add[newfen]))
  725. {
  726. $add[newfen]=0;
  727. }
  728. if(empty($add[oldqz]))
  729. {
  730. $add[oldqz]=0;
  731. }
  732. if(empty($add[newqz]))
  733. {
  734. $add[newqz]=0;
  735. }
  736. //字段
  737. $field='';
  738. $sfield='';
  739. if($add['downpath'])
  740. {
  741. $field.=",downpath";
  742. $dh=",";
  743. $checkf='downpath';
  744. }
  745. if($add['onlinepath'])
  746. {
  747. $field.=",onlinepath";
  748. $checkf='onlinepath';
  749. }
  750. $fr=$empire->fetch1("select tid,savetxt,tbdataf from {$dbtbpre}enewsf where tbname='$tbname' and f='$checkf' limit 1");
  751. if($fr['tbdataf'])//副表
  752. {
  753. $sfield=$field;
  754. $field='';
  755. }
  756. $wheresql="";
  757. //栏目
  758. $classid=(int)$add['classid'];
  759. if($classid)
  760. {
  761. if(empty($class_r[$classid][islast]))//中级栏目
  762. {
  763. $where=ReturnClass($class_r[$classid][sonclass]);
  764. }
  765. else//终极栏目
  766. {
  767. $where="classid='$classid'";
  768. }
  769. $wheresql.=" and (".$where.")";
  770. }
  771. //附加sql语句
  772. $query=$add['query'];
  773. if($query)
  774. {
  775. //取除adds
  776. $query=ClearAddsData($query);
  777. $wheresql.=" and (".$query.")";
  778. }
  779. $update="";
  780. $b=0;
  781. $sql=$empire->query("select id,stb".$field." from {$dbtbpre}ecms_".$tbname." where id>$start".$wheresql." order by id limit ".$public_r['dorepdlevelnum']);
  782. while($r=$empire->fetch($sql))
  783. {
  784. $b=1;
  785. $newstart=$r[id];
  786. //副表
  787. if($fr['tbdataf'])
  788. {
  789. $finfor=$empire->fetch1("select id".$sfield." from {$dbtbpre}ecms_".$tbname."_data_".$r[stb]." where id='$r[id]'");
  790. $r['downpath']=$finfor['downpath'];
  791. $r['onlinepath']=$finfor['onlinepath'];
  792. }
  793. $update='';
  794. //下载地址
  795. $newdownpath="";
  796. if($add[downpath])
  797. {
  798. $newdownpath=RepDownLevelStrip($r[downpath],$add);
  799. $update="downpath='".addslashes($newdownpath)."'";
  800. }
  801. //在线地址
  802. $newonlinepath="";
  803. if($add[onlinepath])
  804. {
  805. $newonlinepath=RepDownLevelStrip($r[onlinepath],$add);
  806. $update.=$dh."onlinepath='".addslashes($newonlinepath)."'";
  807. }
  808. //副表
  809. if($fr['tbdataf'])
  810. {
  811. $empire->query("update {$dbtbpre}ecms_".$tbname."_data_".$r[stb]." set ".$update." where id='$r[id]'");
  812. }
  813. else
  814. {
  815. $empire->query("update {$dbtbpre}ecms_".$tbname." set ".$update." where id='$r[id]'");
  816. }
  817. }
  818. //替换完毕
  819. if(empty($b))
  820. {
  821. //未审核
  822. $sql=$empire->query("select id,stb".$field." from {$dbtbpre}ecms_".$tbname."_check".($wheresql?' where '.substr($wheresql,5):''));
  823. while($r=$empire->fetch($sql))
  824. {
  825. //副表
  826. if($fr['tbdataf'])
  827. {
  828. $finfor=$empire->fetch1("select id".$sfield." from {$dbtbpre}ecms_".$tbname."_check_data where id='$r[id]' limit 1");
  829. $r['downpath']=$finfor['downpath'];
  830. $r['onlinepath']=$finfor['onlinepath'];
  831. }
  832. $update='';
  833. //下载地址
  834. $newdownpath="";
  835. if($add[downpath])
  836. {
  837. $newdownpath=RepDownLevelStrip($r[downpath],$add);
  838. $update="downpath='".addslashes($newdownpath)."'";
  839. }
  840. //在线地址
  841. $newonlinepath="";
  842. if($add[onlinepath])
  843. {
  844. $newonlinepath=RepDownLevelStrip($r[onlinepath],$add);
  845. $update.=$dh."onlinepath='".addslashes($newonlinepath)."'";
  846. }
  847. //副表
  848. if($fr['tbdataf'])
  849. {
  850. $empire->query("update {$dbtbpre}ecms_".$tbname."_check_data set ".$update." where id='$r[id]'");
  851. }
  852. else
  853. {
  854. $empire->query("update {$dbtbpre}ecms_".$tbname."_check set ".$update." where id='$r[id]'");
  855. }
  856. }
  857. //操作日志
  858. insert_dolog("tbname=$tbname<br>downpath=$add[downpath]<br>onlinepath=$add[onlinepath]");
  859. printerror("RepDownLevelSuccess","DownSys/RepDownLevel.php".hReturnEcmsHashStrHref2(1));
  860. }
  861. EchoRepDownLevelForm($add,$newstart);
  862. }
  863. //替换权限处理函数
  864. function RepDownLevelStrip($downpath,$add){
  865. if(empty($downpath))
  866. {
  867. return "";
  868. }
  869. $add[oldpath]=ClearAddsData($add[oldpath]);
  870. $add[newpath]=ClearAddsData($add[newpath]);
  871. $add[oldname]=ClearAddsData($add[oldname]);
  872. $add[newname]=ClearAddsData($add[newname]);
  873. $f_exp="::::::";
  874. $r_exp="\r\n";
  875. $newdownpath="";
  876. $downpath=stripSlashes($downpath);
  877. $down_rr=explode($r_exp,$downpath);
  878. $count=count($down_rr);
  879. for($i=0;$i<$count;$i++)
  880. {
  881. $down_fr=explode($f_exp,$down_rr[$i]);
  882. //权限替换
  883. $d_groupid=(int)$down_fr[2];
  884. if($add[dogroup])
  885. {
  886. if($add[oldgroupid]=="no")//不设置
  887. {
  888. $d_groupid=$add[newgroupid];
  889. }
  890. else//设置
  891. {
  892. if($d_groupid==$add[oldgroupid])
  893. {
  894. $d_groupid=$add[newgroupid];
  895. }
  896. }
  897. }
  898. //点数转换
  899. $d_fen=(int)$down_fr[3];
  900. if($add[dofen])
  901. {
  902. if($add[oldfen]=="no")//不设置
  903. {
  904. $d_fen=$add[newfen];
  905. }
  906. else//设置
  907. {
  908. if($d_fen==$add[oldfen])
  909. {
  910. $d_fen=$add[newfen];
  911. }
  912. }
  913. }
  914. //前缀转换
  915. $d_qz=(int)$down_fr[4];
  916. if($add[doqz])
  917. {
  918. if($add[oldqz]=="no")//不设置
  919. {
  920. $d_qz=$add['newqz'];
  921. }
  922. else//设置
  923. {
  924. if($d_qz==$add[oldqz])
  925. {
  926. $d_qz=$add[newqz];
  927. }
  928. }
  929. }
  930. //地址替换
  931. $d_path=$down_fr[1];
  932. if($add[dopath]&&$add[oldpath])
  933. {
  934. $d_path=str_replace($add[oldpath],$add[newpath],$down_fr[1]);
  935. }
  936. //名称替换
  937. $d_name=$down_fr[0];
  938. if($add[doname]&&$add[oldname])
  939. {
  940. $d_name=str_replace($add[oldname],$add[newname],$down_fr[0]);
  941. }
  942. //组合
  943. $newdownpath.=$d_name.$f_exp.$d_path.$f_exp.$d_groupid.$f_exp.$d_fen.$f_exp.$d_qz.$r_exp;
  944. }
  945. //去掉最后的字符
  946. $newdownpath=substr($newdownpath,0,strlen($newdownpath)-2);
  947. return $newdownpath;
  948. }
  949. //输出批量替换下载权限表单
  950. function EchoRepDownLevelForm($add,$newstart){
  951. global $fun_r;
  952. ?>
  953. <?=$fun_r['RepOneDLeveSuccess']?>(ID:<font color=red><b><?=$newstart?></b></font>)
  954. <form name="RepDownLevelForm" method="post" action="ecmscom.php">
  955. <?=hReturnEcmsHashStrForm(0)?>
  956. <input type=hidden name="enews" value="RepDownLevel">
  957. <input type=hidden name="start" value="<?=$newstart?>">
  958. <input type=hidden name="tbname" value="<?=$add['tbname']?>">
  959. <input type=hidden name="classid" value="<?=$add['classid']?>">
  960. <input type=hidden name="downpath" value="<?=$add['downpath']?>">
  961. <input type=hidden name="onlinepath" value="<?=$add['onlinepath']?>">
  962. <input type=hidden name="dogroup" value="<?=$add['dogroup']?>">
  963. <input type=hidden name="oldgroupid" value="<?=$add['oldgroupid']?>">
  964. <input type=hidden name="newgroupid" value="<?=$add['newgroupid']?>">
  965. <input type=hidden name="dofen" value="<?=$add['dofen']?>">
  966. <input type=hidden name="oldfen" value="<?=$add['oldfen']?>">
  967. <input type=hidden name="newfen" value="<?=$add['newfen']?>">
  968. <input type=hidden name="doqz" value="<?=$add['doqz']?>">
  969. <input type=hidden name="oldqz" value="<?=$add['oldqz']?>">
  970. <input type=hidden name="newqz" value="<?=$add['newqz']?>">
  971. <input type=hidden name="dopath" value="<?=$add['dopath']?>">
  972. <input type=hidden name="oldpath" value="<?=ehtmlspecialchars(ClearAddsData($add['oldpath']))?>">
  973. <input type=hidden name="newpath" value="<?=ehtmlspecialchars(ClearAddsData($add['newpath']))?>">
  974. <input type=hidden name="doname" value="<?=$add['doname']?>">
  975. <input type=hidden name="oldname" value="<?=ehtmlspecialchars(ClearAddsData($add['oldname']))?>">
  976. <input type=hidden name="newname" value="<?=ehtmlspecialchars(ClearAddsData($add['newname']))?>">
  977. <input type=hidden name="query" value="<?=ehtmlspecialchars(ClearAddsData($add['query']))?>">
  978. </form>
  979. <script>
  980. document.RepDownLevelForm.submit();
  981. </script>
  982. <?
  983. exit();
  984. }
  985. //清空临时数据与文件
  986. function ClearTmpFileData($add,$userid,$username){
  987. global $empire,$public_r,$dbtbpre;
  988. //验证权限
  989. CheckLevel($userid,$username,$classid,"changedata");
  990. //临时文件目录
  991. $tmppath=eReturnTrueEcmsPath().'e/data/tmp';
  992. $hand=@opendir($tmppath);
  993. while($file=@readdir($hand))
  994. {
  995. if($file=='.'||$file=='..'||$file=='test.txt'||$file=='index.html'||$file=='mod'||$file=='temp'||$file=='titlepic'||$file=='cj')
  996. {
  997. continue;
  998. }
  999. $filename=$tmppath.'/'.$file;
  1000. if(!is_dir($filename))
  1001. {
  1002. DelFiletext($filename);
  1003. }
  1004. }
  1005. //临时模板导出目录
  1006. $temppath=eReturnTrueEcmsPath().'e/data/tmp/temp';
  1007. $hand=@opendir($temppath);
  1008. while($file=@readdir($hand))
  1009. {
  1010. if($file=='.'||$file=='..'||$file=='test.txt'||$file=='index.php')
  1011. {
  1012. continue;
  1013. }
  1014. $filename=$temppath.'/'.$file;
  1015. if(!is_dir($filename))
  1016. {
  1017. DelFiletext($filename);
  1018. }
  1019. }
  1020. //临时模型导出目录
  1021. $modpath=eReturnTrueEcmsPath().'e/data/tmp/mod';
  1022. $hand=@opendir($modpath);
  1023. while($file=@readdir($hand))
  1024. {
  1025. if($file=='.'||$file=='..'||$file=='test.txt'||$file=='index.php')
  1026. {
  1027. continue;
  1028. }
  1029. $filename=$modpath.'/'.$file;
  1030. if(!is_dir($filename))
  1031. {
  1032. DelFiletext($filename);
  1033. }
  1034. }
  1035. //临时采集导出目录
  1036. $cjpath=eReturnTrueEcmsPath().'e/data/tmp/cj';
  1037. $hand=@opendir($cjpath);
  1038. while($file=@readdir($hand))
  1039. {
  1040. if($file=='.'||$file=='..'||$file=='test.txt'||$file=='index.html')
  1041. {
  1042. continue;
  1043. }
  1044. $filename=$cjpath.'/'.$file;
  1045. if(!is_dir($filename))
  1046. {
  1047. DelFiletext($filename);
  1048. }
  1049. }
  1050. //采集临时表
  1051. $empire->query("TRUNCATE `{$dbtbpre}enewslinktmp`;");
  1052. //远程发布临时表
  1053. $empire->query("TRUNCATE `{$dbtbpre}enewspostdata`;");
  1054. printerror('ClearTmpFileDataSuccess','');
  1055. }
  1056. //清理多余信息
  1057. function ClearBreakInfo($add,$userid,$username){
  1058. global $empire,$dbtbpre;
  1059. CheckLevel($userid,$username,$classid,"changedata");//验证权限
  1060. $tid=(int)$add['tid'];
  1061. if(!$tid)
  1062. {
  1063. printerror('EmptyDocTb','');
  1064. }
  1065. $tbr=$empire->fetch1("select datatbs,tbname from {$dbtbpre}enewstable where tid='$tid'");
  1066. if(!$tbr['tbname'])
  1067. {
  1068. printerror('EmptyDocTb','');
  1069. }
  1070. $affnum=0;
  1071. if($tbr['datatbs'])
  1072. {
  1073. $dtbr=explode(',',$tbr['datatbs']);
  1074. $count=count($dtbr);
  1075. $dodatatbs='';
  1076. $andunion='';
  1077. for($i=1;$i<$count-1;$i++)
  1078. {
  1079. $dodatatbs.=$andunion."select id from {$dbtbpre}ecms_".$tbr['tbname']."_data_".$dtbr[$i];
  1080. $andunion=' union ';
  1081. }
  1082. if($dodatatbs)
  1083. {
  1084. $empire->query("delete from {$dbtbpre}ecms_".$tbr['tbname']." where id not in (".$dodatatbs.")");
  1085. $affnum=$empire->affectnum();
  1086. }
  1087. }
  1088. $GLOBALS['cbinfoaffnum']=$affnum;
  1089. //操作日志
  1090. insert_dolog("tid=".$tid."<br>tbname=".$tbr['tbname']);
  1091. printerror("ClearBreakInfoSuccess","");
  1092. }
  1093. //重置信息或评论数统计
  1094. function ResetAddDataNum($type,$from,$userid,$username){
  1095. global $empire,$dbtbpre;
  1096. if($type=='info')
  1097. {
  1098. //CheckLevel($userid,$username,$classid,"info");//验证权限
  1099. }
  1100. elseif($type=='pl')
  1101. {
  1102. //CheckLevel($userid,$username,$classid,"pl");//验证权限
  1103. }
  1104. else
  1105. {
  1106. printerror("ErrorUrl","");
  1107. }
  1108. CheckLevel($userid,$username,$classid,"changedata");//验证权限
  1109. DoResetAddDataNum($type);
  1110. $returnurl=$from?$from:EcmsGetReturnUrl();
  1111. //操作日志
  1112. insert_dolog("type=".$type);
  1113. printerror("ResetAddDataNumSuccess",$returnurl);
  1114. }
  1115. ?>