ListFeedbackF.php 4.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124
  1. <?php
  2. define('EmpireCMSAdmin','1');
  3. require("../../class/connect.php");
  4. require("../../class/db_sql.php");
  5. require("../../class/functions.php");
  6. $link=db_connect();
  7. $empire=new mysqlquery();
  8. $editor=1;
  9. //验证用户
  10. $lur=is_login();
  11. $logininid=$lur['userid'];
  12. $loginin=$lur['username'];
  13. $loginrnd=$lur['rnd'];
  14. $loginlevel=$lur['groupid'];
  15. $loginadminstyleid=$lur['adminstyleid'];
  16. //ehash
  17. $ecms_hashur=hReturnEcmsHashStrAll();
  18. //验证权限
  19. CheckLevel($logininid,$loginin,$classid,"feedbackf");
  20. $enews=$_POST['enews'];
  21. if(empty($enews))
  22. {$enews=$_GET['enews'];}
  23. if($enews)
  24. {
  25. hCheckEcmsRHash();
  26. include("../../class/com_functions.php");
  27. }
  28. if($enews=="AddFeedbackF")
  29. {
  30. AddFeedbackF($_POST,$logininid,$loginin);
  31. }
  32. elseif($enews=="EditFeedbackF")
  33. {
  34. EditFeedbackF($_POST,$logininid,$loginin);
  35. }
  36. elseif($enews=="DelFeedbackF")
  37. {
  38. DelFeedbackF($_GET,$logininid,$loginin);
  39. }
  40. elseif($enews=="EditFeedbackFOrder")
  41. {
  42. EditFeedbackFOrder($_POST['fid'],$_POST['myorder'],$logininid,$loginin);
  43. }
  44. $url="<a href=feedback.php".$ecms_hashur['whehref'].">管理信息反馈</a>&nbsp;>&nbsp;<a href=FeedbackClass.php".$ecms_hashur['whehref'].">信息反馈分类管理</a>&nbsp;>&nbsp;<a href=ListFeedbackF.php".$ecms_hashur['whehref'].">管理反馈字段</a>";
  45. $sql=$empire->query("select * from {$dbtbpre}enewsfeedbackf order by myorder,fid");
  46. ?>
  47. <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
  48. <html>
  49. <head>
  50. <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
  51. <title>管理字段</title>
  52. <link href="../adminstyle/<?=$loginadminstyleid?>/adminstyle.css" rel="stylesheet" type="text/css">
  53. </head>
  54. <body>
  55. <table width="100%" border="0" align="center" cellpadding="3" cellspacing="1">
  56. <tr>
  57. <td width="50%">位置:
  58. <?=$url?>
  59. </td>
  60. <td><div align="right" class="emenubutton">
  61. <input type="button" name="Submit2" value="新建字段" onclick="self.location.href='AddFeedbackF.php?enews=AddFeedbackF<?=$ecms_hashur['ehref']?>';">
  62. </div></td>
  63. </tr>
  64. </table>
  65. <form name="form1" method="post" action="ListFeedbackF.php" onsubmit="return confirm('确认要操作?');">
  66. <table width="100%" border="0" align="center" cellpadding="3" cellspacing="1" class="tableborder">
  67. <?=$ecms_hashur['form']?>
  68. <tr class="header">
  69. <td width="6%" height="25"><div align="center">顺序</div></td>
  70. <td width="27%" height="25">
  71. <div align="center">字段名</div></td>
  72. <td width="27%">
  73. <div align="center">字段标识</div></td>
  74. <td width="23%"><div align="center">字段类型</div></td>
  75. <td width="17%" height="25"><div align="center">操作</div></td>
  76. </tr>
  77. <?
  78. while($r=$empire->fetch($sql))
  79. {
  80. $ftype=$r[ftype];
  81. if($r[flen])
  82. {
  83. if($r[ftype]!="TEXT"&&$r[ftype]!="MEDIUMTEXT"&&$r[ftype]!="LONGTEXT")
  84. {
  85. $ftype.="(".$r[flen].")";
  86. }
  87. }
  88. ?>
  89. <tr bgcolor="ffffff" onmouseout="this.style.backgroundColor='#ffffff'" onmouseover="this.style.backgroundColor='#C3EFFF'">
  90. <td height="25"><div align="center">
  91. <input name="myorder[]" type="text" id="myorder[]" value="<?=$r[myorder]?>" size="3">
  92. <input type=hidden name=fid[] value=<?=$r[fid]?>>
  93. </div></td>
  94. <td height="25"><div align="center">
  95. <?=$r[f]?>
  96. </div></td>
  97. <td><div align="center">
  98. <?=$r[fname]?>
  99. </div></td>
  100. <td><div align="center">
  101. <?=$ftype?>
  102. </div></td>
  103. <td height="25"><div align="center">
  104. [<a href='AddFeedbackF.php?enews=EditFeedbackF&fid=<?=$r[fid]?><?=$ecms_hashur['ehref']?>'>修改</a>]&nbsp;&nbsp;[<a href='ListFeedbackF.php?enews=DelFeedbackF&fid=<?=$r[fid]?><?=$ecms_hashur['href']?>' onclick="return confirm('确认要删除?');">删除</a>]
  105. </div></td>
  106. </tr>
  107. <?
  108. }
  109. ?>
  110. <tr bgcolor="ffffff">
  111. <td height="25">&nbsp;</td>
  112. <td height="25" colspan="4"><input type="submit" name="Submit" value="修改字段顺序">
  113. (值越小越前面) <input name="enews" type="hidden" id="enews" value="EditFeedbackFOrder">
  114. </td>
  115. </tr>
  116. </table>
  117. </form>
  118. </body>
  119. </html>
  120. <?
  121. db_close();
  122. $empire=null;
  123. ?>