리스트에서 첨부파일2 받기 정보
리스트에서 첨부파일2 받기본문
목진철님의 교수소개 스킨을 사용중입니다.
워낙 초보인지라 이것저것 수정하다가 보니 많이 지저분한 것 같습니다.
첨부파일 1은 교수소개 사진이며, 잘 나옵니다.
이에 첨부파일 2를 다운로드 받게 하려고 합니다.
검색을 해보니...
<?
$ss_name = "ss_view_{$bo_table}_{$list[$i][wr_id]}";
session_register($ss_name);
$$ss_name = $HTTP_SESSION_VARS[$ss_name] = TRUE;
if($list[$i][file][0]) {
$down_link0 = "download.php?bo_table=" . $bo_table . "&wr_id=" . $list[$i][wr_id] . "&no=0";
echo "<a href='$down_link0'>";
echo "1번파일링크";
echo "</a>";
}
if($list[$i][file][1]) {
$down_link1 = "download.php?bo_table=" . $bo_table . "&wr_id=" . $list[$i][wr_id] . "&no=1";
echo "<a href='$down_link1'>";
echo "2번파일링크";
echo "</a>";
}
?>
를 사용하면 된다고 하던데, 저는 왜 적용이 안되는 것일까요?
리스트에서 어떻게 처리해야 할런지요. 제발 부탁드립니다.
=============이하는 현재 리스트 입니다==========================================
<?
if (!defined("_GNUBOARD_")) exit; // 개별 페이지 접근 불가
?>
<style>
/* line_style */
.h1_gray_line {height:1px; background-color:#e7e7e7;}
/* Default Type */
*{line-height:18px;}
</style>
<table width="<?=$width?>" align="center" cellpadding="0" cellspcing="0" bgcolor="#FFFFFF"><tr><td>
<!-- 여백 --><!-- <table width="100%" cellspacing="0" cellpadding="0"><tr><td height="5"></td></tr></table> -->
<table width="100%" cellspacing="0" cellpadding="0" border=0>
<form name="fboardlist" method="post">
<input type="hidden" name="bo_table" value="<?=$bo_table?>">
<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="sw" value="">
<!-- <? if ($is_admin) { ?><tr><td height=30 colspan='<?=$board[bo_gallery_cols]?>' style='padding-left:20px;'><INPUT onclick="if (this.checked) all_checked(true); else all_checked(false);" type=checkbox> 전체선택</td></tr><? } ?> -->
<tr>
<?
for ($i=0; $i<count($list); $i++)
{
$homepageurl="";
$_datetime=$list[$i][datetime2];
$_hit=$list[$i][wr_hit];
$title = "클릭하시면 해당 사이트로 이동합니다.";
//$content = cut_str(get_text($list[$i][wr_content]), 80);
$content = $list[$i][wr_content];
$img = "$g4[path]/data/file/$bo_table/".urlencode($list[$i][file][0][file]);
if (!file_exists($img) || !$list[$i][file][0][file])
$img = "$board_skin_path/img/photo_noimg.gif";
$href = "$g4[bbs_path]/board.php?bo_table=$bo_table&wr_id={$list[$i][wr_id]}&no=1";
//$view_href = "";
//if ($is_admin)
$view_href = "<a href='$g4[bbs_path]/board.php?bo_table=$bo_table&wr_id={$list[$i][wr_id]}'>";
$checkbox = "";
if ($is_checkbox)
$checkbox = "<input type=checkbox name=chk_wr_id[] value='{$list[$i][wr_id]}'>";
$link = cut_str($list[$i][wr_link1], 70);
//$homepageurl="<a href='{$list[$i][wr_link1]}' target=_blank>{$link}</a>";
//$homepageurl="<a href='http://www.cuins.co.kr' target=_blank>";
$wr_guide = nl2br(cut_str($list[$i][wr_3],250));
$tr = "";
if ($i && $i%$board[bo_gallery_cols]==0)
$tr = "</tr><tr>";
echo "$tr";
if ($is_checkbox) { $admin_mod="<a href='$g4[bbs_path]/write.php?w=u&bo_table=$bo_table&wr_id={$list[$i][wr_id]}'>"; }
echo <<<HEREDOC
<td width="{$td_width}%" valign="top" align="center">
<BR>
<TABLE cellSpacing=0 cellPadding=0 width=660 align=center border=0>
<TR>
<TD width="13%" rowSpan=2><IMG height=25 src="../inc/img/dbs_faculty/titlebar.gif" width=136></TD>
<TD align=right>Home > DBS MBA > Faculty Profiles</TD></TR>
<TR>
<TD class=h1_gray_line></TD>
</TR>
</TABLE>
<BR>
<table width='660' border='0' cellspacing='0' cellpadding='2'>
<tr>
<td align='center' valign='top'>
<table width="100%" border="0" cellpadding="0" cellspacing="1" bgcolor="e8e8e8">
<tr>
<td bgcolor="ffffff">
<table width="100%" border="0" cellpadding="0" cellspacing="1">
<tr>
<td bgcolor="f0f0f0" style="padding:7px;">
<table width="100%" border="0" cellpadding="0" cellspacing="1" bgcolor="ffffff">
<tr>
<td>
{$admin_mod}<img src='{$img}' width='190' height='217' border='0'></a><BR></td>
<td width="20"></td>
<td valign="middle">
<table width='430' border='0' cellspacing='0' cellpadding='2'>
<tr><td><table border="0" width="100%" cellpadding="1" cellspacing="1" height='25'><tr><td width="80" bgcolor="#EFEDED" align="center">성 명</td><td width="10"> </td><td>{$list[$i][subject]}</td></tr></table></td></tr>
<tr><td height='1' bgcolor='#f0f0f0'></td></tr>
<tr><td><table border="0" width="100%" cellpadding="1" cellspacing="1" height='25'><tr><td width="80" bgcolor="#EFEDED" align="center">직 위</td><td width="10"> </td><td>{$list[$i][wr_1]}</td></tr></table></td></tr>
<tr><td height='1' bgcolor='#f0f0f0'></td></tr>
<tr><td><table border="0" width="100%" cellpadding="1" cellspacing="1" height='25'><tr><td width="80" bgcolor="#EFEDED" align="center">연 구 실</td><td width="10"> </td><td>{$list[$i][wr_2]}</td></tr></table></td></tr>
<tr><td height='1' bgcolor='#f0f0f0'></td></tr>
<tr><td><table border="0" width="100%" cellpadding="1" cellspacing="1" height='25'><tr><td width="80" bgcolor="#EFEDED" align="center">교내전화</td><td width="10"> </td><td>{$list[$i][wr_3]}</td></tr></table></td></tr>
<tr><td height='1' bgcolor='#f0f0f0'></td></tr>
<tr><td><table border="0" width="100%" cellpadding="1" cellspacing="1" height='25'><tr><td width="80" bgcolor="#EFEDED" align="center">이 메 일</td><td width="10"> </td><td>{$list[$i][wr_link1]}</td></tr></table></td></tr>
<tr><td height='1' bgcolor='#f0f0f0'></td></tr>
<tr><td><table border="0" width="100%" cellpadding="1" cellspacing="1" height='25'><tr><td width="80" bgcolor="#EFEDED" align="center">연구분야</td><td width="10"> </td><td>{$list[$i][wr_4]}</td></tr></table></td></tr>
<tr><td height='1' bgcolor='#f0f0f0'></td></tr>
<tr><td><table border="0" width="100%" cellpadding="1" cellspacing="1" height='25'><tr><td width="80" bgcolor="#EFEDED" align="center">강의분야</td><td width="10"> </td><td>{$list[$i][wr_5]}</td></tr></table></td></tr>
<tr><td height='1' bgcolor='#f0f0f0'></td></tr>
<tr><td>
<?
$ss_name = "ss_view_{$bo_table}_{$list[$i][wr_id]}";
session_register($ss_name);
$$ss_name = $HTTP_SESSION_VARS[$ss_name] = TRUE;
if($list[$i][file][0]) {
$down_link0 = "download.php?bo_table=" . $bo_table . "&wr_id=" . $list[$i][wr_id] . "&no=0";
echo "<a href='$down_link0'>";
echo "1번파일링크";
echo "</a>";
}
if($list[$i][file][1]) {
$down_link1 = "download.php?bo_table=" . $bo_table . "&wr_id=" . $list[$i][wr_id] . "&no=1";
echo "<a href='$down_link1'>";
echo "2번파일링크";
echo "</a>";
}
?>
</td></tr>
<tr><td height='1' bgcolor='#f0f0f0'></td></tr>
</table>
</td>
</tr>
</table>
</td>
</tr>
</table>
</td>
</tr>
</table>
</td>
</tr>
<tr>
<td valign="top" width="100%">
<table align="center" cellpadding="5" cellspacing="1" width="100%">
<tr>
<td>{$list[$i][wr_content]}</td>
</tr>
</table>
</td>
</tr>
</table>
<br>
</td>
HEREDOC;
}
// 나머지 td 를 채운다.
if (($cnt = $i%$list_mod) != 0)
for ($k=$cnt; $k<$list_mod; $k++)
echo "<td> </td>\n";
if ($i == 0)
echo "<td colspan='$board[bo_gallery_cols]' height=50 align=center>등록된 정보가 없습니다.</td>";
?>
</form>
</tr>
</table>
<!-- <table width="100%" border="0" cellspacing="0" cellpadding="0"><tr><td height="1" width="100%" bgcolor="#CCCCCC"></td></tr></table> -->
<!-- <table width="100%" cellspacing="0" cellpadding="0">
<tr>
<td align="center" valign="middle">
<table width="500" border="0" cellspacing="0" cellpadding="0">
<tr>
<td width="100%" align="center">
<? if ($prev_part_href) { echo "<a href='$prev_part_href'><img src='$board_skin_path/img/btn_search_prev.gif' width=50 height=20 border=0 align=absmiddle title='이전검색'></a>"; } ?>
<?
// 기본으로 넘어오는 페이지를 아래와 같이 변환하여 이미지로도 출력할 수 있습니다.
//echo $write_pages;
$write_pages = str_replace("처음", "<img src='$board_skin_path/img/begin.gif' border='0' align='absmiddle' title='처음'>", $write_pages);
$write_pages = str_replace("이전", "<img src='$board_skin_path/img/prev.gif' border='0' align='absmiddle' title='이전'>", $write_pages);
$write_pages = str_replace("다음", "<img src='$board_skin_path/img/next.gif' border='0' align='absmiddle' title='다음'>", $write_pages);
$write_pages = str_replace("맨끝", "<img src='$board_skin_path/img/end.gif' border='0' align='absmiddle' title='맨끝'>", $write_pages);
$write_pages = preg_replace("/<span>([0-9]*)<\/span>/", "<font style=\"font-family:돋움; font-size:9pt; color:#797979\">$1</font>", $write_pages);
$write_pages = preg_replace("/<b>([0-9]*)<\/b>/", "<font style=\"font-family:돋움; font-size:9pt; color:orange;\">$1</font>", $write_pages);
?>
<strong><?=$write_pages?></strong>
<? if ($next_part_href) { echo "<a href='$next_part_href'><img src='$board_skin_path/img/btn_search_next.gif' width=50 height=20 border=0 align=absmiddle title='다음검색'></a>"; } ?>
</td>
</tr>
</table>
</td>
</tr>
</table> -->
<!-- <table width="100%" cellspacing="0" cellpadding="0">
<tr align="left" valign="middle">
<td width="50%" height="40">
<? if ($list_href) { ?><a href="<?=$list_href?>"><img src="<?=$board_skin_path?>/img/btn_list.gif" border="0" align="absmiddle"></a><? } ?>
<? if ($write_href) { ?><a href="<?=$write_href?>"><img src="<?=$board_skin_path?>/img/btn_write.gif" border="0" align="absmiddle"></a><? } ?>
<? if ($is_checkbox) { ?>
<a href="javascript:select_delete();"><img src="<?=$board_skin_path?>/img/btn_select_delete.gif" border="0" align="absmiddle"></a>
<a href="javascript:select_copy('copy');"><img src="<?=$board_skin_path?>/img/btn_select_copy.gif" border="0" align="absmiddle"></a>
<a href="javascript:select_copy('move');"><img src="<?=$board_skin_path?>/img/btn_select_move.gif" border="0" align="absmiddle"></a>
<? } ?>
</td>
</tr>
</table> -->
</td></tr></table>
<script language="JavaScript">
if ("<?=$sca?>") document.fcategory.sca.value = "<?=$sca?>";
if ("<?=$stx?>") {
document.fsearch.sfl.value = "<?=$sfl?>";
document.fsearch.sop.value = "<?=$sop?>";
}
</script>
<? if ($is_checkbox) { ?>
<script language="JavaScript">
function all_checked(sw)
{
var f = document.fboardlist;
for (var i=0; i<f.length; i++) {
if (f.elements[i].name == "chk_wr_id[]")
f.elements[i].checked = sw;
}
}
function check_confirm(str)
{
var f = document.fboardlist;
var chk_count = 0;
for (var i=0; i<f.length; i++) {
if (f.elements[i].name == "chk_wr_id[]" && f.elements[i].checked)
chk_count++;
}
if (!chk_count) {
alert(str + "할 게시물을 하나 이상 선택하세요.");
return false;
}
return true;
}
// 선택한 게시물 삭제
function select_delete()
{
var f = document.fboardlist;
str = "삭제";
if (!check_confirm(str))
return;
if (!confirm("선택한 게시물을 정말 "+str+" 하시겠습니까?\n\n한번 "+str+"한 자료는 복구할 수 없습니다"))
return;
f.action = "./delete_all.php";
f.submit();
}
// 선택한 게시물 복사 및 이동
function select_copy(sw)
{
var f = document.fboardlist;
if (sw == "copy")
str = "복사";
else
str = "이동";
if (!check_confirm(str))
return;
var sub_win = window.open("", "move", "left=50, top=50, width=396, height=550, scrollbars=1");
f.sw.value = sw;
f.target = "move";
f.action = "./move.php";
f.submit();
}
</script>
<? } ?>
댓글 전체
<?
$ss_name = "ss_view_{$bo_table}_{$list[$i][wr_id]}";
session_register($ss_name);
$$ss_name = $HTTP_SESSION_VARS[$ss_name] = TRUE;
if($list[$i][file][0]) {
$down_link0 = "download.php?bo_table=" . $bo_table . "&wr_id=" . $list[$i][wr_id] . "&no=0";
echo "<a href='$down_link0'>";
echo "<img src='$board_skin_path/img/icon_file.gif' border='0'>";
echo "</a> ";
}
if($list[$i][file][1]) {
$down_link1 = "download.php?bo_table=" . $bo_table . "&wr_id=" . $list[$i][wr_id] . "&no=1";
echo "<a href='$down_link1'>";
echo "<img src='$board_skin_path/img/icon_file.gif' border='0'>";
echo "</a> ";
}
if($list[$i][file][2]) {
$down_link2 = "download.php?bo_table=" . $bo_table . "&wr_id=" . $list[$i][wr_id] . "&no=2";
echo "<a href='$down_link2'>";
echo "<img src='$board_skin_path/img/icon_file.gif' border='0'>";
echo "</a> ";
}
if($list[$i][file][3]) {
$down_link3 = "download.php?bo_table=" . $bo_table . "&wr_id=" . $list[$i][wr_id] . "&no=3";
echo "<a href='$down_link3'>";
echo "<img src='$board_skin_path/img/icon_file.gif' border='0'>";
echo "</a> ";
}
if($list[$i][file][4]) {
$down_link4 = "download.php?bo_table=" . $bo_table . "&wr_id=" . $list[$i][wr_id] . "&no=4";
echo "<a href='$down_link4'>";
echo "<img src='$board_skin_path/img/icon_file.gif' border='0'>";
echo "</a> ";
}
?>
</td>
학교에 적용중인 list.skin.php 소스중일부인데요
안돼시면
따로따로 넣어줘보세요
<?
$ss_name = "ss_view_{$bo_table}_{$list[$i][wr_id]}";
session_register($ss_name);
$$ss_name = $HTTP_SESSION_VARS[$ss_name] = TRUE;
if($list[$i][file][0]) {
$down_link0 = "download.php?bo_table=" . $bo_table . "&wr_id=" . $list[$i][wr_id] . "&no=0";
echo "<a href='$down_link0'>";
echo "1번파일링크";
echo "</a>";
}
?>
<?
$ss_name = "ss_view_{$bo_table}_{$list[$i][wr_id]}";
session_register($ss_name);
$$ss_name = $HTTP_SESSION_VARS[$ss_name] = TRUE;
if($list[$i][file][1]) {
$down_link1 = "download.php?bo_table=" . $bo_table . "&wr_id=" . $list[$i][wr_id] . "&no=1";
echo "<a href='$down_link1'>";
echo "2번파일링크";
echo "</a>";
}
?>
말씀해주신대로 했는데도, 아무 것이 나타나지 않습니다.
분명 소스상에는 문제가 없는데, 왜 그런지 정말 모르겠습니다.
리스트에 하나씩만 교수소개가 나오게 했는데, 그것 때문은 아닌 것 같습니다.
아... 빨리 해결해야 하는데 큰일입니다.
빠른 답변 진심으로 감사드립니다.
$link = cut_str($list[$i][wr_link1], 70);
//$homepageurl="<a href='{$list[$i][wr_link1]}' target=_blank>{$link}</a>";
//$homepageurl="<a href='http://www.cuins.co.kr' target=_blank>";
// 추가라인 //////
$ss_name = "ss_view_{$bo_table}_{$list[$i][wr_id]}";
session_register($ss_name);
$$ss_name = $HTTP_SESSION_VARS[$ss_name] = TRUE;
if($list[$i][file][0]) {
$down_link0 = "download.php?bo_table=" . $bo_table . "&wr_id=" . $list[$i][wr_id] . "&no=0";
}
if($list[$i][file][1]) {
$down_link1 = "download.php?bo_table=" . $bo_table . "&wr_id=" . $list[$i][wr_id] . "&no=1";
}
// 추가라인 //////
그리고 밑으려 내려와서 링크걸곳에
<a href={$down_link0}>1번파일링크</a>
<a href={$down_link1}>2번파일링크</a>
이렇게 해주세요 아래는 적용한 소스입니다.
<?
if (!defined("_GNUBOARD_")) exit; // 개별 페이지 접근 불가
?>
<style>
/* line_style */
.h1_gray_line {height:1px; background-color:#e7e7e7;}
/* Default Type */
*{line-height:18px;}
</style>
<table width="<?=$width?>" align="center" cellpadding="0" cellspcing="0" bgcolor="#FFFFFF"><tr><td>
<!-- 여백 --><!-- <table width="100%" cellspacing="0" cellpadding="0"><tr><td height="5"></td></tr></table> -->
<table width="100%" cellspacing="0" cellpadding="0" border=0>
<form name="fboardlist" method="post">
<input type="hidden" name="bo_table" value="<?=$bo_table?>">
<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="sw" value="">
<!-- <? if ($is_admin) { ?><tr><td height=30 colspan='<?=$board[bo_gallery_cols]?>' style='padding-left:20px;'><INPUT onclick="if (this.checked) all_checked(true); else all_checked(false);" type=checkbox> 전체선택</td></tr><? } ?> -->
<tr>
<?
for ($i=0; $i<count($list); $i++)
{
$homepageurl="";
$_datetime=$list[$i][datetime2];
$_hit=$list[$i][wr_hit];
$title = "클릭하시면 해당 사이트로 이동합니다.";
//$content = cut_str(get_text($list[$i][wr_content]), 80);
$content = $list[$i][wr_content];
$img = "$g4[path]/data/file/$bo_table/".urlencode($list[$i][file][0][file]);
if (!file_exists($img) || !$list[$i][file][0][file])
$img = "$board_skin_path/img/photo_noimg.gif";
$href = "$g4[bbs_path]/board.php?bo_table=$bo_table&wr_id={$list[$i][wr_id]}&no=1";
//$view_href = "";
//if ($is_admin)
$view_href = "<a href='$g4[bbs_path]/board.php?bo_table=$bo_table&wr_id={$list[$i][wr_id]}'>";
$checkbox = "";
if ($is_checkbox)
$checkbox = "<input type=checkbox name=chk_wr_id[] value='{$list[$i][wr_id]}'>";
$link = cut_str($list[$i][wr_link1], 70);
//$homepageurl="<a href='{$list[$i][wr_link1]}' target=_blank>{$link}</a>";
//$homepageurl="<a href='http://www.cuins.co.kr' target=_blank>";
/////////////////////////////////////////////////////////////////////
$ss_name = "ss_view_{$bo_table}_{$list[$i][wr_id]}";
session_register($ss_name);
$$ss_name = $HTTP_SESSION_VARS[$ss_name] = TRUE;
if($list[$i][file][0]) {
$down_link0 = "download.php?bo_table=" . $bo_table . "&wr_id=" . $list[$i][wr_id] . "&no=0";
}
if($list[$i][file][1]) {
$down_link1 = "download.php?bo_table=" . $bo_table . "&wr_id=" . $list[$i][wr_id] . "&no=1";
}
/////////////////////////////////////////////////////////////////////
$wr_guide = nl2br(cut_str($list[$i][wr_3],250));
$tr = "";
if ($i && $i%$board[bo_gallery_cols]==0)
$tr = "</tr><tr>";
echo "$tr";
if ($is_checkbox) { $admin_mod="<a href='$g4[bbs_path]/write.php?w=u&bo_table=$bo_table&wr_id={$list[$i][wr_id]}'>"; }
echo <<<HEREDOC
<td width="{$td_width}%" valign="top" align="center">
<BR>
<TABLE cellSpacing=0 cellPadding=0 width=660 align=center border=0>
<TR>
<TD width="13%" rowSpan=2><IMG height=25 src="../inc/img/dbs_faculty/titlebar.gif" width=136></TD>
<TD align=right>Home > DBS MBA > Faculty Profiles</TD></TR>
<TR>
<TD class=h1_gray_line></TD>
</TR>
</TABLE>
<BR>
<table width='660' border='0' cellspacing='0' cellpadding='2'>
<tr>
<td align='center' valign='top'>
<table width="100%" border="0" cellpadding="0" cellspacing="1" bgcolor="e8e8e8">
<tr>
<td bgcolor="ffffff">
<table width="100%" border="0" cellpadding="0" cellspacing="1">
<tr>
<td bgcolor="f0f0f0" style="padding:7px;">
<table width="100%" border="0" cellpadding="0" cellspacing="1" bgcolor="ffffff">
<tr>
<td>
{$admin_mod}<img src='{$img}' width='190' height='217' border='0'></a><BR></td>
<td width="20"></td>
<td valign="middle">
<table width='430' border='0' cellspacing='0' cellpadding='2'>
<tr><td><table border="0" width="100%" cellpadding="1" cellspacing="1" height='25'><tr><td width="80" bgcolor="#EFEDED" align="center">성 & amp;nbsp;명</td><td width="10"> </td><td>{$list[$i][subject]}</td></tr></table></td></tr>
<tr><td height='1' bgcolor='#f0f0f0'></td></tr>
<tr><td><table border="0" width="100%" cellpadding="1" cellspacing="1" height='25'><tr><td width="80" bgcolor="#EFEDED" align="center">직 & amp;nbsp;위</td><td width="10"> </td><td>{$list[$i][wr_1]}</td></tr></table></td></tr>
<tr><td height='1' bgcolor='#f0f0f0'></td></tr>
<tr><td><table border="0" width="100%" cellpadding="1" cellspacing="1" height='25'><tr><td width="80" bgcolor="#EFEDED" align="center">연 구 실</td><td width="10"> </td><td>{$list[$i][wr_2]}</td></tr></table></td></tr>
<tr><td height='1' bgcolor='#f0f0f0'></td></tr>
<tr><td><table border="0" width="100%" cellpadding="1" cellspacing="1" height='25'><tr><td width="80" bgcolor="#EFEDED" align="center">교내전화</td><td width="10"> </td><td>{$list[$i][wr_3]}</td></tr></table></td></tr>
<tr><td height='1' bgcolor='#f0f0f0'></td></tr>
<tr><td><table border="0" width="100%" cellpadding="1" cellspacing="1" height='25'><tr><td width="80" bgcolor="#EFEDED" align="center">이 메 일</td><td width="10"> </td><td>{$list[$i][wr_link1]}</td></tr></table></td></tr>
<tr><td height='1' bgcolor='#f0f0f0'></td></tr>
<tr><td><table border="0" width="100%" cellpadding="1" cellspacing="1" height='25'><tr><td width="80" bgcolor="#EFEDED" align="center">연구분야</td><td width="10"> </td><td>{$list[$i][wr_4]}</td></tr></table></td></tr>
<tr><td height='1' bgcolor='#f0f0f0'></td></tr>
<tr><td><table border="0" width="100%" cellpadding="1" cellspacing="1" height='25'><tr><td width="80" bgcolor="#EFEDED" align="center">강의분야</td><td width="10"> </td><td>{$list[$i][wr_5]}</td></tr></table></td></tr>
<tr><td height='1' bgcolor='#f0f0f0'></td></tr>
<tr><td>
<a href={$down_link0}>1번파일링크</a>
<a href={$down_link1}>2번파일링크</a>
</td></tr>
<tr><td height='1' bgcolor='#f0f0f0'></td></tr>
</table>
</td>
</tr>
</table>
</td>
</tr>
</table>
</td>
</tr>
</table>
</td>
</tr>
<tr>
<td valign="top" width="100%">
<table align="center" cellpadding="5" cellspacing="1" width="100%">
<tr>
<td>{$list[$i][wr_content]}</td>
</tr>
</table>
</td>
</tr>
</table>
<br>
</td>
HEREDOC;
}
// 나머지 td 를 채운다.
if (($cnt = $i%$list_mod) != 0)
for ($k=$cnt; $k<$list_mod; $k++)
echo "<td> </td>\n";
if ($i == 0)
echo "<td colspan='$board[bo_gallery_cols]' height=50 align=center>등록된 정보가 없습니다.</td>";
?>
</form>
</tr>
</table>
<!-- <table width="100%" border="0" cellspacing="0" cellpadding="0"><tr><td height="1" width="100%" bgcolor="#CCCCCC"></td></tr></table> -->
<!-- <table width="100%" cellspacing="0" cellpadding="0">
<tr>
<td align="center" valign="middle">
<table width="500" border="0" cellspacing="0" cellpadding="0">
<tr>
<td width="100%" align="center">
<? if ($prev_part_href) { echo "<a href='$prev_part_href'><img src='$board_skin_path/img/btn_search_prev.gif' width=50 height=20 border=0 align=absmiddle title='이전검색'></a>"; } ?>
<?
// 기본으로 넘어오는 페이지를 아래와 같이 변환하여 이미지로도 출력할 수 있습니다.
//echo $write_pages;
$write_pages = str_replace("처음", "<img src='$board_skin_path/img/begin.gif' border='0' align='absmiddle' title='처음'>", $write_pages);
$write_pages = str_replace("이전", "<img src='$board_skin_path/img/prev.gif' border='0' align='absmiddle' title='이전'>", $write_pages);
$write_pages = str_replace("다음", "<img src='$board_skin_path/img/next.gif' border='0' align='absmiddle' title='다음'>", $write_pages);
$write_pages = str_replace("맨끝", "<img src='$board_skin_path/img/end.gif' border='0' align='absmiddle' title='맨끝'>", $write_pages);
$write_pages = preg_replace("/<span>([0-9]*)<\/span>/", "<font style=\"font-family:돋움; font-size:9pt; color:#797979\">$1</font>", $write_pages);
$write_pages = preg_replace("/<b>([0-9]*)<\/b>/", "<font style=\"font-family:돋움; font-size:9pt; color:orange;\">$1</font>", $write_pages);
?>
<strong><?=$write_pages?></strong>
<? if ($next_part_href) { echo "<a href='$next_part_href'><img src='$board_skin_path/img/btn_search_next.gif' width=50 height=20 border=0 align=absmiddle title='다음검색'></a>"; } ?>
</td>
</tr>
</table>
</td>
</tr>
</table> -->
<!-- <table width="100%" cellspacing="0" cellpadding="0">
<tr align="left" valign="middle">
<td width="50%" height="40">
<? if ($list_href) { ?><a href="<?=$list_href?>"><img src="<?=$board_skin_path?>/img/btn_list.gif" border="0" align="absmiddle"></a><? } ?>
<? if ($write_href) { ?><a href="<?=$write_href?>"><img src="<?=$board_skin_path?>/img/btn_write.gif" border="0" align="absmiddle"></a><? } ?>
<? if ($is_checkbox) { ?>
<a href="javascript:select_delete();"><img src="<?=$board_skin_path?>/img/btn_select_delete.gif" border="0" align="absmiddle"></a>
<a href="javascript:select_copy('copy');"><img src="<?=$board_skin_path?>/img/btn_select_copy.gif" border="0" align="absmiddle"></a>
<a href="javascript:select_copy('move');"><img src="<?=$board_skin_path?>/img/btn_select_move.gif" border="0" align="absmiddle"></a>
<? } ?>
</td>
</tr>
</table> -->
</td></tr></table>
<script language="Javascript">
if ("<?=$sca?>") document.fcategory.sca.value = "<?=$sca?>";
if ("<?=$stx?>") {
document.fsearch.sfl.value = "<?=$sfl?>";
document.fsearch.sop.value = "<?=$sop?>";
}
</script>
<? if ($is_checkbox) { ?>
<script language="Javascript">
function all_checked(sw)
{
var f = document.fboardlist;
for (var i=0; i<f.length; i++) {
if (f.elements[i].name == "chk_wr_id[]")
f.elements[i].checked = sw;
}
}
function check_confirm(str)
{
var f = document.fboardlist;
var chk_count = 0;
for (var i=0; i<f.length; i++) {
if (f.elements[i].name == "chk_wr_id[]" && f.elements[i].checked)
chk_count++;
}
if (!chk_count) {
alert(str + "할 게시물을 하나 이상 선택하세요.");
return false;
}
return true;
}
// 선택한 게시물 삭제
function select_delete()
{
var f = document.fboardlist;
str = "삭제";
if (!check_confirm(str))
return;
if (!confirm("선택한 게시물을 정말 "+str+" 하시겠습니까?\n\n한번 "+str+"한 자료는 복구할 수 없습니다"))
return;
f.action = "./delete_all.php";
f.submit();
}
// 선택한 게시물 복사 및 이동
function select_copy(sw)
{
var f = document.fboardlist;
if (sw == "copy")
str = "복사";
else
str = "이동";
if (!check_confirm(str))
return;
var sub_win = window.open("", "move", "left=50, top=50, width=396, height=550, scrollbars=1");
f.sw.value = sw;
f.target = "move";
f.action = "./move.php";
f.submit();
}
</script>
<? } ?>
<scRIPT language=javascript>AC_FL_RunContent = 0;</scRIPT> <scRIPT language=javascript src="../js/AC_RunActiveContent.js"></scRIPT> <scRIPT language=javascript> if (AC_FL_RunContent == 0) { alert('This page requires AC_RunActiveContent.js.'); } else { AC_FL_RunContent( 'codebase', 'http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=9,0,0,0', 'width', '185', 'height', '75', 'src', 'recommend_bt', 'quality', 'high', 'pluginspage', 'http://www.macromedia.com/go/getflashplayer', 'align', 'middle', 'play', 'true', 'loop', 'true', 'scale', 'showall', 'wmode', 'window', 'devicefont', 'false', 'id', 'recommend_bt', 'bgcolor', '#ffffff', 'name', 'recommend_bt', 'menu', 'true', 'allowFullScreen', 'false', 'allowscriptAccess','sameDomain', 'movie', 'recommend_bt', 'salign', '', 'flashVars', 'bo_table=g4_tiptech&wr_id=711&good=nogood&good_name=추천& wr_good=1&view_token=14268467a4e8ac49b1f58d62c5b1e403' ); //end AC code } </scRIPT>
밤새 검색하며 고민했던 사항인데, 이렇게 친절하게 답변해 주시니, 몸둘 바를 모르겠습니다.
어떻게 감사의 표현을 해야 할지 모르겠습니다.
가끔 neue님의 홈페이지에 가서 팁을 얻고는 했는데 (정말 초보여서 봐도 잘 모릅니다)
이렇게 도움을 받게 되네요.
복 받으실겁니다.
좋은 하루 되십시오.
// 저도 무언가를 도와드려야 할텐데요...
2번 파일이 없을 때는... 1번 링크만 나오게 하려면 어떻게 해야 하죠?
ㅠㅠ
쪽지 잘 받았습니다. 꾸벅~