index.php 897 B

123456789101112131415161718192021222324252627282930313233343536
  1. <?php
  2. require("../../../class/connect.php");
  3. require("../../../class/q_functions.php");
  4. require("../../../class/db_sql.php");
  5. require("../../class/user.php");
  6. $link=db_connect();
  7. $empire=new mysqlquery();
  8. $editor=2;
  9. eCheckCloseMods('member');//关闭模块
  10. $user=islogin();
  11. $mid=(int)$_GET['mid'];
  12. $username=RepPostStr($_GET['username']);
  13. $re=RepPostStr($_GET['re']);
  14. $title='';
  15. $msgtext='';
  16. if($mid)
  17. {
  18. $r=$empire->fetch1("select title,msgtext,from_username from {$dbtbpre}enewsqmsg where mid=$mid and to_username='$user[username]' limit 1");
  19. if(empty($username)&&$r['from_username']!=$user['username'])
  20. {
  21. $username=$r['from_username'];
  22. }
  23. $title=$r['title'];
  24. $msgtext=$r['msgtext'];
  25. //回复
  26. if($re==1)
  27. {
  28. $title="Re:".$title;
  29. $msgtext="\r\n"."------原文内容------\r\n".$msgtext;
  30. }
  31. }
  32. //导入模板
  33. require(ECMS_PATH.'e/template/member/AddMsg.php');
  34. db_close();
  35. $empire=null;
  36. ?>