Topic: Creating tables through loops

Hi all,

                 Can anyone tell how to produce tables through loops.ie there will a table instantly on the page.If data got filled in that table an additional table with blank style have to be formed beneath the current table that data and the process will be repeated.

                                                                                                                    Thank You.

Re: Creating tables through loops

Not exactly sure what the question is..

You want a table to be on the page when the page is loaded, and if there is data in that table you would like another table to appear below it?

- Ben

Re: Creating tables through loops

Hi,

Thanks for your response.

First I like to post the code

<tr>
<td>
<%= options_from_collection_for_select(@asset, "id", "p_date")%>
</td>   

<td>
<%= options_from_collection_for_select(@asset, "id", "amount") %>
</td>   
           
<td>
<%= options_from_collection_for_select(@asset, "id", "posting") %>
</td>   

<td>
<%= options_from_collection_for_select(@asset, "id", "head") %>
</td>   
           
<td>
<%= options_from_collection_for_select(@asset, "id", "category")%>
</td>
   
<td>
<%= options_from_collection_for_select(@asset, "id", "narration") %>
</td>   
   
The data,s are all collected from another page and produced under
this <td></td>.so if I submit one data on another page the all
data,s just I submitted will be shown on this link.So no problem there.But if goes on with continuous submission the whole data,s
are produced under the same<td></td>(not in an vertical way,that is the problem)so that it views like a cluster of data,s and  looks  very untidy.so what I needed is that if the data is stored on the first<td></td> an another <td></td> have to be generated under the first one and the second data that I am submitting on another page have to viewed on the second <td></td>.Like that the process continous.... Hope you have got a better idea.
           
                                                                                    Thank You.