Fix: include error
This commit is contained in:
@@ -6,7 +6,7 @@ include "./../lib/send_reply_json.php";
|
|||||||
include "./../lib/db_maestro.php";
|
include "./../lib/db_maestro.php";
|
||||||
include "./../lib/maestro_log.php";
|
include "./../lib/maestro_log.php";
|
||||||
include "./../lib/maestro_account_info.php";
|
include "./../lib/maestro_account_info.php";
|
||||||
include "./../mail/mail_setting.php";
|
// include "./../mail/mail_setting.php";
|
||||||
// include "./../mail/send_mail.php";
|
// include "./../mail/send_mail.php";
|
||||||
include "./../mail/send_naver_mail.php";
|
include "./../mail/send_naver_mail.php";
|
||||||
|
|
||||||
|
|||||||
@@ -6,7 +6,7 @@ include "./../setup/connect_db.php";
|
|||||||
include "./../lib/maestro_account_info.php";
|
include "./../lib/maestro_account_info.php";
|
||||||
include "./../lib/db_maestro.php";
|
include "./../lib/db_maestro.php";
|
||||||
include "./../lib/maestro_log.php";
|
include "./../lib/maestro_log.php";
|
||||||
include "./../mail/mail_setting.php";
|
// include "./../mail/mail_setting.php";
|
||||||
// include "./../mail/send_mail.php";
|
// include "./../mail/send_mail.php";
|
||||||
include "./../mail/send_naver_mail.php";
|
include "./../mail/send_naver_mail.php";
|
||||||
|
|
||||||
|
|||||||
@@ -1,12 +1,15 @@
|
|||||||
<?php
|
<?php
|
||||||
header("Content-Type: application/json");
|
header("Content-Type: application/json");
|
||||||
|
|
||||||
|
error_reporting( E_ALL );
|
||||||
|
ini_set( "display_errors", 1 );
|
||||||
|
|
||||||
include "./../setup/connect_db.php";
|
include "./../setup/connect_db.php";
|
||||||
include "./../lib/send_reply_json.php";
|
include "./../lib/send_reply_json.php";
|
||||||
include "./../lib/maestro_account_info.php";
|
// include "./../lib/maestro_account_info.php";
|
||||||
include "./../lib/db_maestro.php";
|
include "./../lib/db_maestro.php";
|
||||||
include "./../lib/maestro_log.php";
|
include "./../lib/maestro_log.php";
|
||||||
include "./../mail/mail_setting.php";
|
// include "./../mail/mail_setting.php";
|
||||||
include "./../mail/send_naver_mail.php";
|
include "./../mail/send_naver_mail.php";
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -5,7 +5,7 @@ include "./../setup/connect_db.php";
|
|||||||
include "./../lib/send_reply_json.php";
|
include "./../lib/send_reply_json.php";
|
||||||
include "./../lib/db_maestro.php";
|
include "./../lib/db_maestro.php";
|
||||||
include "./../lib/maestro_account_info.php";
|
include "./../lib/maestro_account_info.php";
|
||||||
include "./../mail/mail_setting.php";
|
// include "./../mail/mail_setting.php";
|
||||||
// include "./../mail/send_mail.php";
|
// include "./../mail/send_mail.php";
|
||||||
include "./../mail/send_naver_mail.php";
|
include "./../mail/send_naver_mail.php";
|
||||||
|
|
||||||
|
|||||||
@@ -5,7 +5,7 @@ include "./../setup/connect_db.php";
|
|||||||
include "./../lib/send_reply_json.php";
|
include "./../lib/send_reply_json.php";
|
||||||
include "./../lib/db_maestro.php";
|
include "./../lib/db_maestro.php";
|
||||||
include "./../lib/maestro_account_info.php";
|
include "./../lib/maestro_account_info.php";
|
||||||
include "./../mail/mail_setting.php";
|
// include "./../mail/mail_setting.php";
|
||||||
// include "./../mail/send_mail.php";
|
// include "./../mail/send_mail.php";
|
||||||
include "./../mail/send_naver_mail.php";
|
include "./../mail/send_naver_mail.php";
|
||||||
|
|
||||||
|
|||||||
@@ -6,7 +6,7 @@ include "./../setup/connect_db.php";
|
|||||||
include "./../lib/maestro_account_info.php";
|
include "./../lib/maestro_account_info.php";
|
||||||
include "./../lib/db_maestro.php";
|
include "./../lib/db_maestro.php";
|
||||||
include "./../lib/maestro_log.php";
|
include "./../lib/maestro_log.php";
|
||||||
include "./../mail/mail_setting.php";
|
// include "./../mail/mail_setting.php";
|
||||||
// include "./../mail/send_mail.php";
|
// include "./../mail/send_mail.php";
|
||||||
include "./../mail/send_naver_mail.php";
|
include "./../mail/send_naver_mail.php";
|
||||||
|
|
||||||
|
|||||||
@@ -9,12 +9,12 @@ $bodyMap['registrationBankInfo'] = "안녕하세요.<br/>".
|
|||||||
"<br/>".
|
"<br/>".
|
||||||
"신청하신 마에스트로 계정 내용은 아래와 같습니다.<br/>".
|
"신청하신 마에스트로 계정 내용은 아래와 같습니다.<br/>".
|
||||||
"1) 아이디 : {{maestro_name}}<br/>".
|
"1) 아이디 : {{maestro_name}}<br/>".
|
||||||
"2) 요금제 : {{student_count}}명 ({{price}}만원)<br/>".
|
"2) 요금제 : {{student_count}}명 ({{price}}원)<br/>".
|
||||||
"<br/>".
|
"<br/>".
|
||||||
"계정 등록을 위한 은행 계좌 입금 정보는 아래와 같습니다.<br/>".
|
"계정 등록을 위한 은행 계좌 입금 정보는 아래와 같습니다.<br/>".
|
||||||
"------------------------------------------------------------<br/>".
|
"------------------------------------------------------------<br/>".
|
||||||
"* 은행 계좌 : {{bank_account_no}} ( 카카오뱅크, 예금주 : 박지상 )<br/>".
|
"* 은행 계좌 : {{bank_account_no}} ( 카카오뱅크, 예금주 : 박지상 )<br/>".
|
||||||
"* 금액 : {{price}}만원<br/>".
|
"* 금액 : {{price}}원<br/>".
|
||||||
"* 송금자명 : {{maestro_name}} (신청하신 마에스트로 아이디)<br/>".
|
"* 송금자명 : {{maestro_name}} (신청하신 마에스트로 아이디)<br/>".
|
||||||
" ☞ 빠른 입금 확인을 위해, 송금자명을 본인 이름 대신 위와 같이 아이디로 부탁드립니다 ☜<br/>".
|
" ☞ 빠른 입금 확인을 위해, 송금자명을 본인 이름 대신 위와 같이 아이디로 부탁드립니다 ☜<br/>".
|
||||||
"------------------------------------------------------------<br/>".
|
"------------------------------------------------------------<br/>".
|
||||||
@@ -75,7 +75,7 @@ $bodyMap['closedBetaRegistrationBankInfo'] = "안녕하세요.<br/>".
|
|||||||
"<br/>".
|
"<br/>".
|
||||||
"신청하신 마에스트로 계정 내용은 아래와 같습니다.<br/>".
|
"신청하신 마에스트로 계정 내용은 아래와 같습니다.<br/>".
|
||||||
"1) 아이디 : {{maestro_name}}<br/>".
|
"1) 아이디 : {{maestro_name}}<br/>".
|
||||||
"2) 요금제 : {{student_count}}명 ({{price}}만원)<br/>".
|
"2) 요금제 : {{student_count}}명 ({{price}}원)<br/>".
|
||||||
"<br/>".
|
"<br/>".
|
||||||
"계정 신청 내역이 확인되는대로 마에스트로 아이디를 활성화 해드리겠습니다.<br/>".
|
"계정 신청 내역이 확인되는대로 마에스트로 아이디를 활성화 해드리겠습니다.<br/>".
|
||||||
"현재 수작업으로 확인하고 활성화하고 있어서 시간이 조금 걸리는 점 양해 부탁드립니다.<br/>".
|
"현재 수작업으로 확인하고 활성화하고 있어서 시간이 조금 걸리는 점 양해 부탁드립니다.<br/>".
|
||||||
@@ -108,7 +108,7 @@ $bodyMap['extensionBankInfo'] = "안녕하세요.<br/>".
|
|||||||
"[초코마에] 마에스트로 계정 유효기간 연장을 신청해주셔서 감사합니다.<br/>".
|
"[초코마에] 마에스트로 계정 유효기간 연장을 신청해주셔서 감사합니다.<br/>".
|
||||||
"<br/>".
|
"<br/>".
|
||||||
"{{maestro_name}} - 마에스트로 계정의 현재 요금제와 유효기간은 아래와 같습니다.<br/>".
|
"{{maestro_name}} - 마에스트로 계정의 현재 요금제와 유효기간은 아래와 같습니다.<br/>".
|
||||||
"1) 현재 사용중인 요금제 : {{student_count}}명 ({{price}}만원)<br/>".
|
"1) 현재 사용중인 요금제 : {{student_count}}명 ({{price}}원)<br/>".
|
||||||
"2) 유효기간 : {{date}}<br/>".
|
"2) 유효기간 : {{date}}<br/>".
|
||||||
"<br/>".
|
"<br/>".
|
||||||
"연장을 신청하실 경우, 새로운 유효기간은 아래와 같습니다.<br/>".
|
"연장을 신청하실 경우, 새로운 유효기간은 아래와 같습니다.<br/>".
|
||||||
@@ -117,7 +117,7 @@ $bodyMap['extensionBankInfo'] = "안녕하세요.<br/>".
|
|||||||
"계정 유효기간 연장을 위한 은행 계좌 입금 정보는 아래와 같습니다.<br/>".
|
"계정 유효기간 연장을 위한 은행 계좌 입금 정보는 아래와 같습니다.<br/>".
|
||||||
"------------------------------------------------------------<br/>".
|
"------------------------------------------------------------<br/>".
|
||||||
"* 은행 계좌 : {{bank_account_no}} ( 카카오뱅크, 예금주 : 박지상 )<br/>".
|
"* 은행 계좌 : {{bank_account_no}} ( 카카오뱅크, 예금주 : 박지상 )<br/>".
|
||||||
"* 금액 : {{price}}만원<br/>".
|
"* 금액 : {{price}}원<br/>".
|
||||||
"* 송금자명 : {{maestro_name}} (신청하신 마에스트로 아이디)<br/>".
|
"* 송금자명 : {{maestro_name}} (신청하신 마에스트로 아이디)<br/>".
|
||||||
" ☞ 빠른 입금 확인을 위해, 송금자명을 본인 이름 대신 위와 같이 아이디로 부탁드립니다 ☜<br/>".
|
" ☞ 빠른 입금 확인을 위해, 송금자명을 본인 이름 대신 위와 같이 아이디로 부탁드립니다 ☜<br/>".
|
||||||
"------------------------------------------------------------<br/>".
|
"------------------------------------------------------------<br/>".
|
||||||
@@ -152,14 +152,14 @@ $bodyMap['upgradeBankInfo'] = "안녕하세요.<br/>".
|
|||||||
"[초코마에] 마에스트로 계정 요금제 업그레이드를 신청해주셔서 감사합니다.<br/>".
|
"[초코마에] 마에스트로 계정 요금제 업그레이드를 신청해주셔서 감사합니다.<br/>".
|
||||||
"<br/>".
|
"<br/>".
|
||||||
"{{maestro_name}} - 마에스트로 계정의 현재 요금제와 업그레이드 요금제는 아래와 같습니다.<br/>".
|
"{{maestro_name}} - 마에스트로 계정의 현재 요금제와 업그레이드 요금제는 아래와 같습니다.<br/>".
|
||||||
"1) 현재 사용중인 요금제 : {{prev_student_count}}명 ({{prev_price}}만원)<br/>".
|
"1) 현재 사용중인 요금제 : {{prev_student_count}}명 ({{prev_price}}원)<br/>".
|
||||||
"2) 신청하신 업그레이드 요금제 : {{upgrade_student_count}}명 ({{upgrade_price}}만원)<br/>".
|
"2) 신청하신 업그레이드 요금제 : {{upgrade_student_count}}명 ({{upgrade_price}}원)<br/>".
|
||||||
"<br/>".
|
"<br/>".
|
||||||
"<br/>".
|
"<br/>".
|
||||||
"계정 요금제 업그레이드를 위한 은행 계좌 입금 정보는 아래와 같습니다.<br/>".
|
"계정 요금제 업그레이드를 위한 은행 계좌 입금 정보는 아래와 같습니다.<br/>".
|
||||||
"------------------------------------------------------------<br/>".
|
"------------------------------------------------------------<br/>".
|
||||||
"* 은행 계좌 : {{bank_account_no}} ( 카카오뱅크, 예금주 : 박지상 )<br/>".
|
"* 은행 계좌 : {{bank_account_no}} ( 카카오뱅크, 예금주 : 박지상 )<br/>".
|
||||||
"* 금액 : {{price}}만원<br/>".
|
"* 금액 : {{price}}원<br/>".
|
||||||
"* 송금자명 : {{maestro_name}} (신청하신 마에스트로 아이디)<br/>".
|
"* 송금자명 : {{maestro_name}} (신청하신 마에스트로 아이디)<br/>".
|
||||||
" ☞ 빠른 입금 확인을 위해, 송금자명을 본인 이름 대신 위와 같이 아이디로 부탁드립니다 ☜<br/>".
|
" ☞ 빠른 입금 확인을 위해, 송금자명을 본인 이름 대신 위와 같이 아이디로 부탁드립니다 ☜<br/>".
|
||||||
"------------------------------------------------------------<br/>".
|
"------------------------------------------------------------<br/>".
|
||||||
@@ -180,7 +180,7 @@ $subjectMap['upgradeDone'] = "[초코마에] {{maestro_name}} - 마에스트로
|
|||||||
$bodyMap['upgradeDone'] = "안녕하세요.<br/>".
|
$bodyMap['upgradeDone'] = "안녕하세요.<br/>".
|
||||||
"[초코마에] 마에스트로 계정 요금제 업그레이드를 신청해주셔서 감사합니다.<br/>".
|
"[초코마에] 마에스트로 계정 요금제 업그레이드를 신청해주셔서 감사합니다.<br/>".
|
||||||
"<br/>".
|
"<br/>".
|
||||||
"{{maestro_name}} - 마에스트로 계정의 요금제가 [ 50명 (2만원) ] 에서 [ 500명 (4만원) ] 로 업그레이드 되었습니다.<br/>".
|
"{{maestro_name}} - 마에스트로 계정의 요금제가 [ 50명 ({{prev_price}}원) ] 에서 [ 500명 ({{price}}원) ] 으로 업그레이드 되었습니다.<br/>".
|
||||||
"<br/>".
|
"<br/>".
|
||||||
"* 마에스트로 계정 유효기간이 오늘부터 1년으로 다시 채워졌습니다.<br/>".
|
"* 마에스트로 계정 유효기간이 오늘부터 1년으로 다시 채워졌습니다.<br/>".
|
||||||
"<br/>".
|
"<br/>".
|
||||||
|
|||||||
@@ -1,15 +1,13 @@
|
|||||||
<?php
|
<?php
|
||||||
header("Content-Type: application/json");
|
header("Content-Type: application/json");
|
||||||
|
|
||||||
include "./../setup/connect_db.php";
|
|
||||||
include "./../lib/send_reply_json.php";
|
include "./../lib/send_reply_json.php";
|
||||||
include "./../lib/maestro_account_info.php";
|
include "./../setup/connect_db.php";
|
||||||
include "./../lib/db_maestro.php";
|
include "./../lib/db_maestro.php";
|
||||||
include "./mail_setting.php";
|
// include "./mail_setting.php";
|
||||||
// include "./send_mail.php";
|
// include "./send_mail.php";
|
||||||
include "./send_naver_mail.php";
|
include "./send_naver_mail.php";
|
||||||
|
|
||||||
/*
|
|
||||||
$type = $_POST["type"];
|
$type = $_POST["type"];
|
||||||
$maestro_id = $_POST["maestro_id"];
|
$maestro_id = $_POST["maestro_id"];
|
||||||
$maestro_name = $_POST["maestro_name"];
|
$maestro_name = $_POST["maestro_name"];
|
||||||
@@ -22,9 +20,7 @@ $upgrade_account_type = $_POST["upgrade_account_type"];
|
|||||||
$registered_account_type = $_POST["registered_account_type"];
|
$registered_account_type = $_POST["registered_account_type"];
|
||||||
$maestro_name_prev = $_POST["maestro_name_prev"];
|
$maestro_name_prev = $_POST["maestro_name_prev"];
|
||||||
$maestro_email_prev = $_POST["email_prev"];
|
$maestro_email_prev = $_POST["email_prev"];
|
||||||
*/
|
|
||||||
|
|
||||||
/*
|
|
||||||
if($type == "sendMailRegisterBankInfo") {
|
if($type == "sendMailRegisterBankInfo") {
|
||||||
$result = sendMailRegisterBankInfo($maestro_name, $maestro_email, $account_type);
|
$result = sendMailRegisterBankInfo($maestro_name, $maestro_email, $account_type);
|
||||||
} else if($type == "sendMailRegistered") {
|
} else if($type == "sendMailRegistered") {
|
||||||
@@ -46,10 +42,8 @@ if($type == "sendMailRegisterBankInfo") {
|
|||||||
$maestro_data = get_maestro_data($maestro_id);
|
$maestro_data = get_maestro_data($maestro_id);
|
||||||
set_data("maestroData", $maestro_data);
|
set_data("maestroData", $maestro_data);
|
||||||
}
|
}
|
||||||
*/
|
|
||||||
|
|
||||||
$return = true;
|
set_data("sendMailResult", $result);
|
||||||
set_data("sendMailResult", $return);
|
|
||||||
send_result_success();
|
send_result_success();
|
||||||
|
|
||||||
exit;
|
exit;
|
||||||
|
|||||||
@@ -1,49 +1,45 @@
|
|||||||
<?php
|
<?php
|
||||||
header("Content-Type: application/json");
|
header("Content-Type: application/json");
|
||||||
|
|
||||||
|
error_reporting( E_ALL );
|
||||||
|
ini_set( "display_errors", 1 );
|
||||||
|
|
||||||
use PHPMailer\PHPMailer\PHPMailer;
|
use PHPMailer\PHPMailer\PHPMailer;
|
||||||
use PHPMailer\PHPMailer\Exception;
|
use PHPMailer\PHPMailer\Exception;
|
||||||
|
|
||||||
require './../PHPMailer/src/Exception.php';
|
require './../PHPMailer/src/Exception.php';
|
||||||
require './../PHPMailer/src/PHPMailer.php';
|
require './../PHPMailer/src/PHPMailer.php';
|
||||||
require './../PHPMailer/src/SMTP.php';
|
require './../PHPMailer/src/SMTP.php';
|
||||||
require './mail_contents.php';
|
|
||||||
require './../lib/maestro_account_info.php';
|
|
||||||
|
|
||||||
|
include './mail_setting.php';
|
||||||
|
include './mail_contents.php';
|
||||||
|
include './../lib/maestro_account_info.php';
|
||||||
|
// include_once "./../lib/send_reply_json.php";
|
||||||
|
|
||||||
// Register
|
// Register
|
||||||
function sendMailRegisterBankInfo($maestro_name, $maestro_email, $account_type) {
|
function sendMailRegisterBankInfo($maestro_name, $maestro_email, $account_type) {
|
||||||
global $subjectMap, $bodyMap;
|
global $subjectMap, $bodyMap;
|
||||||
|
|
||||||
// closed beta
|
// closed beta
|
||||||
/*
|
|
||||||
$subject = str_replace("{{maestro_name}}", $maestro_name, $subjectMap['closedBetaRegistrationBankInfo']);
|
$subject = str_replace("{{maestro_name}}", $maestro_name, $subjectMap['closedBetaRegistrationBankInfo']);
|
||||||
|
|
||||||
$body = str_replace("{{maestro_name}}", $maestro_name, $bodyMap['closedBetaRegistrationBankInfo']);
|
$body = str_replace("{{maestro_name}}", $maestro_name, $bodyMap['closedBetaRegistrationBankInfo']);
|
||||||
$body = str_replace("{{student_count}}", get_max_player_count($account_type), $body);
|
$body = str_replace("{{student_count}}", get_max_player_count($account_type), $body);
|
||||||
$body = str_replace("{{price}}", get_price($account_type), $body);
|
$price = number_format(get_price($account_type));
|
||||||
*/
|
$body = str_replace("{{price}}", $price, $body);
|
||||||
|
|
||||||
$subject = "Naver 메일 발신 테스트";
|
return send_naver_mail($maestro_email, $maestro_name, $subject, $body);
|
||||||
$body = "sendMailRegisterBankInfo";
|
|
||||||
|
|
||||||
send_naver_mail($maestro_email, $maestro_name, $subject, $body);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
function sendMailRegisterDone($maestro_name, $maestro_email) {
|
function sendMailRegisterDone($maestro_name, $maestro_email) {
|
||||||
global $subjectMap, $bodyMap;
|
global $subjectMap, $bodyMap;
|
||||||
|
|
||||||
// closed beta
|
// closed beta
|
||||||
/*
|
|
||||||
$subject = str_replace("{{maestro_name}}", $maestro_name, $subjectMap['closedBetaRegistrationDone']);
|
$subject = str_replace("{{maestro_name}}", $maestro_name, $subjectMap['closedBetaRegistrationDone']);
|
||||||
|
|
||||||
$body = str_replace("{{maestro_name}}", $maestro_name, $bodyMap['closedBetaRegistrationDone']);
|
$body = str_replace("{{maestro_name}}", $maestro_name, $bodyMap['closedBetaRegistrationDone']);
|
||||||
*/
|
|
||||||
|
|
||||||
$subject = "Naver 메일 발신 테스트";
|
return send_naver_mail($maestro_email, $maestro_name, $subject, $body);
|
||||||
$body = "sendMailRegisterDone";
|
|
||||||
|
|
||||||
send_naver_mail($maestro_email, $maestro_name, $subject, $body);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@@ -52,14 +48,14 @@ function sendMailExtensionBankInfo($maestro_name, $available_date, $new_availabl
|
|||||||
$subject = "Naver 메일 발신 테스트";
|
$subject = "Naver 메일 발신 테스트";
|
||||||
$body = "sendMailExtensionBankInfo";
|
$body = "sendMailExtensionBankInfo";
|
||||||
|
|
||||||
send_naver_mail($maestro_email, $maestro_name, $subject, $body);
|
return send_naver_mail($maestro_email, $maestro_name, $subject, $body);
|
||||||
}
|
}
|
||||||
|
|
||||||
function sendMailExtensionDone($maestro_name, $new_available_date, $maestro_email) {
|
function sendMailExtensionDone($maestro_name, $new_available_date, $maestro_email) {
|
||||||
$subject = "Naver 메일 발신 테스트";
|
$subject = "Naver 메일 발신 테스트";
|
||||||
$body = "sendMailExtensionDone";
|
$body = "sendMailExtensionDone";
|
||||||
|
|
||||||
send_naver_mail($maestro_email, $maestro_name, $subject, $body);
|
return send_naver_mail($maestro_email, $maestro_name, $subject, $body);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@@ -68,30 +64,38 @@ function sendMailUpgradeBankInfo($maestro_name, $maestro_email, $account_type, $
|
|||||||
$subject = "Naver 메일 발신 테스트";
|
$subject = "Naver 메일 발신 테스트";
|
||||||
$body = "sendMailUpgradeBankInfo";
|
$body = "sendMailUpgradeBankInfo";
|
||||||
|
|
||||||
send_naver_mail($maestro_email, $maestro_name, $subject, $body);
|
return send_naver_mail($maestro_email, $maestro_name, $subject, $body);
|
||||||
}
|
}
|
||||||
|
|
||||||
function sendMailUpgradeDone($maestro_name, $maestro_email, $account_type, $upgrade_account_type) {
|
function sendMailUpgradeDone($maestro_name, $maestro_email, $account_type, $upgrade_account_type) {
|
||||||
$subject = "Naver 메일 발신 테스트";
|
$subject = "Naver 메일 발신 테스트";
|
||||||
$body = "sendMailUpgradeDone";
|
$body = "sendMailUpgradeDone";
|
||||||
|
|
||||||
send_naver_mail($maestro_email, $maestro_name, $subject, $body);
|
return send_naver_mail($maestro_email, $maestro_name, $subject, $body);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
// Update
|
// Update
|
||||||
function sendMailUpdateMaestroName($maestro_name, $maestro_name_prev, $maestro_email) {
|
function sendMailUpdateMaestroName($maestro_name, $maestro_name_prev, $maestro_email) {
|
||||||
$subject = "Naver 메일 발신 테스트";
|
global $subjectMap, $bodyMap;
|
||||||
$body = "sendMailUpdateMaestroName";
|
|
||||||
|
|
||||||
send_naver_mail($maestro_email, $maestro_name, $subject, $body);
|
$subject = str_replace("{{update_maestro_name}}", $maestro_name, $subjectMap['updateMaestroName']);
|
||||||
|
|
||||||
|
$body = str_replace("{{prev_maestro_name}}", $maestro_name_prev, $bodyMap['updateMaestroName']);
|
||||||
|
$body = str_replace("{{update_maestro_name}}", $maestro_name, $body);
|
||||||
|
|
||||||
|
return send_naver_mail($maestro_email, $maestro_name, $subject, $body);
|
||||||
}
|
}
|
||||||
|
|
||||||
function sendMailUpdateMaestroEmail($maestro_name, $maestro_email, $maestro_email_prev) {
|
function sendMailUpdateMaestroEmail($maestro_name, $maestro_email, $maestro_email_prev) {
|
||||||
$subject = "Naver 메일 발신 테스트";
|
global $subjectMap, $bodyMap;
|
||||||
$body = "sendMailUpdateMaestroEmail";
|
|
||||||
|
|
||||||
send_naver_mail($maestro_email, $maestro_name, $subject, $body);
|
$subject = $subjectMap['updateMaestroEmail'];
|
||||||
|
|
||||||
|
$body = str_replace("{{prev_email}}", $maestro_email_prev, $bodyMap['updateMaestroEmail']);
|
||||||
|
$body = str_replace("{{update_email}}", $maestro_email, $body);
|
||||||
|
|
||||||
|
return send_naver_mail($maestro_email, $maestro_name, $subject, $body);
|
||||||
}
|
}
|
||||||
|
|
||||||
// experation
|
// experation
|
||||||
@@ -99,10 +103,9 @@ function sendMailExperation30days($maestro_name, $maestro_email, $maestro_email_
|
|||||||
$subject = "Naver 메일 발신 테스트";
|
$subject = "Naver 메일 발신 테스트";
|
||||||
$body = "sendMailExperation30days";
|
$body = "sendMailExperation30days";
|
||||||
|
|
||||||
send_naver_mail($maestro_email, $maestro_name, $subject, $body);
|
return send_naver_mail($maestro_email, $maestro_name, $subject, $body);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
// Load Composer's autoloader
|
// Load Composer's autoloader
|
||||||
// require $_SERVER['DOCUMENT_ROOT'] . '/vendor/autoload.php';
|
// require $_SERVER['DOCUMENT_ROOT'] . '/vendor/autoload.php';
|
||||||
|
|
||||||
@@ -148,10 +151,15 @@ function send_naver_mail($maestro_email, $maestro_name, $subject, $body) {
|
|||||||
$mail->Body = $body;
|
$mail->Body = $body;
|
||||||
|
|
||||||
$mail->send();
|
$mail->send();
|
||||||
echo 'Message has been sent';
|
|
||||||
|
// set_data("message", "Message has been sent");
|
||||||
|
// send_result_success();
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
} catch (Exception $e) {
|
} catch (Exception $e) {
|
||||||
echo "Message could not be sent. Mailer Error: {$mail->ErrorInfo}";
|
// set_error_code("Message could not be sent. Mailer Error: {".$mail->ErrorInfo."}");
|
||||||
|
// send_result_success();
|
||||||
|
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
Reference in New Issue
Block a user