글 조회시 차감되는 포인트 글 작성자에게 되돌려주기 질문... 채택완료
안녕하세요.
링크1의 팁을 참고하였습니다.
// 글읽기 포인트가 설정되어 있다면 if ($config['cf_use_point'] && $board['bo_read_point'] && $member['mb_point'] + $board['bo_read_point'] < 0) alert('보유하신 포인트('.number_format($member['mb_point']).')가 없거나 모자라서 글읽기('.number_format($board['bo_read_point']).')가 불가합니다.\\n\\n포인트를 모으신 후 다시 글읽기 해 주십시오.'); insert_point($member['mb_id'], $board['bo_read_point'], ((G5_IS_MOBILE && $board['bo_mobile_subject']) ? $board['bo_mobile_subject'] : $board['bo_subject']).' '.$wr_id.' 글읽기', $bo_table, $wr_id, '읽기'); if($bo_table == "게시판ID") { insert_point($write['mb_id'], $board['bo_read_point']*-1, ((G5_IS_MOBILE && $board['bo_mobile_subject']) ? $board['bo_mobile_subject'] : $board['bo_subject']).' '.$wr_id.' 글 수익 포인트', $bo_table, $wr_id, '수익'); }
특정게시판에만 적용시키고 싶은데 위 처럼 적용하니 사이트 게시판 전체가 에러떠버립니다.
재야의 고수님들께 도움을 청합니다.
답변 2개
답변에 대한 댓글 1개
댓글을 작성하려면 로그인이 필요합니다.
if($bo_table == "게시판ID") { insert_point($write['mb_id'], $board['bo_read_point']*-1, ((G5_IS_MOBILE && $board['bo_mobile_subject']) ? $board['bo_mobile_subject'] : $board['bo_subject']).' '.$wr_id.' 글 수익 포인트', $bo_table, $wr_id, '수익'); }
위에 게시판ID 이라고 되어 있는 부분에 해당 적용 시킬 게시판 아이디를 넣어주셔야 됩니다.
답변에 대한 댓글 1개
댓글을 작성하려면 로그인이 필요합니다.
답변을 작성하려면 로그인이 필요합니다.
로그인
그누 알림 보고 자다가 바로 컴앞에 앉았네요.
if($bo_table == "board_1") {
insert_point($write['mb_id'], $board['bo_read_point']* (-1), ((G5_IS_MOBILE && $board['bo_mobile_subject']) ? $board['bo_mobile_subject'] : $board['bo_subject']).' '.$wr_id.' 글 수익 포인트', $bo_table, $wr_id, '수익');
알려주신대로 수정을 했지만 모든 게시판 에러표시가 나더라고요. 혹시나 해서
$bo_table, $wr_id, '수익'); 다음에 } 항목을 추가하니 에러는 안나는데 글 작성자 포인트 적립은 되질 않았습니다.
늦은시간에 도움주셔서 감사합니다.
참고로 그누 기본 빌더가 아닌 나리야 테마빌더를 사용하고 있습니다.
꼭 해결해보고싶네요~