글등록시 포인트 차감에 관하여~~

안녕하세요.
특정한 게시판에서 글등록시 포인트 차감을 하고싶어요..
고수님들 답변 부탁합니다..그럼..좋은 하루~~
|

댓글 2개

http://www.sir.co.kr/?doc=bbs/gnuboard.php&bo_table=tiptech&sselect=concat%28wr_subject%2Cwr_content%29&stext=%C6%AF%C1%A4+%C6%F7%C0%CE%C5%CD&soperator=1&page=1&wr_id=2627

약간 응용해 보셔도 됩니다.
$diff_point = -1; 한줄 추가 하면 될듯...

if ($w == '') {
$wr_num = get_next_num($write_table, $wr_notice);

$sql = " insert into $write_table
set ca_id = '$ca_id',
wr_notice = '$wr_notice',
wr_html = '$wr_html',
wr_secret = '$wr_secret',
wr_recv_email = '$wr_recv_email',
wr_num = '$wr_num',
wr_reply = '',
wr_comment = '0',
wr_commentcnt = '0',
wr_subject = '$wr_subject',
wr_content = '$wr_content',
wr_link1 = '$wr_link1',
wr_link2 = '$wr_link2',
wr_file1 = '$upload[1]',
wr_file2 = '$upload[2]',
wr_file1_source = '$upload_source[1]',
wr_file2_source = '$upload_source[2]',
wr_file1_download = '0',
wr_file2_download = '0',
wr_hit = '0',
mb_id = '$mb_id',
wr_name = '$wr_name',
wr_passwd = '$wr_passwd',
wr_email = '$wr_email',
wr_homepage = '$wr_homepage',
wr_datetime = '$now',
wr_ip = '$_SERVER[REMOTE_ADDR]',
wr_user_agent = '$_SERVER[HTTP_USER_AGENT]'
$sql_add ";
sql_query($sql);

$wr_id = mysql_insert_id();

sql_query(" update $write_table set wr_parent_id = '$wr_id' where wr_id = '$wr_id' ");

// 게시글 1 증가
sql_query("update $cfg[table_board] set bo_total_count = bo_total_count + 1 where bo_table = '$bo_table'");

$diff_point = -1; //요기에 한줄 추가 하면 될듯...
}
댓글을 작성하시려면 로그인이 필요합니다. 로그인

그누3질답

+
제목 글쓴이 날짜 조회
21년 전 조회 423
21년 전 조회 469
21년 전 조회 367
21년 전 조회 484
21년 전 조회 720
21년 전 조회 638
&  
21년 전 조회 1,008
21년 전 조회 358
21년 전 조회 301
21년 전 조회 440
21년 전 조회 880
21년 전 조회 354
21년 전 조회 492
21년 전 조회 526
21년 전 조회 628
21년 전 조회 403
21년 전 조회 382
21년 전 조회 507
21년 전 조회 490
21년 전 조회 458
🐛 버그신고