/[LeafOK_CVS]/fenglin/bbs/suicide.php
ViewVC logotype

Contents of /fenglin/bbs/suicide.php

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.14 - (show annotations)
Mon Apr 14 04:27:11 2025 UTC (11 months ago) by sysadm
Branch: MAIN
Changes since 1.13: +33 -45 lines
Refact close account

1 <?
2 require_once "./session_init.inc.php";
3 require_once "./common_lib.inc.php";
4 require_once "./theme.inc.php";
5
6 force_login();
7
8 $result_set = array(
9 "return" => array(
10 "code" => 0,
11 "message" => "",
12 "errorFields" => array(),
13 )
14 );
15
16 if (!$_SESSION["BBS_priv"]->checkpriv(0, S_POST) ||
17 $_SESSION["BBS_priv"]->checklevel(P_ADMIN_M | P_ADMIN_S | P_MAN_M | P_MAN_S))
18 {
19 $result_set["return"]["code"] = -1;
20 $result_set["return"]["message"] = "没有权限";
21
22 mysqli_close($db_conn);
23 exit(json_encode($result_set));
24 }
25
26 if ($_SESSION["BBS_login_tm"] < time() - 60) // login earlier than 1 minute
27 {
28 header ("Location: index.php?msg=1&redir=suicide.php");
29 exit();
30 }
31
32 // Output with theme view
33 $theme_view_file = get_theme_file("view/suicide", $_SESSION["BBS_theme_name"]);
34 if ($theme_view_file == null)
35 {
36 exit(json_encode($result_set)); // Output data in Json
37 }
38 include $theme_view_file;
39 ?>

webmaster@leafok.com
ViewVC Help
Powered by ViewVC 1.3.0-beta1