회원메일발송에 cheditor 적용하기 정보
회원메일발송에 cheditor 적용하기본문
adm/mail_form.php 를 아래의 코드로 대체합니다.
<?
$sub_menu = "200300";
include_once("./_common.php");
include_once ("$g4[path]/lib/cheditor4.lib.php");
$sub_menu = "200300";
include_once("./_common.php");
include_once ("$g4[path]/lib/cheditor4.lib.php");
auth_check($auth[$sub_menu], "r");
$token = get_token();
$html_title = "회원메일";
if ($w == "u") {
$html_title .= "수정";
$readonly = " readonly";
$html_title .= "수정";
$readonly = " readonly";
$sql = " select * from $g4[mail_table] where ma_id = '$ma_id' ";
$ma = sql_fetch($sql);
if (!$ma[ma_id])
alert("등록된 자료가 없습니다.");
} else {
$html_title .= "입력";
}
$ma = sql_fetch($sql);
if (!$ma[ma_id])
alert("등록된 자료가 없습니다.");
} else {
$html_title .= "입력";
}
$g4[title] = $html_title;
include_once("./admin.head.php");
?>
include_once("./admin.head.php");
?>
<script src="<?=$g4[cheditor4_path]?>/cheditor.js"></script>
<?=cheditor1('ma_content', '100%', '350');?>
<?=cheditor1('ma_content', '100%', '350');?>
<form name=fmailform method=post action="./mail_update.php" onsubmit="return fmailform_check(this);">
<input type=hidden name=w value='<?=$w?>'>
<input type=hidden name=ma_id value='<?=$ma[ma_id]?>'>
<input type=hidden name=token value='<?=$token?>'>
<table cellpadding=0 cellspacing=0 width=100%>
<colgroup width=20% class='col1 pad1 bold right'>
<colgroup width=80% class='col2 pad2'>
<tr>
<td colspan=2 class=title align=left><img src='<?=$g4[admin_path]?>/img/icon_title.gif'> <?=$html_title?></td>
</tr>
<tr><td colspan=2 class='line1'></td></tr>
<tr class='ht'>
<td>메일 제목</td>
<td><input type=text class='ed w99' name=ma_subject value='<?=$ma[ma_subject]?>' required itemname='메일 제목'></td>
</tr>
<tr>
<td>메일 내용</td>
<td class=lh>
<?=cheditor2('ma_content', $ma[ma_content]);?>
<br>{이름} , {별명} , {회원아이디} , {이메일} , {생일}
<br>위와 같이 HTML 코드에 삽입하면 해당 내용에 맞게 변환하여 메일 발송합니다.
</td>
</tr>
<tr><td colspan=2 class='line1'></td></tr>
</table>
<input type=hidden name=w value='<?=$w?>'>
<input type=hidden name=ma_id value='<?=$ma[ma_id]?>'>
<input type=hidden name=token value='<?=$token?>'>
<table cellpadding=0 cellspacing=0 width=100%>
<colgroup width=20% class='col1 pad1 bold right'>
<colgroup width=80% class='col2 pad2'>
<tr>
<td colspan=2 class=title align=left><img src='<?=$g4[admin_path]?>/img/icon_title.gif'> <?=$html_title?></td>
</tr>
<tr><td colspan=2 class='line1'></td></tr>
<tr class='ht'>
<td>메일 제목</td>
<td><input type=text class='ed w99' name=ma_subject value='<?=$ma[ma_subject]?>' required itemname='메일 제목'></td>
</tr>
<tr>
<td>메일 내용</td>
<td class=lh>
<?=cheditor2('ma_content', $ma[ma_content]);?>
<br>{이름} , {별명} , {회원아이디} , {이메일} , {생일}
<br>위와 같이 HTML 코드에 삽입하면 해당 내용에 맞게 변환하여 메일 발송합니다.
</td>
</tr>
<tr><td colspan=2 class='line1'></td></tr>
</table>
<p align=center>
<input type=submit class=btn1 accesskey='s' value=' 확 인 '>
</form>
<input type=submit class=btn1 accesskey='s' value=' 확 인 '>
</form>
<script type="text/javascript">
function fmailform_check(f)
{
errmsg = "";
errfld = "";
function fmailform_check(f)
{
errmsg = "";
errfld = "";
<?=cheditor3('ma_content');?>
check_field(f.ma_subject, "제목을 입력하세요.");
check_field(f.ma_content, "내용을 입력하세요.");
check_field(f.ma_content, "내용을 입력하세요.");
if (errmsg != "") {
alert(errmsg);
errfld.focus();
return false;
}
return true;
}
alert(errmsg);
errfld.focus();
return false;
}
return true;
}
document.fmailform.ma_subject.focus();
</script>
</script>
<?
include_once("./admin.tail.php");
?>
include_once("./admin.tail.php");
?>
추천
6
6
댓글 9개
적용완료! 감사합니다.
좋아요~ㅋ
적용하기 참 쉽네요!
감사합니다.^^
게시판에도 응용해 봐야겠네요~~~
감사합니다.^^
게시판에도 응용해 봐야겠네요~~~
너무 좋습니다.
단조로웠는데 말입니다...
감사히 사용하겠습니다.
단조로웠는데 말입니다...
감사히 사용하겠습니다.
Hi. This is the qmail-send program at uwa64-053.cafe24.com.
I'm afraid I wasn't able to deliver your message to the following addresses.
This is a permanent error; I've given up. Sorry it didn't work out.
:
Connected to 117.53.114.15 but sender was rejected.
Remote host said: 550 5.7.1 Access denied by ACL
--- Below this line is a copy of the message.
Return-Path:
Received: (qmail 5390 invoked by uid 1893); 16 Nov 2011 12:42:41 +0900
Date: 16 Nov 2011 12:42:41 +0900
Message-ID: <20111116034241.5387.http://www.paradisefarm.co.kr/adm/mail_select_list.php
Content-Type: TEXT/HTML; charset=UTF-8
Content-Transfer-Encoding: BASE64
무슨메세지인지요?
I'm afraid I wasn't able to deliver your message to the following addresses.
This is a permanent error; I've given up. Sorry it didn't work out.
:
Connected to 117.53.114.15 but sender was rejected.
Remote host said: 550 5.7.1 Access denied by ACL
--- Below this line is a copy of the message.
Return-Path:
Received: (qmail 5390 invoked by uid 1893); 16 Nov 2011 12:42:41 +0900
Date: 16 Nov 2011 12:42:41 +0900
Message-ID: <20111116034241.5387.http://www.paradisefarm.co.kr/adm/mail_select_list.php
Content-Type: TEXT/HTML; charset=UTF-8
Content-Transfer-Encoding: BASE64
무슨메세지인지요?
한참 헤메다 네이버에디터 달았더니 다음날 그냥 활용팁 들어오니 최상단에서 발견한 글이 이글입니다
허허허허허허허허허허허 ㅠㅠ
허허허허허허허허허허허 ㅠㅠ
잘 되는군요 감사합니다
잘되네요 감사감사
보내기에는 이미지가 나오는데 메일 수신에서 확인해보니 이미지가 안나옵니다.