/
account_delete_page.php
48 lines (40 loc) · 1.27 KB
/
account_delete_page.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
<?php
# Mantis - a php based bugtracking system
# Copyright (C) 2000 - 2002 Kenzaburo Ito - kenito@300baud.org
# This program is distributed under the terms and conditions of the GPL
# See the README and LICENSE files for details
?>
<?php
# This is the delete confirmation page
# The result is POSTed to account_delete.php3
?>
<?php include( "core_API.php" ) ?>
<?php login_cookie_check() ?>
<?php
db_connect( $g_hostname, $g_db_username, $g_db_password, $g_database_name );
# check if users can't delete their own accounts
if ( OFF == $g_allow_account_delete ) {
print_header_redirect( $g_account_page );
}
# get protected state
$t_protected = get_current_user_field( "protected" );
# protected account check
if ( ON == $t_protected ) {
print_mantis_error( ERROR_PROTECTED_ACCOUNT );
}
if ( OFF == $g_allow_account_delete ) {
print_header_redirect( $g_account_page );
}
?>
<?php print_page_top1() ?>
<?php print_page_top2() ?>
<p>
<div align="center">
<?php print_hr( $g_hr_size, $g_hr_width ) ?>
<?php echo $s_confirm_delete_msg ?>
<form method="post" action="<?php echo $g_account_delete ?>">
<input type="submit" value="<?php echo $s_delete_account_button ?>">
</form>
<?php print_hr( $g_hr_size, $g_hr_width ) ?>
</div>
<?php print_page_bot1( __FILE__ ) ?>