[도움] 최신글 두줄 정열 도움 부탁드립니다.. 정보
[도움] 최신글 두줄 정열 도움 부탁드립니다..본문
최신글을 두줄 정열 하고 싶은데 혹시 방법이있을까요?
그러니깐 가로 3개 넘으면 한칸 내려야 다음줄 출력....
<?
if (!defined("_GNUBOARD_")) exit; // 개별 페이지 접근 불가
?>
<table width=100% cellpadding=0 cellspacing=0 border="0">
<tr>
<?
for ($i=0; $i<count($list); $i++) {
$list[$i]['content']=eregi_replace(" "," ",$list[$i]['content']);
if($list[$i][file][0][file]) {
$file = "<img src='".$list[$i][file][0][path] .'/'. $list[$i][file][0][file]."' align=absmiddle width=\"226\" height=\"108\"border=\"0\">";
} else {
$file="";
}
?>
<td align=center width="39" height="167">
<table border="1" cellspacing="0" bordercolordark="white" bordercolorlight="black" width="218">
<tr>
<td width="212">
<table width="202" cellspacing="0" bordercolordark="white" bordercolorlight="black" cellpadding="0">
<tr>
<td width="202" height="34" style="border:0px solid #DDDDDD">
<p align="left"> <?=$list[$i]['subject']?></p>
</td>
</tr>
<tr>
<td width="202" height="29" style="border-width:0px; border-color:rgb(221,221,221); border-style:solid;"> <p><a href="<?=$list[$i]['href']?>"><?=$file?></a></p>
</td>
</tr>
<tr>
<td width="202" height="110" style="border-width:0px; border-color:rgb(221,221,221); border-style:solid;">
<table cellpadding="0" cellspacing="0">
<tr>
<td width="185">
<table cellpadding="0" cellspacing="0" width="226" bgcolor="#EEEEEE" align="center">
<tr align="center" valign="middle">
<td width="226" bgcolor="#EEEEEE" height="30" align="center" valign="middle">
<p align="left"><font color="#999999"><span style='color:#666666'><B><img src="http://freedogs.cafe24.com/b/images/1.jpg" width="91" height="16" border="0" align="middle"><?=$list[$i]['subject']?></a></font></p>
</td>
</tr>
<tr align="center" valign="middle">
<td width="226" bgcolor="#EEEEEE" height="30" align="center" valign="middle">
<p align="left"><font color="#999999"><span style='color:#666666'><B><img src="http://freedogs.cafe24.com/b/images/2.jpg" width="91" height="16" border="0" align="middle"><?=$list[$i]['wr_5']?></a></font></p>
</td>
</tr>
<tr align="center" valign="middle">
<td width="226" bgcolor="#EEEEEE" height="30" align="center" valign="middle">
<p align="left"><font color="#999999"><span style='color:#666666'><B><img src="http://freedogs.cafe24.com/b/images/3.jpg" width="91" height="16" border="0" align="middle"><?=$list[$i]['wr_1']?></a></font></p>
</td>
</tr>
<tr align="center" valign="middle">
<td width="226" bgcolor="#EEEEEE" height="30" align="center" valign="middle">
<p align="left"><font color="#999999"><span style='color:#666666'><B><img src="http://freedogs.cafe24.com/b/images/4.jpg" width="91" height="16" border="0" align="middle"><?=$list[$i]['wr_3']?></a></font></p>
</td>
</tr>
<tr align="center" valign="middle">
<td width="226" bgcolor="#EEEEEE" height="30" align="center" valign="middle">
<p align="left"><font color="#999999"><span style='color:#666666'><B><img src="http://freedogs.cafe24.com/b/images/5.jpg" width="91" height="16" border="0" align="middle"><?=$list[$i]['wr_8']?></a></font></p>
</td>
</tr>
</table></td>
</tr>
</table>
</td>
</tr>
</table></td>
</tr>
</table>
</td>
<?if($i!=count($list)-1) { ?>
<td width="1038" height="167">
<p align="center"><img src="<?=$latest_skin_path?>/img/line_1.gif" border="0" align="absmiddle"></p>
</td>
<? } ?>
<? } ?>
</tr>
<? if (count($list) == 0) { ?><tr> <td colspan=4 align=center height=50 width="1131">
<p align="center"><font color=#6A6A6A>게시물이 없습니다.</a></p>
</td></tr><? } ?>
</table>
그러니깐 가로 3개 넘으면 한칸 내려야 다음줄 출력....
<?
if (!defined("_GNUBOARD_")) exit; // 개별 페이지 접근 불가
?>
<table width=100% cellpadding=0 cellspacing=0 border="0">
<tr>
<?
for ($i=0; $i<count($list); $i++) {
$list[$i]['content']=eregi_replace(" "," ",$list[$i]['content']);
if($list[$i][file][0][file]) {
$file = "<img src='".$list[$i][file][0][path] .'/'. $list[$i][file][0][file]."' align=absmiddle width=\"226\" height=\"108\"border=\"0\">";
} else {
$file="";
}
?>
<td align=center width="39" height="167">
<table border="1" cellspacing="0" bordercolordark="white" bordercolorlight="black" width="218">
<tr>
<td width="212">
<table width="202" cellspacing="0" bordercolordark="white" bordercolorlight="black" cellpadding="0">
<tr>
<td width="202" height="34" style="border:0px solid #DDDDDD">
<p align="left"> <?=$list[$i]['subject']?></p>
</td>
</tr>
<tr>
<td width="202" height="29" style="border-width:0px; border-color:rgb(221,221,221); border-style:solid;"> <p><a href="<?=$list[$i]['href']?>"><?=$file?></a></p>
</td>
</tr>
<tr>
<td width="202" height="110" style="border-width:0px; border-color:rgb(221,221,221); border-style:solid;">
<table cellpadding="0" cellspacing="0">
<tr>
<td width="185">
<table cellpadding="0" cellspacing="0" width="226" bgcolor="#EEEEEE" align="center">
<tr align="center" valign="middle">
<td width="226" bgcolor="#EEEEEE" height="30" align="center" valign="middle">
<p align="left"><font color="#999999"><span style='color:#666666'><B><img src="http://freedogs.cafe24.com/b/images/1.jpg" width="91" height="16" border="0" align="middle"><?=$list[$i]['subject']?></a></font></p>
</td>
</tr>
<tr align="center" valign="middle">
<td width="226" bgcolor="#EEEEEE" height="30" align="center" valign="middle">
<p align="left"><font color="#999999"><span style='color:#666666'><B><img src="http://freedogs.cafe24.com/b/images/2.jpg" width="91" height="16" border="0" align="middle"><?=$list[$i]['wr_5']?></a></font></p>
</td>
</tr>
<tr align="center" valign="middle">
<td width="226" bgcolor="#EEEEEE" height="30" align="center" valign="middle">
<p align="left"><font color="#999999"><span style='color:#666666'><B><img src="http://freedogs.cafe24.com/b/images/3.jpg" width="91" height="16" border="0" align="middle"><?=$list[$i]['wr_1']?></a></font></p>
</td>
</tr>
<tr align="center" valign="middle">
<td width="226" bgcolor="#EEEEEE" height="30" align="center" valign="middle">
<p align="left"><font color="#999999"><span style='color:#666666'><B><img src="http://freedogs.cafe24.com/b/images/4.jpg" width="91" height="16" border="0" align="middle"><?=$list[$i]['wr_3']?></a></font></p>
</td>
</tr>
<tr align="center" valign="middle">
<td width="226" bgcolor="#EEEEEE" height="30" align="center" valign="middle">
<p align="left"><font color="#999999"><span style='color:#666666'><B><img src="http://freedogs.cafe24.com/b/images/5.jpg" width="91" height="16" border="0" align="middle"><?=$list[$i]['wr_8']?></a></font></p>
</td>
</tr>
</table></td>
</tr>
</table>
</td>
</tr>
</table></td>
</tr>
</table>
</td>
<?if($i!=count($list)-1) { ?>
<td width="1038" height="167">
<p align="center"><img src="<?=$latest_skin_path?>/img/line_1.gif" border="0" align="absmiddle"></p>
</td>
<? } ?>
<? } ?>
</tr>
<? if (count($list) == 0) { ?><tr> <td colspan=4 align=center height=50 width="1131">
<p align="center"><font color=#6A6A6A>게시물이 없습니다.</a></p>
</td></tr><? } ?>
</table>
댓글 전체