/home/mjc1/public_html/member/search_info.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
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
<? 
$doc_name 
"search_info";
//require_once("./member/member_class.php");
$member_class = new member_class();


$get_row $member_class->search_pw($name,$jumin1,$jumin2);
if(!
$get_row[id]){
    echo (
"
    <script>
    alert ('ȸ¿ø Á¤º¸°¡ ¾ø½À´Ï´Ù.');
    history.back();
    </script>"
);
    exit;


}
// ¸ÞÀÏ ¹ß¼Û ½ÃÀÛ
$s_name "µ¿±¤±³È¸ °ü¸®ÀÚ";
//$s_mail = $admin_mail;
$s_mail "linuxer702@empas.com";
$r_name $get_row[name];
$r_mail $get_row[email];
$subject "¾È³çÇϼ¼¿ä. µ¿±¤±³È¸ ÀÔ´Ï´Ù.";
$content $get_row[pass];

if (!
eregi("[^[:space:]]+",$s_name))
{
    echo (
"
        <script>
        alert ('º¸³»´Â »ç¶÷ À̸§À» ÀÔ·ÂÇϼ¼¿ä.');
        history.back();
        </script>
        "
);
    exit;
}
if (!
ereg("(^[_0-9a-zA-Z-]+(\.[_0-9a-zA-Z]+)*@[0-9a-zA-Z-]+(\.[0-9a-zA-Z]+)*$)",$s_mail))
{
    echo (
"
        <script>
        alert ('º¸³»´Â ¸ÞÀÏÀÇ Çü½ÄÀÌ À߸øµÇ¾ú½À´Ï´Ù!');
        history.back();
        </script>
        "
);
    exit;
}
if (!
eregi("([^[:space:]]+)",$r_name))
{
    echo (
"
        <script>
        alert ('¹Þ´Â »ç¶÷ À̸§À» ÀÔ·ÂÇϼ¼¿ä.');
        history.back();
        </script>
        "
);
    exit;
}
if (!
ereg("(^[_0-9a-zA-Z-]+(\.[_0-9a-zA-Z]+)*@[0-9a-zA-Z-]+(\.[0-9a-zA-Z]+)*$)",$r_mail))
{
    echo (
"
        <script>
        alert ('¹Þ´Â ¸ÞÀÏÀÇ Çü½ÄÀÌ À߸øµÇ¾ú½À´Ï´Ù!');
        history.back();
        </script>
        "
);
    exit;
}
if (!
eregi("([^[:space:]]+)",$subject))
{
    echo (
"
        <script>
        alert ('Á¦¸ñÀ» ÀÔ·ÂÇϼ¼¿ä!');
        history.back();
        </script>
        "
);
    exit;
}
if (!
eregi("([^[:space:]]+)",$content))
{
    echo (
"
        <script>
        alert ('³»¿ëÀ» ÀÔ·ÂÇϼ¼¿ä!');
        history.back();
        </script>
        "
);
    exit;
}

$from $s_name." <".$s_mail.">";                        // º¸³»´Â »ç¶÷ÀÇ À̸§.< º¸³»´Â »ç¶÷ÀÇ ¸ÞÀÏÁÖ¼Ò>
$mailto $r_name." <".$r_mail.">";                        // ¹Þ´Â »ç¶÷ÀÇ À̸§.< ¹Þ´Â »ç¶÷ÀÇ ¸ÞÀÏÁÖ¼Ò>
$additional_headers "Reply-To: $s_mail\r\n";            // Àü¼ÛÀÌ µÇÁö ¾Ê¾Ò´Âµ¥ µÇµ¹¾Æ¿Ã ÁÖ¼Ò
$additional_headers .= "From: $from\r\n";    // º¸³»´Â »ç¶÷ÀÇ ÁÖ¼Ò(»ó´ë¹æÀÇ 'º¸³½»ç¶÷'¶õ¿¡ ÀÌ Çü½ÄÀÌ ³ªÅ¸³²)
$additional_headers .= "content-type:text/html;charset=euc-kr\n";    // htmlÀ» »ç¿ëÇØ¼­ º¸³¿
$mail_content "
<html>
<head>
</head>
<body>
<table width='781' cellpadding='0' cellspacing='0' border='0' align='center'>
<tr>
    <td>
        <table width='650' cellspacing='0' cellpadding='0'>
        <tr>
            <td height='15' colspan='3' bgcolor='#EFF4FE'>&nbsp;</td>
        </tr><tr>
            <td width='15' rowspan='4' bgcolor='#EFF4FE'>&nbsp;</td>
            <td width='610'></td>
        </tr><tr>
            <td>
$r_name ´ÔÀÇ ºñ¹Ð¹øÈ£´Â <b>".nl2br(stripslashes($content))."</b>ÀÔ´Ï´Ù.<br>
            °³ÀÎÁ¤º¸°¡ À¯ÃâµÉ ¼ö ÀÖÀ¸´Ï ºñ¹Ð¹øÈ£¸¦ È®ÀΠÈÄ¿¡´Â ¹Ýµå½Ã »èÁ¦ÇÏ¿© ÁֽʽÿÀ.</td>
        </tr><tr>
            <td height='15' colspan='3' bgcolor='#EFF4FE'>&nbsp;</td>
        </tr>
        </table>
    </td>
</tr>
</table>
</body>
</html>"
;

$result mail($mailto$subject$mail_content$additional_headers);
if (
$result == TRUE)
{
    echo(
"
        <script>
        alert('¸ÞÀÏÀÌ Àü¼Û µÇ¾ú½À´Ï´Ù. º»ÀÎÀÇ ¸ÞÀϰèÁ¤¿¡¼­ È®ÀÎÇØ º¸½Ê½Ã¿À.');
        </script>
        <meta http-equiv='refresh' content='0; url=../join.htm'>
        "
);
} else {
    echo(
"
        <script>
        alert('¸ÞÀÏ Àü¼Û ½ÇÆÐÀÔ´Ï´Ù. ´Ù½Ã ½ÃµµÇØ º¸¼¼¿ä.');
        history.back();
        </script>
        "
);
}
?>