说我有一个清单
e.g.
apple
car
bin
如何让它在表格中填充而不是垂直填充,所以它在表格中看起来像这样:
apple car bin
使用的代码只是重复整个行的列表的每个条目,代码如下:
<body>
<div metal:fill-slot="main">
<h1>List of Species in the Database</h1>
<table border="0" width="100%">
<tr tal:repeat="records container/Query_Species">
<td tal:content="records/gene_bank_species">Species</td>
<td tal:content="records/gene_bank_species">Species</td>
</tr>
</div>
</body>
答案 0 :(得分:0)
<table border="0" width="100%">
<tr tal:repeat="records container/Query_Species">
<td tal:content="records/gene_bank_species">Species</td>
</tr>
<tr tal:repeat="records container/Query_Species">
<td tal:content="records/gene_bank_species">Species</td>
</tr>
</table>