我的 SQL查询是
select KS_U_meinv.ID,KS_U_meinv.Tid,KS_U_meinv.Title,KS_U_meinv.Adddate,KS_U_meinv.Hits,KS_U_meinv.TitleFontColor,KS_U_meinv.KS_shuliang,KS_User.UserName from KS_U_meinv,KS_User where tid in ({$CurrClassChildID}) order by adddate desc
循环是
<table cellSpacing=5 cellPadding=0 width=577 align=center bgColor=#f1f1ee border=0
<tr>
[loop=4]
<td align="center"><div>
<table width="135" height="100" border="1" cellpadding="0" cellspacing="0" bordercolor="#999999">
<tr>
<td width="165" valign="middle" bordercolor="#FFFFFF"><div align="center"><A title={$Field(Title,Text,0,,0,)} href="{$Field(ID,GetInfoUrl,110,1)}" target=_blank><IMG class=img2xp height=95 alt={$Field(Title,Text,0,,0,)} src="{$Field(Picurl,Text,0,,0,)}" width=125 border=0> <font color="{$Field(TitleFontColor,Text,0,...,0,)}">{$Field(Title,Text,14,,0,)}</font></A>
<div align="left"><span class="user">上传者:</span> <A href="http://u.youku.com/user_show/id_3255647.html" target="_blank" charset="100-013-2-1">{$Field(UserName,Text,0,...,0,)}</A>
<div align="left"><span class="user">点击率:</span> {$Field(Hits,Num,0,2)} </div>
<div align="left"><span class="hotimglink">图片数:</span> {$Field(KS_shuliang,Num,0,2)} </div>
</div>
<a href="{$Field(ID,GetInfoUrl,110,1)}" title="{$Field(Title,Text,14,...,0,)}" target="_blank"></a></div></td>
</tr>
</table>
<a href='{$Field(ID,GetInfoUrl,1,1)}' target="_blank"></a>
<div></div>
</div>
</td>
[/loop]
</tr>
<tr>
[loop=4]
<td align="center"><div>
<div><div>
<table width="135" height="100" border="1" cellpadding="0" cellspacing="0" bordercolor="#999999">
<tr>
<td width="165" valign="middle" bordercolor="#FFFFFF"><div align="center"><a title="{$Field(Title,Text,0,,0,)}" href="{$Field(ID,GetInfoUrl,110,1)}" target="_blank"><img class="img2xp" height="95" alt="{$Field(Title,Text,0,,0,)}" src="{$Field(Picurl,Text,0,,0,)}" width="125" border="0" /> <font color="{$Field(TitleFontColor,Text,0,...,0,)}">{$Field(Title,Text,14,,0,)}</font></a>
<div align="left"><span class="user">上传者:</span> <a href="http://u.youku.com/user_show/id_3255647.html" target="_blank" charset="100-013-2-1">{$Field(UserName,Text,0,...,0,)}</a>
<div align="left"><span class="user">点击率:</span> {$Field(Hits,Num,0,2)} </div>
<div align="left"><span class="hotimglink">图片数:</span> {$Field(KS_shuliang,Num,0,2)} </div>
</div>
<a href="{$Field(ID,GetInfoUrl,110,1)}" title="{$Field(Title,Text,14,...,0,)}" target="_blank"></a></div></td>
</tr>
</table>
</div>
</div>
<div></div>
</div>
</td>
[/loop]
</tr>
<tr>
[loop=4]
<td align="center"><div><div>
<div><div>
<table width="135" height="100" border="1" cellpadding="0" cellspacing="0" bordercolor="#999999">
<tr>
<td width="165" valign="middle" bordercolor="#FFFFFF"><div align="center"><a title="{$Field(Title,Text,0,,0,)}" href="{$Field(ID,GetInfoUrl,110,1)}" target="_blank"><img class="img2xp" height="95" alt="{$Field(Title,Text,0,,0,)}" src="{$Field(Picurl,Text,0,,0,)}" width="125" border="0" /> <font color="{$Field(TitleFontColor,Text,0,...,0,)}">{$Field(Title,Text,14,,0,)}</font></a>
<div align="left"><span class="user">上传者:</span> <a href="http://u.youku.com/user_show/id_3255647.html" target="_blank" charset="100-013-2-1">{$Field(UserName,Text,0,...,0,)}</a>
<div align="left"><span class="user">点击率:</span> {$Field(Hits,Num,0,2)} </div>
<div align="left"><span class="hotimglink">图片数:</span> {$Field(KS_shuliang,Num,0,2)} </div>
</div>
<a href="{$Field(ID,GetInfoUrl,110,1)}" title="{$Field(Title,Text,14,...,0,)}" target="_blank"></a></div></td>
</tr>
</table>
</div>
</div>
</div>
</div></td>
[/loop]
</tr>
<tr>
[loop=4]
<td align="center"><div><div><div><div>
<div><div>
<table width="135" height="100" border="1" cellpadding="0" cellspacing="0" bordercolor="#999999">
<tr>
<td width="165" valign="middle" bordercolor="#FFFFFF"><div align="center"><a title="{$Field(Title,Text,0,,0,)}" href="{$Field(ID,GetInfoUrl,110,1)}" target="_blank"><img class="img2xp" height="95" alt="{$Field(Title,Text,0,,0,)}" src="{$Field(Picurl,Text,0,,0,)}" width="125" border="0" /> <font color="{$Field(TitleFontColor,Text,0,...,0,)}">{$Field(Title,Text,14,,0,)}</font></a>
<div align="left"><span class="user">上传者:</span> <a href="http://u.youku.com/user_show/id_3255647.html" target="_blank" charset="100-013-2-1">{$Field(UserName,Text,0,...,0,)}</a>
<div align="left"><span class="user">点击率:</span> {$Field(Hits,Num,0,2)} </div>
<div align="left"><span class="hotimglink">图片数:</span> {$Field(KS_shuliang,Num,0,2)} </div>
</div>
<a href="{$Field(ID,GetInfoUrl,110,1)}" title="{$Field(Title,Text,14,...,0,)}" target="_blank"></a></div></td>
</tr>
</table>
</div>
</div>
</div>
</div>
</div>
</div>
</td>
[/loop]
</tr>
<tr>
[loop=4]
<td align="center"><div><div>
<div><div>
<table width="135" height="100" border="1" cellpadding="0" cellspacing="0" bordercolor="#999999">
<tr>
<td width="165" valign="middle" bordercolor="#FFFFFF"><div align="center"><a title="{$Field(Title,Text,0,,0,)}" href="{$Field(ID,GetInfoUrl,110,1)}" target="_blank"><img class="img2xp" height="95" alt="{$Field(Title,Text,0,,0,)}" src="{$Field(Picurl,Text,0,,0,)}" width="125" border="0" /> <font color="{$Field(TitleFontColor,Text,0,...,0,)}">{$Field(Title,Text,14,,0,)}</font></a>
<div align="left"><span class="user">上传者:</span> <a href="http://u.youku.com/user_show/id_3255647.html" target="_blank" charset="100-013-2-1">{$Field(UserName,Text,0,...,0,)}</a>
<div align="left"><span class="user">点击率:</span> {$Field(Hits,Num,0,2)} </div>
<div align="left"><span class="hotimglink">图片数:</span> {$Field(KS_shuliang,Num,0,2)} </div>
</div>
<a href="{$Field(ID,GetInfoUrl,110,1)}" title="{$Field(Title,Text,14,...,0,)}" target="_blank"></a></div></td>
</tr>
</table>
</div>
</div>
</div>
</div></td>
[/loop]
</tr>
</table>
结果出现的效果是 每个信息他产生2个一模一样的
此主题相关图片如下:未命名-1.gif
请求各位好心大爷帮助我 求您们啦 补充一下 明明是ADMIN发布一个文章 可是这样查询后 出现的是ADMIN和RXZ88092个人发表了这个图片
[此贴子已经被作者于2008-2-3 13:06:00编辑过]