포인트 정보
포인트본문
댓글 전체
엥 이부부분은 다른분들이 잘할것같은데요..^^
// 쓰기 포인트 부여
조금전 말씀드린 그부분에
if ($bo_table=="포인트게시판코드") {
$board[bo_write_point]= 1000;
$board[bo_comment_point]= 1000;
}
if ($w == '')
{
if ($notice)
{
$bo_notice = $wr_id . "\n" . $board[bo_notice];
sql_query(" update $g4[board_table] set bo_notice = '$bo_notice' where bo_table = '$bo_table' ");
}
insert_point($member[mb_id], $board[bo_write_point], "$board[bo_subject] $wr_id 글쓰기", $bo_table, $wr_id, '쓰기');
}
else
{
// 답변은 코멘트 포인트를 부여함
// 답변 포인트가 많은 경우 코멘트 대신 답변을 하는 경우가 많음
insert_point($member[mb_id], $board[bo_comment_point], "$board[bo_subject] $wr_id 글답변", $bo_table, $wr_id, '쓰기');
}
이 게시판에서 적었다 지웠다하는 불량어린이들을 위해...
delete.php 에도 추가해주세요..
if ($bo_table=="포인트게시판코드") {
$board[bo_write_point]= 1000;
$board[bo_comment_point]= 1000;
}
$sql = " select wr_id, mb_id, wr_is_comment from $write_table where wr_parent = '$write[wr_id]' order by wr_id ";
$result = sql_query($sql);
while ($row = sql_fetch_array($result))
{
// 원글이라면
if (!$row[wr_is_comment])
{
// 원글 포인트 삭제
if (!delete_point($row[mb_id], $bo_table, $row[wr_id], '쓰기'))
insert_point($row[mb_id], $board[bo_write_point] * (-1), "$board[bo_subject] $row[wr_id] 글삭제");
// 업로드된 파일이 있다면 파일삭제
$sql2 = " select * from $g4[board_file_table] where bo_table = '$bo_table' and wr_id = '$row[wr_id]' ";
$result2 = sql_query($sql2);
while ($row2 = sql_fetch_array($result2))
@unlink("$g4[path]/data/file/$bo_table/$row2[bf_file]");
// 파일테이블 행 삭제
sql_query(" delete from $g4[board_file_table] where bo_table = '$bo_table' and wr_id = '$row[wr_id]' ");
$count_write++;
}
else
{
// 코멘트 포인트 삭제
if (!delete_point($row[mb_id], $bo_table, $row[wr_id], '코멘트'))
insert_point($row[mb_id], $board[bo_comment_point] * (-1), "$board[bo_subject] {$write[wr_id]}-{$row[wr_id]} 코멘트삭제");
$count_comment++;
}
}
----------- 아 착한 로빈아빠.. ^^ ---
// 쓰기 포인트 부여
조금전 말씀드린 그부분에
if ($bo_table=="포인트게시판코드") {
$board[bo_write_point]= 1000;
$board[bo_comment_point]= 1000;
}
if ($w == '')
{
if ($notice)
{
$bo_notice = $wr_id . "\n" . $board[bo_notice];
sql_query(" update $g4[board_table] set bo_notice = '$bo_notice' where bo_table = '$bo_table' ");
}
insert_point($member[mb_id], $board[bo_write_point], "$board[bo_subject] $wr_id 글쓰기", $bo_table, $wr_id, '쓰기');
}
else
{
// 답변은 코멘트 포인트를 부여함
// 답변 포인트가 많은 경우 코멘트 대신 답변을 하는 경우가 많음
insert_point($member[mb_id], $board[bo_comment_point], "$board[bo_subject] $wr_id 글답변", $bo_table, $wr_id, '쓰기');
}
이 게시판에서 적었다 지웠다하는 불량어린이들을 위해...
delete.php 에도 추가해주세요..
if ($bo_table=="포인트게시판코드") {
$board[bo_write_point]= 1000;
$board[bo_comment_point]= 1000;
}
$sql = " select wr_id, mb_id, wr_is_comment from $write_table where wr_parent = '$write[wr_id]' order by wr_id ";
$result = sql_query($sql);
while ($row = sql_fetch_array($result))
{
// 원글이라면
if (!$row[wr_is_comment])
{
// 원글 포인트 삭제
if (!delete_point($row[mb_id], $bo_table, $row[wr_id], '쓰기'))
insert_point($row[mb_id], $board[bo_write_point] * (-1), "$board[bo_subject] $row[wr_id] 글삭제");
// 업로드된 파일이 있다면 파일삭제
$sql2 = " select * from $g4[board_file_table] where bo_table = '$bo_table' and wr_id = '$row[wr_id]' ";
$result2 = sql_query($sql2);
while ($row2 = sql_fetch_array($result2))
@unlink("$g4[path]/data/file/$bo_table/$row2[bf_file]");
// 파일테이블 행 삭제
sql_query(" delete from $g4[board_file_table] where bo_table = '$bo_table' and wr_id = '$row[wr_id]' ");
$count_write++;
}
else
{
// 코멘트 포인트 삭제
if (!delete_point($row[mb_id], $bo_table, $row[wr_id], '코멘트'))
insert_point($row[mb_id], $board[bo_comment_point] * (-1), "$board[bo_subject] {$write[wr_id]}-{$row[wr_id]} 코멘트삭제");
$count_comment++;
}
}
----------- 아 착한 로빈아빠.. ^^ ---
그럼 이전 글 bbs/write_update.php 를 적용하고
포인트받기 게시판 write.skin.php에서
<? if ($row2[cnt] >= 1) { ?>
포인트 받기 버튼
<? } ?>
이렇게 싸준다면 오늘 작성한 글수가 1이상일때 받기 버튼이 보일까요?
포인트받기 게시판 write.skin.php에서
<? if ($row2[cnt] >= 1) { ?>
포인트 받기 버튼
<? } ?>
이렇게 싸준다면 오늘 작성한 글수가 1이상일때 받기 버튼이 보일까요?
아이쿠 코멘트 쓸동안 그사이 답변을 해주셨네요~ ㄳㄳ 감사합니다.
읽어봐야지~ ㅋ
읽어봐야지~ ㅋ
네.. 보여질껍니다.. 포인트 이게 재미있네요.. 저도 최근에 그누보드 가지고 놀다보니.. 포인트에 은근히 빠져듭니다. ㅋㅋ