Ok please forgive me my brain is fried, I am sure this is a easy one but I can't seem to find it in the archives.
If I have a form that has a bunch of reapeating fields and I want it to only print how many the user has requested, how I can I do this? For example say the user says he has 7 stores, which I am storing as a variable. I only want to print 7 fields and make a new line at after 5 fields how would I do that?
it has to be some kind of foreach stament that will print a <tr>, <td>, <input field>, </td>, </tr>
NOTE: up to five <td> and <input fields> per line. Then break to a new <tr> if the stores field is greater than 5, or have three lines if greater than 10. And so on.
I would like to do this without a crapton of if statements which is the wrong way of course. Please help!!
Thanks in advance. Any advice would be great, it may spark my brain into working again.