권한설정에서요. 정보
권한설정에서요.본문
목록보기 1
읽기 1
쓰기 2
답변 2
위와같이 권한설정을 하였습니다.
로그인하지 않고 글을 읽을경우 글읽기 페이지 하단에는 (쓰기, 목록,수정...의 버튼들이 보이지않습니다.)
이경우 목록 버튼만 보이게 할수는 없나요?
댓글 전체
^^ 하단에 " 목록 " 이 나오는데요 ;;
그러게요..확인한바 다른스킨은 나오네요!!
그럼 제가 사용한 이스킨의 소스가 문제인가봅니다.
근데 문제는 제가 아직초보라 소스를봐두 잘모릅니다. 한번 봐주세요..^^;;
------------------------------------view.skin.php------------------------------------------------
<?
if (!defined("_GNUBOARD_")) exit; // 개별 페이지 접근 불가
?>
<STYLE TYPE="text/css" TITLE="">
.member { color:#585858; font-weight:normal; }
.guest { font-weight:normal; }
.lh { line-height: 150%; }
.jt { text-align:justify; }
.li { font-weight:bold; font-size:18px; vertical-align:-4px; color:#66AEAD; }
.ul { list-style-type:square; color:#66AEAD; }
.ct { font-family: Verdana, 굴림; color:#222222; }
.ed { border:1px solid #CCCCCC; }
.tx { border:1px solid #CCCCCC; }
.small { font-size:8pt; font-family: Verdana, 굴림; }
.o_line1 {font-family: tahoma;font-size:9pt;color:464646;padding:3 0 0 0;height:28px;border-width:0 0 1 0;border-color:F0F0F0;border-style:solid; }
</STYLE>
<!-- 게시글 보기 시작 -->
<table width="<?=$width?>" align="center" cellpadding="0" cellspacing="0"><tr><td>
<!-- 링크 버튼 -->
<?
ob_start();
?>
<?
$link_buttons = ob_get_contents();
ob_end_flush();
?>
<table width="100%" cellspacing="0" cellpadding="0">
<!--<tr><td height=1 bgcolor=#F5F5F5></td></tr> -->
<tr><td height=30 bgcolor=#ffffff style='word-break:break-all; border:1px solid #DBDBDB; padding:20 0 20 0;'> <? if ($is_category) { echo ($category_name ? "[$view[ca_name]] " : ""); } ?><?=$view[subject]?></td></tr>
<tr><td height=30> <font color=#7A8FDB></font><?=$view[name]?>
<? if ($is_ip_view) { echo "<span style='font-family:tahoma; font-size:8pt;color:#737373; '> ($ip)"; } ?>
<font color=#7A8FDB>Date</font> : <?=substr($view[wr_datetime],2,14)?>
<font color=#7A8FDB>Hit</font> : <?=$view[wr_hit]?>
<? if ($is_good) { ?><font color=#7A8FDB>Vote</font> : <?=$view[wr_good]?> <?}?>
<? if ($is_nogood) { ?><font color=#7A8FDB>비추천</font> : <?=$view[wr_nogood]?> <?}?></span></td></tr>
<tr><td height=1 bgcolor=#E7E7E7></td></tr>
<? if ($trackback_url) { ?>
<tr><td height=30> 트랙백 주소 : <a href="javascript:clipboard_trackback('<?=$trackback_url?>');" style="letter-spacing:0;" title='이 글을 소개할 때는 이 주소를 사용하세요'><?=$trackback_url?></a>
<script language="JavaScript">
function clipboard_trackback(str)
{
if (g4_is_gecko)
prompt("이 글의 고유주소입니다. Ctrl+C를 눌러 복사하세요.", str);
else if (g4_is_ie) {
window.clipboardData.setData("Text", str);
alert("트랙백 주소가 복사되었습니다.\n\n<?=$trackback_url?>");
}
}
</script></td></tr>
<?}?>
<?
// 가변 파일
$cnt = 0;
for ($i=0; $i<count($view[file]); $i++)
{
if ($view[file][$i][source] && !$view[file][$i][view])
{
$cnt++;
//echo "<tr><td height=22> <img src='{$board_skin_path}/img/icon_file.gif' align=absmiddle> <a href='{$view[file][$i][href]}' title='{$view[file][$i][content]}'>{$view[file][$i][source]}</strong> ({$view[file][$i][size]}), Down : {$view[file][$i][download]}, {$view[file][$i][datetime]}</a></td></tr>";
echo "<tr><td height=22 > <font color=#FF6600><b>Download</b></font> : <img src='{$board_skin_path}/img/icon_file.gif' align=absmiddle> <a href=\"javascript:file_download('{$view[file][$i][href]}', '{$view[file][$i][source]}');\" title='{$view[file][$i][content]}'>{$view[file][$i][source]}</strong>({$view[file][$i][size]}),<!-- Down : {$view[file][$i][download]},--><span style='font-family:tahoma; font-size:8pt;color:#737373; '> {$view[file][$i][datetime]}</span></a></td></tr>";
}
}
// 링크
$cnt = 0;
for ($i=1; $i<=$g4[link_count]; $i++)
{
if ($view[link][$i])
{
$cnt++;
$link = cut_str($view[link][$i], 70);
echo "<tr><td height=22> <img src='{$board_skin_path}/img/icon_link.gif' align=absmiddle> <a href='{$view[link_href][$i]}' target=_blank>{$link}</strong> ({$view[link_hit][$i]})</a></td></tr>";
}
}
?>
<!-- <tr><td height=1 bgcolor=#E7E7E7></td></tr> -->
<tr>
<td height="150" style='word-break:break-all; padding:10px; border:1px solid #F5F5F5;' bgcolor=#FFFFFF>
<?
// 파일 출력
for ($i=0; $i<=count($view[file]); $i++) {
if ($view[file][$i][view])
echo $view[file][$i][view] . "<p>";
}
?>
<span class="ct lh"><?=$view[content];?></span>
<?//echo $view[rich_content]; // {이미지:0} 과 같은 코드를 사용할 경우?>
<!-- 테러 태그 방지용 --></xml></xmp><a href=""></a><a href=''></a>
<div align=right>
<table>
<tr>
<td width=></td>
<td style='word-break:break-all; padding:0px; border:1px solid #DBDBDB;' bgcolor=#FCFCFC>
<? if ($is_signature) { echo "<br> $signature <br><br>"; } // 서명 출력 ?>
</td>
</tr>
</table>
</div>
</td>
</tr>
</table><br>
<?
include_once("./view_comment.php");
?>
<?=$link_buttons?>
</td></tr></table><br>
<script language="JavaScript">
// HTML 로 넘어온 <img ... > 태그의 폭이 테이블폭보다 크다면 테이블폭을 적용한다.
function resize_image()
{
var target = document.getElementsByName('target_resize_image[]');
var image_width = parseInt('<?=$board[bo_image_width]?>');
var image_height = 0;
for(i=0; i<target.length; i++) {
// 원래 사이즈를 저장해 놓는다
target[i].tmp_width = target[i].width;
target[i].tmp_height = target[i].height;
// 이미지 폭이 테이블 폭보다 크다면 테이블폭에 맞춘다
if(target[i].width > image_width) {
image_height = parseFloat(target[i].width / target[i].height)
target[i].width = image_width;
target[i].height = parseInt(image_width / image_height);
}
}
}
window.onload = resize_image;
function file_download(link, file)
{
<? if ($board[bo_download_point] < 0) { ?>if (confirm("'"+file+"' 파일을 다운로드 하시면 포인트가 차감(<?=number_format($board[bo_download_point])?>점)됩니다.\n\n포인트는 게시물당 한번만 차감되며 다음에 다시 다운로드 하셔도 중복하여 차감하지 않습니다.\n\n그래도 다운로드 하시겠습니까?"))<?}?>
document.location.href = link;
}
</script>
<!-- 게시글 보기 끝 -->
--------------------------view_comment.skin.php--------------------------------------------------
<?
if (!defined("_GNUBOARD_")) exit; // 개별 페이지 접근 불가
?>
<script language="JavaScript">
// 글자수 제한
var char_min = parseInt(<?=$comment_min?>); // 최소
var char_max = parseInt(<?=$comment_max?>); // 최대
</script>
<? if ($cwin==1) { ?><table width=100% cellpadding=10 align=center><tr><td><?}?>
<!-- 코멘트 리스트 -->
<?
for ($i=0; $i<count($list); $i++) {
$comment_id = $list[$i][wr_id];
?>
<a name="c_<?=$comment_id?>"></a>
<table width=100% cellpadding=0 cellspacing=0>
<tr>
<td><? for ($k=0; $k<strlen($list[$i][wr_comment_reply]); $k++) echo " "; ?></td>
<td width='100%'>
<table width=100% cellpadding=0 cellspacing=0>
<tr>
<td><?=$list[$i][name]?><? if ($is_ip_view) { echo "<span style='font-family:tahoma; font-size:8pt;color:#737373; '> ({$list[$i][ip]})</span>"; } ?></td>
<td align=right>
<? if ($list[$i][is_reply]) { echo "<a href=\"javascript:comment_box('{$comment_id}', 'c');\"><img src='$board_skin_path/img/btn_comment_reply.gif' border=0 align=absmiddle></a> "; } ?>
<? if ($list[$i][is_edit]) { echo "<a href=\"javascript:comment_box('{$comment_id}', 'cu');\"><img src='$board_skin_path/img/btn_comment_update.gif' border=0 align=absmiddle></a> "; } ?>
<? if ($list[$i][is_del]) { echo "<a href=\"javascript:comment_delete('{$list[$i][del_link]}');\"><img src='$board_skin_path/img/btn_comment_delete.gif' border=0 align=absmiddle></a> "; } ?>
<span style='font-family:tahoma; font-size:8pt;color:#737373; '><?=$list[$i][datetime]?></span></td>
</tr>
</table>
<table width=100% cellpadding=0 cellspacing=0 style='border:1px solid #F5F5F5;'>
<tr><td bgcolor=#ffffff colspan=2><img src='<?=$board_skin_path?>/img/co_point.gif'></td></tr>
<tr>
<td bgcolor=#ffffff colspan=2 style='line-height:150%; padding:7px; word-break:break-all;'>
<!-- 코멘트 출력 -->
<span class="ct lh"><?=$list[$i][content]?></span>
<? if ($list[$i][trackback]) { echo "<p>".$list[$i][trackback]."</p>"; } ?>
<span id='edit_<?=$comment_id?>' style='display:none;'></span><!-- 수정 -->
<span id='reply_<?=$comment_id?>' style='display:none;'></span><!-- 답변 -->
</td>
</tr>
</table>
<table width=100% cellpadding=0 cellspacing=0>
<tr><td colspan=2 height=20></td></tr>
</table><textarea id='save_comment_<?=$comment_id?>' style='display:none;'><?=get_text($list[$i][wr_content], 0)?></textarea></td>
</tr>
</table>
<? } ?>
<!-- 코멘트 리스트 -->
<? if ($is_comment_write) { ?>
<!-- 코멘트 입력 -->
<table width=100% cellpadding=3 cellspacing=0 bgcolor=#FFFFFF><tr><td align=right><a href="javascript:comment_box('', 'c');"><img src='<?=$board_skin_path?>/img/btn_comment_insert.gif' border=0 align=absmiddle></a></td></tr></table>
<span id=comment_write style='display:none;'>
<form name="fviewcomment" method="post" action="./write_comment_update.php" onsubmit="return fviewcomment_submit(this);" autocomplete="off" style="margin:0px;">
<input type=hidden name=w id=w value='c'>
<input type=hidden name=bo_table value='<?=$bo_table?>'>
<input type=hidden name=wr_id value='<?=$wr_id?>'>
<input type=hidden name=comment_id id='comment_id' value=''>
<input type=hidden name=sca value='<?=$sca?>' >
<input type=hidden name=sfl value='<?=$sfl?>' >
<input type=hidden name=stx value='<?=$stx?>'>
<input type=hidden name=spt value='<?=$spt?>'>
<input type=hidden name=page value='<?=$page?>'>
<input type=hidden name=cwin value='<?=$cwin?>'>
<table width=100% cellpadding=3 cellspacing=0 bgcolor=#F8F8F9>
<tr><td colspan=2>
<? if ($is_guest) { ?>
이름 <INPUT type=text maxLength=20 size=15 name="wr_name" itemname="이름" required class=ed>
패스워드 <INPUT type=password maxLength=20 size=15 name="wr_password" itemname="패스워드" required class=ed>
<? if ($is_norobot) { ?>
<?=$norobot_str?>
<INPUT title="왼쪽의 글자중 빨간글자만 순서대로 입력하세요." type="input" name="wr_key" itemname="자동등록방지" required class=ed size=10>
<?}?>
<?}?>
<span style="cursor: pointer;" onclick="textarea_decrease('wr_content', 10);"><img src="<?=$board_skin_path?>/img/up.gif"></span>
<span style="cursor: pointer;" onclick="textarea_original('wr_content', 10);"><img src="<?=$board_skin_path?>/img/start.gif"></span>
<span style="cursor: pointer;" onclick="textarea_increase('wr_content', 10);"><img src="<?=$board_skin_path?>/img/down.gif"></span>
<? if ($comment_min || $comment_max) { ?><span id=char_count></span>글자<?}?></td></tr>
<tr>
<td width="95%">
<textarea id="wr_content" name="wr_content" rows="5" itemname="내용" required
<? if ($comment_min || $comment_max) { ?>onkeyup="check_byte('wr_content', 'char_count');"<?}?> style='width:100%; word-break:break-all;' class=tx></textarea>
<? if ($comment_min || $comment_max) { ?><script language="javascript"> check_byte('wr_content', 'char_count'); </script><?}?></td>
<td width=80 align=center><input type="image" src="<?=$board_skin_path?>/img/ok_btn.gif" border=0 accesskey='s'></td></tr>
</table>
</form>
</span>
<table width='100%' cellpadding=0 cellspacing=0>
<tr height=35>
<td width=75%>
<? if ($search_href) { echo "<a href=\"$search_href\"><img src='$board_skin_path/img/btn_search_list.gif' border='0' align='absmiddle'></a> "; } ?>
<? echo "<a href=\"$list_href\"><img src='$board_skin_path/img/btn_list.gif' border='0' align='absmiddle'></a> "; ?>
<? if ($write_href) { echo "<a href=\"$write_href\"><img src='$board_skin_path/img/btn_write.gif' border='0' align='absmiddle'></a> "; } ?>
<?php /*?> <? if ($reply_href) { echo "<a href=\"$reply_href\"><img src='$board_skin_path/img/btn_reply.gif' border='0' align='absmiddle'></a> "; } ?>
<?php */?>
<? if ($update_href) { echo "<a href=\"$update_href\"><img src='$board_skin_path/img/btn_update.gif' border='0' align='absmiddle'></a> "; } ?>
<? if ($delete_href) { echo "<a href=\"$delete_href\"><img src='$board_skin_path/img/btn_delete.gif' border='0' align='absmiddle'></a> "; } ?>
<? if ($good_href) { echo "<a href=\"$good_href\" target='hiddenframe'><img src='$board_skin_path/img/btn_good.gif' border='0' align='absmiddle'></a> "; } ?>
<? if ($nogood_href) { echo "<a href=\"$nogood_href\" target='hiddenframe'><img src='$board_skin_path/img/btn_nogood.gif' border='0' align='absmiddle'></a> "; } ?>
<? if ($scrap_href) { echo "<a href=\"javascript:;\" onclick=\"win_scrap('$scrap_href');\"><img src='$board_skin_path/img/btn_scrap.gif' border='0' align='absmiddle'></a> "; } ?>
<? if ($copy_href) { echo "<a href=\"$copy_href\"><img src='$board_skin_path/img/btn_copy.gif' border='0' align='absmiddle'></a> "; } ?>
<? if ($move_href) { echo "<a href=\"$move_href\"><img src='$board_skin_path/img/btn_move.gif' border='0' align='absmiddle'></a> "; } ?>
</td>
<td width=25% align=right>
<? if ($prev_href) { echo "<a href=\"$prev_href\" title=\"$prev_wr_subject\"><img src='$board_skin_path/img/btn_prev.gif' border='0' align='absmiddle'></a> "; } ?>
<? if ($next_href) { echo "<a href=\"$next_href\" title=\"$next_wr_subject\"><img src='$board_skin_path/img/btn_next.gif' border='0' align='absmiddle'></a> "; } ?>
</td>
</tr>
</table>
<script language='JavaScript'>
var save_before = '';
var save_html = document.getElementById('comment_write').innerHTML;
function fviewcomment_submit(f)
{
var pattern = /(^\s*)|(\s*$)/g; // \s 공백 문자
var s;
if (s = word_filter_check(document.getElementById('wr_content').value))
{
alert("내용에 금지단어('"+s+"')가 포함되어있습니다");
document.getElementById('wr_content').focus();
return false;
}
// 양쪽 공백 없애기
var pattern = /(^\s*)|(\s*$)/g; // \s 공백 문자
document.getElementById('wr_content').value = document.getElementById('wr_content').value.replace(pattern, "");
if (char_min > 0 || char_max > 0)
{
check_byte('wr_content', 'char_count');
var cnt = parseInt(document.getElementById('char_count').innerHTML);
if (char_min > 0 && char_min > cnt)
{
alert("코멘트는 "+char_min+"글자 이상 쓰셔야 합니다.");
return false;
} else if (char_max > 0 && char_max < cnt)
{
alert("코멘트는 "+char_max+"글자 이하로 쓰셔야 합니다.");
return false;
}
}
else if (!document.getElementById('wr_content').value)
{
alert("코멘트를 입력하여 주십시오.");
return false;
}
if (typeof(f.wr_name) != 'undefined')
{
f.wr_name.value = f.wr_name.value.replace(pattern, "");
if (f.wr_name.value == '')
{
alert('이름이 입력되지 않았습니다.');
f.wr_name.focus();
return false;
}
}
if (typeof(f.wr_password) != 'undefined')
{
f.wr_password.value = f.wr_password.value.replace(pattern, "");
if (f.wr_password.value == '')
{
alert('패스워드가 입력되지 않았습니다.');
f.wr_password.focus();
return false;
}
}
if (typeof(f.wr_key) != 'undefined')
{
if (hex_md5(f.wr_key.value) != md5_norobot_key)
{
alert('자동등록방지용 빨간글자가 순서대로 입력되지 않았습니다.');
f.wr_key.focus();
return false;
}
}
return true;
}
function comment_box(comment_id, work)
{
var el_id;
// 코멘트 아이디가 넘어오면 답변, 수정
if (comment_id)
{
if (work == 'c')
el_id = 'reply_' + comment_id;
else
el_id = 'edit_' + comment_id;
}
else
el_id = 'comment_write';
if (save_before != el_id)
{
if (save_before)
{
document.getElementById(save_before).style.display = 'none';
document.getElementById(save_before).innerHTML = '';
}
document.getElementById(el_id).style.display = '';
document.getElementById(el_id).innerHTML = save_html;
// 코멘트 수정
if (work == 'cu')
{
document.getElementById('wr_content').value = document.getElementById('save_comment_' + comment_id).value;
if (typeof char_count != 'undefined')
check_byte('wr_content', 'char_count');
}
document.getElementById('comment_id').value = comment_id;
document.getElementById('w').value = work;
save_before = el_id;
}
}
function comment_delete(url)
{
if (confirm("이 코멘트를 삭제하시겠습니까?")) location.href = url;
}
comment_box('', 'c'); // 코멘트 입력폼이 보이도록 처리하기위해서 추가 (root님)
</script>
<? } ?>
<? if($cwin==1) { ?></td><tr></table><p align=center><a href="javascript:window.close();"><img src="<?=$board_skin_path?>/img/btn_close.gif" border="0"></a><br><br><?}?>
그럼 제가 사용한 이스킨의 소스가 문제인가봅니다.
근데 문제는 제가 아직초보라 소스를봐두 잘모릅니다. 한번 봐주세요..^^;;
------------------------------------view.skin.php------------------------------------------------
<?
if (!defined("_GNUBOARD_")) exit; // 개별 페이지 접근 불가
?>
<STYLE TYPE="text/css" TITLE="">
.member { color:#585858; font-weight:normal; }
.guest { font-weight:normal; }
.lh { line-height: 150%; }
.jt { text-align:justify; }
.li { font-weight:bold; font-size:18px; vertical-align:-4px; color:#66AEAD; }
.ul { list-style-type:square; color:#66AEAD; }
.ct { font-family: Verdana, 굴림; color:#222222; }
.ed { border:1px solid #CCCCCC; }
.tx { border:1px solid #CCCCCC; }
.small { font-size:8pt; font-family: Verdana, 굴림; }
.o_line1 {font-family: tahoma;font-size:9pt;color:464646;padding:3 0 0 0;height:28px;border-width:0 0 1 0;border-color:F0F0F0;border-style:solid; }
</STYLE>
<!-- 게시글 보기 시작 -->
<table width="<?=$width?>" align="center" cellpadding="0" cellspacing="0"><tr><td>
<!-- 링크 버튼 -->
<?
ob_start();
?>
<?
$link_buttons = ob_get_contents();
ob_end_flush();
?>
<table width="100%" cellspacing="0" cellpadding="0">
<!--<tr><td height=1 bgcolor=#F5F5F5></td></tr> -->
<tr><td height=30 bgcolor=#ffffff style='word-break:break-all; border:1px solid #DBDBDB; padding:20 0 20 0;'> <? if ($is_category) { echo ($category_name ? "[$view[ca_name]] " : ""); } ?><?=$view[subject]?></td></tr>
<tr><td height=30> <font color=#7A8FDB></font><?=$view[name]?>
<? if ($is_ip_view) { echo "<span style='font-family:tahoma; font-size:8pt;color:#737373; '> ($ip)"; } ?>
<font color=#7A8FDB>Date</font> : <?=substr($view[wr_datetime],2,14)?>
<font color=#7A8FDB>Hit</font> : <?=$view[wr_hit]?>
<? if ($is_good) { ?><font color=#7A8FDB>Vote</font> : <?=$view[wr_good]?> <?}?>
<? if ($is_nogood) { ?><font color=#7A8FDB>비추천</font> : <?=$view[wr_nogood]?> <?}?></span></td></tr>
<tr><td height=1 bgcolor=#E7E7E7></td></tr>
<? if ($trackback_url) { ?>
<tr><td height=30> 트랙백 주소 : <a href="javascript:clipboard_trackback('<?=$trackback_url?>');" style="letter-spacing:0;" title='이 글을 소개할 때는 이 주소를 사용하세요'><?=$trackback_url?></a>
<script language="JavaScript">
function clipboard_trackback(str)
{
if (g4_is_gecko)
prompt("이 글의 고유주소입니다. Ctrl+C를 눌러 복사하세요.", str);
else if (g4_is_ie) {
window.clipboardData.setData("Text", str);
alert("트랙백 주소가 복사되었습니다.\n\n<?=$trackback_url?>");
}
}
</script></td></tr>
<?}?>
<?
// 가변 파일
$cnt = 0;
for ($i=0; $i<count($view[file]); $i++)
{
if ($view[file][$i][source] && !$view[file][$i][view])
{
$cnt++;
//echo "<tr><td height=22> <img src='{$board_skin_path}/img/icon_file.gif' align=absmiddle> <a href='{$view[file][$i][href]}' title='{$view[file][$i][content]}'>{$view[file][$i][source]}</strong> ({$view[file][$i][size]}), Down : {$view[file][$i][download]}, {$view[file][$i][datetime]}</a></td></tr>";
echo "<tr><td height=22 > <font color=#FF6600><b>Download</b></font> : <img src='{$board_skin_path}/img/icon_file.gif' align=absmiddle> <a href=\"javascript:file_download('{$view[file][$i][href]}', '{$view[file][$i][source]}');\" title='{$view[file][$i][content]}'>{$view[file][$i][source]}</strong>({$view[file][$i][size]}),<!-- Down : {$view[file][$i][download]},--><span style='font-family:tahoma; font-size:8pt;color:#737373; '> {$view[file][$i][datetime]}</span></a></td></tr>";
}
}
// 링크
$cnt = 0;
for ($i=1; $i<=$g4[link_count]; $i++)
{
if ($view[link][$i])
{
$cnt++;
$link = cut_str($view[link][$i], 70);
echo "<tr><td height=22> <img src='{$board_skin_path}/img/icon_link.gif' align=absmiddle> <a href='{$view[link_href][$i]}' target=_blank>{$link}</strong> ({$view[link_hit][$i]})</a></td></tr>";
}
}
?>
<!-- <tr><td height=1 bgcolor=#E7E7E7></td></tr> -->
<tr>
<td height="150" style='word-break:break-all; padding:10px; border:1px solid #F5F5F5;' bgcolor=#FFFFFF>
<?
// 파일 출력
for ($i=0; $i<=count($view[file]); $i++) {
if ($view[file][$i][view])
echo $view[file][$i][view] . "<p>";
}
?>
<span class="ct lh"><?=$view[content];?></span>
<?//echo $view[rich_content]; // {이미지:0} 과 같은 코드를 사용할 경우?>
<!-- 테러 태그 방지용 --></xml></xmp><a href=""></a><a href=''></a>
<div align=right>
<table>
<tr>
<td width=></td>
<td style='word-break:break-all; padding:0px; border:1px solid #DBDBDB;' bgcolor=#FCFCFC>
<? if ($is_signature) { echo "<br> $signature <br><br>"; } // 서명 출력 ?>
</td>
</tr>
</table>
</div>
</td>
</tr>
</table><br>
<?
include_once("./view_comment.php");
?>
<?=$link_buttons?>
</td></tr></table><br>
<script language="JavaScript">
// HTML 로 넘어온 <img ... > 태그의 폭이 테이블폭보다 크다면 테이블폭을 적용한다.
function resize_image()
{
var target = document.getElementsByName('target_resize_image[]');
var image_width = parseInt('<?=$board[bo_image_width]?>');
var image_height = 0;
for(i=0; i<target.length; i++) {
// 원래 사이즈를 저장해 놓는다
target[i].tmp_width = target[i].width;
target[i].tmp_height = target[i].height;
// 이미지 폭이 테이블 폭보다 크다면 테이블폭에 맞춘다
if(target[i].width > image_width) {
image_height = parseFloat(target[i].width / target[i].height)
target[i].width = image_width;
target[i].height = parseInt(image_width / image_height);
}
}
}
window.onload = resize_image;
function file_download(link, file)
{
<? if ($board[bo_download_point] < 0) { ?>if (confirm("'"+file+"' 파일을 다운로드 하시면 포인트가 차감(<?=number_format($board[bo_download_point])?>점)됩니다.\n\n포인트는 게시물당 한번만 차감되며 다음에 다시 다운로드 하셔도 중복하여 차감하지 않습니다.\n\n그래도 다운로드 하시겠습니까?"))<?}?>
document.location.href = link;
}
</script>
<!-- 게시글 보기 끝 -->
--------------------------view_comment.skin.php--------------------------------------------------
<?
if (!defined("_GNUBOARD_")) exit; // 개별 페이지 접근 불가
?>
<script language="JavaScript">
// 글자수 제한
var char_min = parseInt(<?=$comment_min?>); // 최소
var char_max = parseInt(<?=$comment_max?>); // 최대
</script>
<? if ($cwin==1) { ?><table width=100% cellpadding=10 align=center><tr><td><?}?>
<!-- 코멘트 리스트 -->
<?
for ($i=0; $i<count($list); $i++) {
$comment_id = $list[$i][wr_id];
?>
<a name="c_<?=$comment_id?>"></a>
<table width=100% cellpadding=0 cellspacing=0>
<tr>
<td><? for ($k=0; $k<strlen($list[$i][wr_comment_reply]); $k++) echo " "; ?></td>
<td width='100%'>
<table width=100% cellpadding=0 cellspacing=0>
<tr>
<td><?=$list[$i][name]?><? if ($is_ip_view) { echo "<span style='font-family:tahoma; font-size:8pt;color:#737373; '> ({$list[$i][ip]})</span>"; } ?></td>
<td align=right>
<? if ($list[$i][is_reply]) { echo "<a href=\"javascript:comment_box('{$comment_id}', 'c');\"><img src='$board_skin_path/img/btn_comment_reply.gif' border=0 align=absmiddle></a> "; } ?>
<? if ($list[$i][is_edit]) { echo "<a href=\"javascript:comment_box('{$comment_id}', 'cu');\"><img src='$board_skin_path/img/btn_comment_update.gif' border=0 align=absmiddle></a> "; } ?>
<? if ($list[$i][is_del]) { echo "<a href=\"javascript:comment_delete('{$list[$i][del_link]}');\"><img src='$board_skin_path/img/btn_comment_delete.gif' border=0 align=absmiddle></a> "; } ?>
<span style='font-family:tahoma; font-size:8pt;color:#737373; '><?=$list[$i][datetime]?></span></td>
</tr>
</table>
<table width=100% cellpadding=0 cellspacing=0 style='border:1px solid #F5F5F5;'>
<tr><td bgcolor=#ffffff colspan=2><img src='<?=$board_skin_path?>/img/co_point.gif'></td></tr>
<tr>
<td bgcolor=#ffffff colspan=2 style='line-height:150%; padding:7px; word-break:break-all;'>
<!-- 코멘트 출력 -->
<span class="ct lh"><?=$list[$i][content]?></span>
<? if ($list[$i][trackback]) { echo "<p>".$list[$i][trackback]."</p>"; } ?>
<span id='edit_<?=$comment_id?>' style='display:none;'></span><!-- 수정 -->
<span id='reply_<?=$comment_id?>' style='display:none;'></span><!-- 답변 -->
</td>
</tr>
</table>
<table width=100% cellpadding=0 cellspacing=0>
<tr><td colspan=2 height=20></td></tr>
</table><textarea id='save_comment_<?=$comment_id?>' style='display:none;'><?=get_text($list[$i][wr_content], 0)?></textarea></td>
</tr>
</table>
<? } ?>
<!-- 코멘트 리스트 -->
<? if ($is_comment_write) { ?>
<!-- 코멘트 입력 -->
<table width=100% cellpadding=3 cellspacing=0 bgcolor=#FFFFFF><tr><td align=right><a href="javascript:comment_box('', 'c');"><img src='<?=$board_skin_path?>/img/btn_comment_insert.gif' border=0 align=absmiddle></a></td></tr></table>
<span id=comment_write style='display:none;'>
<form name="fviewcomment" method="post" action="./write_comment_update.php" onsubmit="return fviewcomment_submit(this);" autocomplete="off" style="margin:0px;">
<input type=hidden name=w id=w value='c'>
<input type=hidden name=bo_table value='<?=$bo_table?>'>
<input type=hidden name=wr_id value='<?=$wr_id?>'>
<input type=hidden name=comment_id id='comment_id' value=''>
<input type=hidden name=sca value='<?=$sca?>' >
<input type=hidden name=sfl value='<?=$sfl?>' >
<input type=hidden name=stx value='<?=$stx?>'>
<input type=hidden name=spt value='<?=$spt?>'>
<input type=hidden name=page value='<?=$page?>'>
<input type=hidden name=cwin value='<?=$cwin?>'>
<table width=100% cellpadding=3 cellspacing=0 bgcolor=#F8F8F9>
<tr><td colspan=2>
<? if ($is_guest) { ?>
이름 <INPUT type=text maxLength=20 size=15 name="wr_name" itemname="이름" required class=ed>
패스워드 <INPUT type=password maxLength=20 size=15 name="wr_password" itemname="패스워드" required class=ed>
<? if ($is_norobot) { ?>
<?=$norobot_str?>
<INPUT title="왼쪽의 글자중 빨간글자만 순서대로 입력하세요." type="input" name="wr_key" itemname="자동등록방지" required class=ed size=10>
<?}?>
<?}?>
<span style="cursor: pointer;" onclick="textarea_decrease('wr_content', 10);"><img src="<?=$board_skin_path?>/img/up.gif"></span>
<span style="cursor: pointer;" onclick="textarea_original('wr_content', 10);"><img src="<?=$board_skin_path?>/img/start.gif"></span>
<span style="cursor: pointer;" onclick="textarea_increase('wr_content', 10);"><img src="<?=$board_skin_path?>/img/down.gif"></span>
<? if ($comment_min || $comment_max) { ?><span id=char_count></span>글자<?}?></td></tr>
<tr>
<td width="95%">
<textarea id="wr_content" name="wr_content" rows="5" itemname="내용" required
<? if ($comment_min || $comment_max) { ?>onkeyup="check_byte('wr_content', 'char_count');"<?}?> style='width:100%; word-break:break-all;' class=tx></textarea>
<? if ($comment_min || $comment_max) { ?><script language="javascript"> check_byte('wr_content', 'char_count'); </script><?}?></td>
<td width=80 align=center><input type="image" src="<?=$board_skin_path?>/img/ok_btn.gif" border=0 accesskey='s'></td></tr>
</table>
</form>
</span>
<table width='100%' cellpadding=0 cellspacing=0>
<tr height=35>
<td width=75%>
<? if ($search_href) { echo "<a href=\"$search_href\"><img src='$board_skin_path/img/btn_search_list.gif' border='0' align='absmiddle'></a> "; } ?>
<? echo "<a href=\"$list_href\"><img src='$board_skin_path/img/btn_list.gif' border='0' align='absmiddle'></a> "; ?>
<? if ($write_href) { echo "<a href=\"$write_href\"><img src='$board_skin_path/img/btn_write.gif' border='0' align='absmiddle'></a> "; } ?>
<?php /*?> <? if ($reply_href) { echo "<a href=\"$reply_href\"><img src='$board_skin_path/img/btn_reply.gif' border='0' align='absmiddle'></a> "; } ?>
<?php */?>
<? if ($update_href) { echo "<a href=\"$update_href\"><img src='$board_skin_path/img/btn_update.gif' border='0' align='absmiddle'></a> "; } ?>
<? if ($delete_href) { echo "<a href=\"$delete_href\"><img src='$board_skin_path/img/btn_delete.gif' border='0' align='absmiddle'></a> "; } ?>
<? if ($good_href) { echo "<a href=\"$good_href\" target='hiddenframe'><img src='$board_skin_path/img/btn_good.gif' border='0' align='absmiddle'></a> "; } ?>
<? if ($nogood_href) { echo "<a href=\"$nogood_href\" target='hiddenframe'><img src='$board_skin_path/img/btn_nogood.gif' border='0' align='absmiddle'></a> "; } ?>
<? if ($scrap_href) { echo "<a href=\"javascript:;\" onclick=\"win_scrap('$scrap_href');\"><img src='$board_skin_path/img/btn_scrap.gif' border='0' align='absmiddle'></a> "; } ?>
<? if ($copy_href) { echo "<a href=\"$copy_href\"><img src='$board_skin_path/img/btn_copy.gif' border='0' align='absmiddle'></a> "; } ?>
<? if ($move_href) { echo "<a href=\"$move_href\"><img src='$board_skin_path/img/btn_move.gif' border='0' align='absmiddle'></a> "; } ?>
</td>
<td width=25% align=right>
<? if ($prev_href) { echo "<a href=\"$prev_href\" title=\"$prev_wr_subject\"><img src='$board_skin_path/img/btn_prev.gif' border='0' align='absmiddle'></a> "; } ?>
<? if ($next_href) { echo "<a href=\"$next_href\" title=\"$next_wr_subject\"><img src='$board_skin_path/img/btn_next.gif' border='0' align='absmiddle'></a> "; } ?>
</td>
</tr>
</table>
<script language='JavaScript'>
var save_before = '';
var save_html = document.getElementById('comment_write').innerHTML;
function fviewcomment_submit(f)
{
var pattern = /(^\s*)|(\s*$)/g; // \s 공백 문자
var s;
if (s = word_filter_check(document.getElementById('wr_content').value))
{
alert("내용에 금지단어('"+s+"')가 포함되어있습니다");
document.getElementById('wr_content').focus();
return false;
}
// 양쪽 공백 없애기
var pattern = /(^\s*)|(\s*$)/g; // \s 공백 문자
document.getElementById('wr_content').value = document.getElementById('wr_content').value.replace(pattern, "");
if (char_min > 0 || char_max > 0)
{
check_byte('wr_content', 'char_count');
var cnt = parseInt(document.getElementById('char_count').innerHTML);
if (char_min > 0 && char_min > cnt)
{
alert("코멘트는 "+char_min+"글자 이상 쓰셔야 합니다.");
return false;
} else if (char_max > 0 && char_max < cnt)
{
alert("코멘트는 "+char_max+"글자 이하로 쓰셔야 합니다.");
return false;
}
}
else if (!document.getElementById('wr_content').value)
{
alert("코멘트를 입력하여 주십시오.");
return false;
}
if (typeof(f.wr_name) != 'undefined')
{
f.wr_name.value = f.wr_name.value.replace(pattern, "");
if (f.wr_name.value == '')
{
alert('이름이 입력되지 않았습니다.');
f.wr_name.focus();
return false;
}
}
if (typeof(f.wr_password) != 'undefined')
{
f.wr_password.value = f.wr_password.value.replace(pattern, "");
if (f.wr_password.value == '')
{
alert('패스워드가 입력되지 않았습니다.');
f.wr_password.focus();
return false;
}
}
if (typeof(f.wr_key) != 'undefined')
{
if (hex_md5(f.wr_key.value) != md5_norobot_key)
{
alert('자동등록방지용 빨간글자가 순서대로 입력되지 않았습니다.');
f.wr_key.focus();
return false;
}
}
return true;
}
function comment_box(comment_id, work)
{
var el_id;
// 코멘트 아이디가 넘어오면 답변, 수정
if (comment_id)
{
if (work == 'c')
el_id = 'reply_' + comment_id;
else
el_id = 'edit_' + comment_id;
}
else
el_id = 'comment_write';
if (save_before != el_id)
{
if (save_before)
{
document.getElementById(save_before).style.display = 'none';
document.getElementById(save_before).innerHTML = '';
}
document.getElementById(el_id).style.display = '';
document.getElementById(el_id).innerHTML = save_html;
// 코멘트 수정
if (work == 'cu')
{
document.getElementById('wr_content').value = document.getElementById('save_comment_' + comment_id).value;
if (typeof char_count != 'undefined')
check_byte('wr_content', 'char_count');
}
document.getElementById('comment_id').value = comment_id;
document.getElementById('w').value = work;
save_before = el_id;
}
}
function comment_delete(url)
{
if (confirm("이 코멘트를 삭제하시겠습니까?")) location.href = url;
}
comment_box('', 'c'); // 코멘트 입력폼이 보이도록 처리하기위해서 추가 (root님)
</script>
<? } ?>
<? if($cwin==1) { ?></td><tr></table><p align=center><a href="javascript:window.close();"><img src="<?=$board_skin_path?>/img/btn_close.gif" border="0"></a><br><br><?}?>
^^ ;; 위에꺼에 링크버트 지우시구요 아래 ( ** 참조 : basic_new skin ) 꺼로 붙이세용.
view.skin.php
--------------
1. 상단에 아래내용.
------------------------------------------
<!-- 링크 버튼 -->
<?
ob_start();
?>
<table width='100%' cellpadding=0 cellspacing=0>
<tr height=35>
<td width=75%>
<? if ($search_href) { echo "<a href=\"$search_href\"><img src='$board_skin_path/img/btn_search_list.gif' border='0' align='absmiddle'></a> "; } ?>
<? echo "<a href=\"$list_href\"><img src='$board_skin_path/img/btn_list.gif' border='0' align='absmiddle'></a> "; ?>
<? if ($write_href) { echo "<a href=\"$write_href\"><img src='$board_skin_path/img/btn_write.gif' border='0' align='absmiddle'></a> "; } ?>
<? if ($reply_href) { echo "<a href=\"$reply_href\"><img src='$board_skin_path/img/btn_reply.gif' border='0' align='absmiddle'></a> "; } ?>
<? if ($update_href) { echo "<a href=\"$update_href\"><img src='$board_skin_path/img/btn_modify.gif' border='0' align='absmiddle'></a> "; } ?>
<? if ($delete_href) { echo "<a href=\"$delete_href\"><img src='$board_skin_path/img/btn_del.gif' border='0' align='absmiddle'></a> "; } ?>
<? if ($good_href) { echo "<a href=\"$good_href\" target='hiddenframe'><img src='$board_skin_path/img/btn_good.gif' border='0' align='absmiddle'></a> "; } ?>
<? if ($nogood_href) { echo "<a href=\"$nogood_href\" target='hiddenframe'><img src='$board_skin_path/img/btn_nogood.gif' border='0' align='absmiddle'></a> "; } ?>
<? if ($scrap_href) { echo "<a href=\"javascript:;\" onclick=\"win_scrap('$scrap_href');\"><img src='$board_skin_path/img/btn_scrap.gif' border='0' align='absmiddle'></a> "; } ?>
<? if ($copy_href) { echo "<a href=\"$copy_href\"><img src='$board_skin_path/img/btn_copy.gif' border='0' align='absmiddle'></a> "; } ?>
<? if ($move_href) { echo "<a href=\"$move_href\"><img src='$board_skin_path/img/btn_move.gif' border='0' align='absmiddle'></a> "; } ?>
</td>
<td width=25% align=right>
<? if ($prev_href) { echo "<a href=\"$prev_href\" title=\"$prev_wr_subject\"><img src='$board_skin_path/img/btn_prev.gif' border='0' align='absmiddle'></a> "; } ?>
<? if ($next_href) { echo "<a href=\"$next_href\" title=\"$next_wr_subject\"><img src='$board_skin_path/img/btn_next.gif' border='0' align='absmiddle'></a> "; } ?>
</td>
</tr>
</table>
<?
$link_buttons = ob_get_contents();
ob_end_flush();
?>
view.skin.php
--------------
1. 상단에 아래내용.
------------------------------------------
<!-- 링크 버튼 -->
<?
ob_start();
?>
<table width='100%' cellpadding=0 cellspacing=0>
<tr height=35>
<td width=75%>
<? if ($search_href) { echo "<a href=\"$search_href\"><img src='$board_skin_path/img/btn_search_list.gif' border='0' align='absmiddle'></a> "; } ?>
<? echo "<a href=\"$list_href\"><img src='$board_skin_path/img/btn_list.gif' border='0' align='absmiddle'></a> "; ?>
<? if ($write_href) { echo "<a href=\"$write_href\"><img src='$board_skin_path/img/btn_write.gif' border='0' align='absmiddle'></a> "; } ?>
<? if ($reply_href) { echo "<a href=\"$reply_href\"><img src='$board_skin_path/img/btn_reply.gif' border='0' align='absmiddle'></a> "; } ?>
<? if ($update_href) { echo "<a href=\"$update_href\"><img src='$board_skin_path/img/btn_modify.gif' border='0' align='absmiddle'></a> "; } ?>
<? if ($delete_href) { echo "<a href=\"$delete_href\"><img src='$board_skin_path/img/btn_del.gif' border='0' align='absmiddle'></a> "; } ?>
<? if ($good_href) { echo "<a href=\"$good_href\" target='hiddenframe'><img src='$board_skin_path/img/btn_good.gif' border='0' align='absmiddle'></a> "; } ?>
<? if ($nogood_href) { echo "<a href=\"$nogood_href\" target='hiddenframe'><img src='$board_skin_path/img/btn_nogood.gif' border='0' align='absmiddle'></a> "; } ?>
<? if ($scrap_href) { echo "<a href=\"javascript:;\" onclick=\"win_scrap('$scrap_href');\"><img src='$board_skin_path/img/btn_scrap.gif' border='0' align='absmiddle'></a> "; } ?>
<? if ($copy_href) { echo "<a href=\"$copy_href\"><img src='$board_skin_path/img/btn_copy.gif' border='0' align='absmiddle'></a> "; } ?>
<? if ($move_href) { echo "<a href=\"$move_href\"><img src='$board_skin_path/img/btn_move.gif' border='0' align='absmiddle'></a> "; } ?>
</td>
<td width=25% align=right>
<? if ($prev_href) { echo "<a href=\"$prev_href\" title=\"$prev_wr_subject\"><img src='$board_skin_path/img/btn_prev.gif' border='0' align='absmiddle'></a> "; } ?>
<? if ($next_href) { echo "<a href=\"$next_href\" title=\"$next_wr_subject\"><img src='$board_skin_path/img/btn_next.gif' border='0' align='absmiddle'></a> "; } ?>
</td>
</tr>
</table>
<?
$link_buttons = ob_get_contents();
ob_end_flush();
?>
2. 하단에 아래내용.
-----------------------
<?=$link_buttons?>
-----------------------
<?=$link_buttons?>
ps - 음냐... 위치는 잘...찍으시면 될듯 한데요 ;;
감사합니다..
이제 나타나네요..^^
이제 나타나네요..^^