index.php 1.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990
  1. <?php
  2. require("../class/connect.php");
  3. require("../class/db_sql.php");
  4. require("../data/dbcache/class.php");
  5. require("../member/class/user.php");
  6. require("../data/dbcache/MemberLevel.php");
  7. require LoadLang("pub/fun.php");
  8. $link=db_connect();
  9. $empire=new mysqlquery();
  10. $enews=$_POST['enews'];
  11. if(empty($enews))
  12. {
  13. $enews=$_GET['enews'];
  14. }
  15. //导入文件
  16. if($enews=='AddVote'||$enews=='AddInfoVote'||$enews=='AddInfoPfen')
  17. {
  18. include('votefun.php');
  19. }
  20. elseif($enews=='AddGbook')
  21. {
  22. include('gbookfun.php');
  23. }
  24. else
  25. {
  26. include('../class/q_functions.php');
  27. }
  28. if($enews=='AddVote')//增加投票
  29. {
  30. if($_GET['voteid'])
  31. {
  32. $voteid=$_GET['voteid'];
  33. $vote=$_GET['vote'];
  34. }
  35. else
  36. {
  37. $voteid=$_POST['voteid'];
  38. $vote=$_POST['vote'];
  39. }
  40. AddVote($voteid,$vote);
  41. }
  42. elseif($enews=='AddInfoVote')//增加信息投票
  43. {
  44. if($_GET['id'])
  45. {
  46. $id=$_GET['id'];
  47. $classid=$_GET['classid'];
  48. $vote=$_GET['vote'];
  49. }
  50. else
  51. {
  52. $id=$_POST['id'];
  53. $classid=$_POST['classid'];
  54. $vote=$_POST['vote'];
  55. }
  56. AddInfoVote($classid,$id,$vote);
  57. }
  58. elseif($enews=='AddInfoPfen')//信息评分
  59. {
  60. if($_GET['id'])
  61. {
  62. $add=$_GET;
  63. }
  64. else
  65. {
  66. $add=$_POST;
  67. }
  68. AddInfoPfen($add);
  69. }
  70. elseif($enews=="AddGbook")//增加留言
  71. {
  72. eCheckCloseMods('gb');//关闭模块
  73. AddGbook($_POST);
  74. }
  75. elseif($enews=="AddFeedback")//增加反馈
  76. {
  77. eCheckCloseMods('fb');//关闭模块
  78. $doetran=1;
  79. AddFeedback($_POST);
  80. }
  81. elseif($enews=="AddError")//增加错误报告
  82. {
  83. eCheckCloseMods('error');//关闭模块
  84. AddError($_POST);
  85. }
  86. else
  87. {printerror("ErrorUrl","history.go(-1)",1);}
  88. db_close();
  89. $empire=null;
  90. ?>