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
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
|
<?php $dir = "."; include_once($dir."/_common.php");
if($eid==''){ alert('e천년경영 로그인 후에 이용가능합니다.',"index.php"); exit; }
$all_sql = "";
$sql = "select * from user_config where menu_name = 'EmailOptionWindow' "; $res = mysql_query($sql,$connect_e1000y); while($minfo = mysql_fetch_array($res)){ if($minfo['config_key']=='메일서버정보_보내는사람주소'){ $old_uc_email = $minfo['config_val']; } if($minfo['config_key']=='메일서버정보_SMTP'){ $old_uc_smtp = $minfo['config_val']; } if($minfo['config_key']=='메일서버정보_포트번호'){ $old_uc_port = $minfo['config_val']; } if($minfo['config_key']=='메일서버정보_사용자_ID'){ $old_uc_id = $minfo['config_val']; } if($minfo['config_key']=='메일서버정보_패스워드2'){ $old_uc_pw = $minfo['config_val']; } }
if(!isset($old_uc_email) && $old_uc_email==''){ $sql = "insert into user_config set config_val = '$uc_email', data_updated = '".date("Y-m-d H:i:s",time())."', menu_name = 'EmailOptionWindow', config_key = '메일서버정보_보내는사람주소'"; mysql_query($sql,$connect_e1000y); $all_sql .= $sql; } else if($old_uc_email!=$uc_email){ $sql = "update user_config set config_val = '$uc_email', data_updated = '".date("Y-m-d H:i:s",time())."' where menu_name = 'EmailOptionWindow' and config_key = '메일서버정보_보내는사람주소' "; mysql_query($sql,$connect_e1000y); $all_sql .= $sql; }
if(!isset($old_uc_smtp) && $old_uc_smtp==''){ $sql = "insert into user_config set config_val = '$uc_smtp', data_updated = '".date("Y-m-d H:i:s",time())."', menu_name = 'EmailOptionWindow', config_key = '메일서버정보_SMTP'"; mysql_query($sql,$connect_e1000y); $all_sql .= $sql; } else if($old_uc_smtp!=$uc_smtp){ $sql = "update user_config set config_val = '$uc_smtp', data_updated = '".date("Y-m-d H:i:s",time())."' where menu_name = 'EmailOptionWindow' and config_key = '메일서버정보_SMTP' "; mysql_query($sql,$connect_e1000y); $all_sql .= $sql; }
if(!isset($old_uc_port) && $old_uc_port==''){ $sql = "insert into user_config set config_val = '$uc_port', data_updated = '".date("Y-m-d H:i:s",time())."', menu_name = 'EmailOptionWindow', config_key = '메일서버정보_포트번호'"; mysql_query($sql,$connect_e1000y); $all_sql .= $sql; } else if($old_uc_port!=$uc_port){ $sql = "update user_config set config_val = '$uc_port', data_updated = '".date("Y-m-d H:i:s",time())."' where menu_name = 'EmailOptionWindow' and config_key = '메일서버정보_포트번호' "; mysql_query($sql,$connect_e1000y); $all_sql .= $sql; }
if(!isset($old_uc_id) && $old_uc_id==''){ $sql = "insert into user_config set config_val = '$uc_id', data_updated = '".date("Y-m-d H:i:s",time())."', menu_name = 'EmailOptionWindow', config_key = '메일서버정보_사용자_ID'"; mysql_query($sql,$connect_e1000y); $all_sql .= $sql; } else if($old_uc_id!=$uc_id){ $sql = "update user_config set config_val = '$uc_id', data_updated = '".date("Y-m-d H:i:s",time())."' where menu_name = 'EmailOptionWindow' and config_key = '메일서버정보_사용자_ID' "; mysql_query($sql,$connect_e1000y); $all_sql .= $sql; }
$enc_uc_pw = encrypt($uc_pw,"m.j.s.f.t");
if(!isset($old_uc_pw) && $old_uc_pw==''){ $sql = "insert into user_config set config_val = '$enc_uc_pw', data_updated = '".date("Y-m-d H:i:s",time())."', menu_name = 'EmailOptionWindow', config_key = '메일서버정보_패스워드2'"; mysql_query($sql,$connect_e1000y); $all_sql .= $sql; } else if($old_uc_pw!=$enc_uc_pw){ $sql = "update user_config set config_val = '$enc_uc_pw', data_updated = '".date("Y-m-d H:i:s",time())."' where menu_name = 'EmailOptionWindow' and config_key = '메일서버정보_패스워드2' "; mysql_query($sql,$connect_e1000y); $all_sql .= $sql; }
?> <script> document.location.href='email.php?time=<?php echo time();?>'; </script>
|