테스트 사이트 - 개발 중인 베타 버전입니다

개인결제시 메일 알림 질문 채택완료

klee 7년 전 조회 2,888

안녕하세요 

개인결제 (personalpay) 에서 상품을 구매할시 관리자에게 오더 알림이 가야하는데 

가지 않고 있습니다. 구입자에게 메일전송은 되고 있으며, 테스트메일 정상적으로 오구 있구요. 

 

일반 상품 구매시에는 관리자, 구입자에게 메일 알림은 가고 있습니다. 

 

ordermail2.inc.php 에서 운영자에게 메일 보내기 코드는 아래와 같습니다. 

개인 결제시 메일알림설정은 어디에서 손봐야하는지 궁금합니다. 

 

</p>

<p><?php

if (!defined("_GNUBOARD_")) exit; // 개별 페이지 접근 불가</p>

<p>include_once(G5_LIB_PATH.'/mailer.lib.php');</p>

<p>//------------------------------------------------------------------------------

// 운영자에게 메일보내기

//------------------------------------------------------------------------------

$subject = $config['cf_title'].' - 주문 알림 메일 ('.$od_name.')';

ob_start();

include G5_SHOP_PATH.'/mail/orderupdate1.mail.php';

$content = ob_get_contents();

ob_end_clean();</p>

<p>mailer($od_name, $od_email, $config['cf_admin_email'], $subject, $content, 1);

mailer($config['cf_admin_email_name'], $config['cf_admin_email'], $config['cf_admin_email'], $subject, $content, 1);</p>

<p>

//------------------------------------------------------------------------------</p>

<p>//------------------------------------------------------------------------------

// 주문자에게 메일보내기

//------------------------------------------------------------------------------

$subject = $config['cf_title'].' - 주문 내역 안내 메일';

ob_start();

include G5_SHOP_PATH.'/mail/orderupdate2.mail.php';

$content = ob_get_contents();

ob_end_clean();</p>

<p>mailer($config['cf_admin_email_name'], $config['cf_admin_email'], $od_email, $subject, $content, 1);

//------------------------------------------------------------------------------</p>

<p>

//------------------------------------------------------------------------------

// 판매자에게 메일 보내기 (상품별로 보낸다.)

//------------------------------------------------------------------------------</p>

<p>unset($list);

$sql = " select b.it_sell_email,

                a.it_id,

                a.it_name

           from {$g5['g5_shop_cart_table']} a left join {$g5['g5_shop_item_table']} b on ( a.it_id = b.it_id )

          where a.od_id = '$od_id'

            and a.ct_select = '1'

            and b.it_sell_email <> ''

          group by a.it_id ";

$result = sql_query($sql);

for ($i=0; $row=sql_fetch_array($result); $i++)

{

    // 합계금액 계산

    $sql = " select SUM(IF(io_type = 1, (io_price * ct_qty), ((ct_price + io_price) * ct_qty))) as price,

                    SUM(ct_point * ct_qty) as point,

                    SUM(ct_qty) as qty

                from {$g5['g5_shop_cart_table']}

                where it_id = '{$row['it_id']}'

                  and od_id = '$od_id'

                  and ct_select = '1' ";

    $sum = sql_fetch($sql);</p>

<p>    // 옵션정보

    $sql2 = " select ct_option, ct_qty, io_price

                from {$g5['g5_shop_cart_table']}

                where it_id = '{$row['it_id']}' and od_id = '$od_id' and ct_select = '1'

                order by io_type asc, ct_id asc ";

    $result2 = sql_query($sql2);</p>

<p>    $options = '';

    $options_ul = ' style="margin:0;padding:0"'; // ul style

    $options_li = ' style="padding:5px 0;list-style:none"'; // li style

    for($k=0; $row2=sql_fetch_array($result2); $k++) {

        if($k == 0)

            $options .= '<ul'.$options_ul.'>'.PHP_EOL;

        $price_plus = '';

        if($row2['io_price'] >= 0)

            $price_plus = '+';

        $options .= '<li'.$options_li.'>'.$row2['ct_option'].' ('.$price_plus.display_price($row2['io_price']).') '.$row2['ct_qty'].'개</li>'.PHP_EOL;

    }</p>

<p>    if($k > 0)

        $options .= '</ul>';</p>

<p>    $list[$i]['it_id']   = $row['it_id'];

    $list[$i]['it_simg'] = get_it_image($row['it_id'], 70, 70);

    $list[$i]['it_name'] = $row['it_name'];

    $list[$i]['it_opt']  = $options;

    $list[$i]['ct_price'] = $sum['price'];</p>

<p>    $subject = $config['cf_title'].' - 주문 알림 메일 (주문자 '.$od_name.'님)';

    ob_start();

    include G5_SHOP_PATH.'/mail/orderupdate3.mail.php';

    $content = ob_get_contents();

    ob_end_clean();</p>

<p>    mailer($config['cf_admin_email_name'], $config['cf_admin_email'],  $row['it_sell_email'], $subject, $content, 1);

}

//==============================================================================

?></p>

<p>
 

댓글을 작성하려면 로그인이 필요합니다.

답변 1개

채택된 답변
+20 포인트
7년 전

개인결제업데이트 페이지에는 알림 코드가 없기 때문에 기존결제업데이트 페이지를 참고하여 알림 코드를 추가해주셔야 합니다.

로그인 후 평가할 수 있습니다

댓글을 작성하려면 로그인이 필요합니다.

답변을 작성하려면 로그인이 필요합니다.

로그인