How to create below mentioned table structure in jquery/javascript:
<table>
<tr>
<td>
one
</td>
<td>
two
</td>
<td>
three
</td>
</tr>
<tr>
<td>
single
</td>
</tr>
<tr>
<td>
one
</td>
<td>
two
</td>
<td>
three
</td>
</tr>
<tr>
<td>
single
</td>
</tr>
</table>
i.e. alternate row is having 3/ 1 cols.
This should suffice:
Check out the JSFiddle: http://jsfiddle.net/ZbJ3v/
This, of course doesn’t add in your “one” “two”, etc (I just have ‘a’ to denote the structure) but I assumed from your question that you just wanted the structure.
Edit for comment below. The loop block would look something like:
Avaliable on this jsfiddle: http://jsfiddle.net/WPJ5q/