하루꼬박 해메고 있습니다 코멘트작성시 관리자메일관련...
본문
코멘트 메일발송에 체크를 하면서 보니까
체크박스 옆에
[ ]사용 (원글에 코멘트가 올라오는 경우 코멘트 쓴 모든 분들께 메일을 발송합니다.)
이라고 되어 있습니다.
이걸 최고관리자만 메일을 받게 하고 싶은데 어디서 손대야할지 모르겠습니다. ㅠㅠ
일단 bbs/write_comment_update.php 이 부분인것 같은데
최고 관리자만 메일을 받게 하려면 어떻게 해야할까요??? 도와주십시요 ㅠㅠ
include_once("$g4[path]/lib/mailer.lib.php");
ob_start();
include_once ("./write_update_mail.php");
$content = ob_get_contents();
ob_end_clean();
$array_email = array();
// 게시판관리자에게 보내는 메일 ==> 주석처리함
// if ($config[cf_email_wr_board_admin]) $array_email[] = $board_admin[mb_email];
// 게시판그룹관리자에게 보내는 메일 ==> 주석처리함
// if ($config[cf_email_wr_group_admin]) $array_email[] = $group_admin[mb_email];
// 최고관리자에게 보내는 메일
if ($config[cf_email_wr_super_admin]) $array_email[] = $super_admin[mb_email];
// 옵션에 메일받기가 체크되어 있고, 게시자의 메일이 있다면
if (strstr($wr[wr_option], "mail") && $wr[wr_email]) {
// 원글 메일발송에 체크가 되어 있다면
if ($config[cf_email_wr_write]) $array_email[] = $wr[wr_email];
// 코멘트 쓴 모든이에게 메일 발송이 되어 있다면 (자신에게는 발송하지 않는다)
if ($config[cf_email_wr_comment_all]) {
$sql = " select distinct wr_email from $write_table
where wr_email not in ( '$wr[wr_email]', '$member[mb_email]', '' )
and wr_parent = '$wr_id' ";
$result = sql_query($sql);
while ($row=sql_fetch_array($result))
$array_email[] = $row[wr_email];
}
}
답변 1
최고관리자만 메일을 받게 하고 싶다고 하셨으니, 소스에 최고관리자쪽 로직은 그대로 두고
// 옵션에 메일받기가 체크되어 있고, 게시자의 메일이 있다면
위 주석아래 소스만 주석처리하시면 됩니다.
답변을 작성하시기 전에 로그인 해주세요.