최근게시물을 두줄로 하려면 어느부분을 수정해야 할까요? 정보
최근게시물을 두줄로 하려면 어느부분을 수정해야 할까요?본문
현재 갤러리 형태의 최근게시물을 가로로 출력하고 있습니다.
게시물이 3개를 넘길경우 다음 줄로 (총 2줄까지만) 출력하고 싶은데 어디를 건드려야 할지 부탁드립니다.
<table width="499" cellspacing="0" cellpadding="0" bgcolor="#323232" 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]."' width=\"157\" height=\"130\" border=\"0\" align=\"center\">";
}
else
{
$file="";
}
?>
<td width="163" height="185" valign="top">
<table width="163" height="185" cellspacing="0" cellpadding="0" style="background:url(<?=$g4['path']?>/images/box_bg.png); background-repeat:no-repeat"">
<tr>
<td width="163" height="5" colspan="2"></td>
</tr>
<tr>
<td width="4" height="130"></td>
<td width="157" height="130">
<table width="157" height="130">
<tr>
<td .colspan='2'>
<a href="<?=$list[$i]['href']?>"><?=$file?></a>
</td>
<td width="4" height="130"></td>
</tr>
<tr>
<td width="163" height="5" colspan="3"></td>
</tr>
<tr>
<td width="4" height="46"></td>
<td width="157" height="46"></td>
<td width="4" height="46"></td>
</tr>
</table>
</td>
</tr>
</table>
</td>
<?
}
?>
<? if(!count($list))
{
?>
<td align=center height=30><font color=#6A6A6A>게시물이 없습니다.</a></td>
<?
}
?>
</tr>
</table>
게시물이 3개를 넘길경우 다음 줄로 (총 2줄까지만) 출력하고 싶은데 어디를 건드려야 할지 부탁드립니다.
<table width="499" cellspacing="0" cellpadding="0" bgcolor="#323232" 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]."' width=\"157\" height=\"130\" border=\"0\" align=\"center\">";
}
else
{
$file="";
}
?>
<td width="163" height="185" valign="top">
<table width="163" height="185" cellspacing="0" cellpadding="0" style="background:url(<?=$g4['path']?>/images/box_bg.png); background-repeat:no-repeat"">
<tr>
<td width="163" height="5" colspan="2"></td>
</tr>
<tr>
<td width="4" height="130"></td>
<td width="157" height="130">
<table width="157" height="130">
<tr>
<td .colspan='2'>
<a href="<?=$list[$i]['href']?>"><?=$file?></a>
</td>
<td width="4" height="130"></td>
</tr>
<tr>
<td width="163" height="5" colspan="3"></td>
</tr>
<tr>
<td width="4" height="46"></td>
<td width="157" height="46"></td>
<td width="4" height="46"></td>
</tr>
</table>
</td>
</tr>
</table>
</td>
<?
}
?>
<? if(!count($list))
{
?>
<td align=center height=30><font color=#6A6A6A>게시물이 없습니다.</a></td>
<?
}
?>
</tr>
</table>
( select a.* , ( select sum(co_count) as co_count from g4_qa_choose where mb_id=a.mb_id and bo_table = 'g4_qa' ) as q_co_count from `g4_write_g4_qa` a where wr_parent = '214696' and wr_8 != '' and wr_is_comment = 1 and CONVERT(wr_7, UNSIGNED) >= 5 group by wr_content having max(wr_7) order by CONVERT(wr_7, UNSIGNED) desc limit 3 )
1055 : Expression #1 of SELECT list is not in GROUP BY clause and contains nonaggregated column 'sir.a.wr_id' which is not functionally dependent on columns in GROUP BY clause; this is incompatible with sql_mode=only_full_group_by
error file : /15sir/bbs/board.php