问个简单smarty模板问题,谢谢
这块模板是商城显示一行一列的商品,怎么改为一行显示两列或四列的方式,我是初手谢谢
<div class="content-div">
<!-- {if $category > 0} -->
<form name="compareForm" action="compare.php" method="post" onSubmit="return compareGoods(this);">
<!-- {/if} -->
<!--{foreach from=$goods_list item=goods}-->
<table border="0" cellpadding="5" cellspacing="1" class="goods-list">
<tr>
<td width="35%" align="center"><!-- {if $category > 0} -->
<input name="goods[]" type="checkbox" id="goods[]" value="{$goods.goods_id}" style="vertical-align: middle" />
<!-- {/if} -->
<a href="{$goods.url}"><img src="{$goods.goods_thumb}" alt="{$goods.goods_name}" border="0" style="vertical-align: middle" /></a></td>
<td><a href="{$goods.url}"><strong>{$goods.goods_name}</strong></a><br />
{$goods.goods_brief}<br />
<!-- {if $show_marketprice} -->
{$lang.market_price}<span class="market-price">{$goods.market_price}</span>
<!-- {/if} -->
<!--{if $goods.promote_price neq "" } -->
{$lang.promote_price}<span class="goods-price">{$goods.promote_price}</span>
<!--{else}-->
{$lang.shop_price}<span class="goods-price">{$goods.shop_price}</span>
<!--{/if}-->
<div class="addto_cart"><a href="javascript:collect({$goods.goods_id});"><img src="../images/collect.gif" alt="{$lang.collect}" width="69" height="19" /></a> <a href="javascript:addToCart({$goods.goods_id})"><img src="../images/add_cart.gif" alt="{$lang.add_to_cart}" width="80" height="19" /></a></div></td>
</tr>
</table>
<!--{/foreach}-->
<div align="center">
<!-- {if $category > 0} -->
<input name="compareButton" type="submit" value="{$lang.button_compare}" />
<!-- {/if} -->
</div>
<!-- {if $category > 0} -->
</form>
<!-- {/if} -->
</div>