cr84net
Technical User
- Jan 16, 2003
- 2
I have a 3 field form that is multiplied by the number of items a person orders. If someone orders 3 items, 9 fields are displayed, if they order 4 then 12 fields are displayed etc.I am using a loop to create the fields and the code is like this (qty is an integer):
I have simplified the code for ease of discussion. My problem is I can't seem to get my head around how to properly process the input fields. Once posted, I would like to end up with the three fields that go together in a string like:
T1Line1 & T1Line2 & T1Line3
T2Line1 & T2Line2 & T2Line3
T3Line1 & T3Line2 & T3Line3
A line separator would be nice like:
T1Line1 & ~ & T1Line2 & ~ & T1Line3
Each string will be submitted to an access db along with the sku and ordernum . The line separator would be available so I can separate the lines when I retrieve them from the db.
Any ideas ?
Thank you, any help would be appreciated.
Code:
<input type=hidden name="sku" value="<%=sku%>" >
<input type=hidden name="qty" value="<%=qty%>" >
<input type=hidden name="ordernum" value="<%=eon%>" >
t= qty
z=1
Do While z<= t
<input type=text name="T<%=z%>Line1" size="30" >
<input type=text name="T<%=z%>Line2" size="30" >
<input type=text name="T<%=z%>Line3" size="30" >
z=z + 1
Loop
I have simplified the code for ease of discussion. My problem is I can't seem to get my head around how to properly process the input fields. Once posted, I would like to end up with the three fields that go together in a string like:
T1Line1 & T1Line2 & T1Line3
T2Line1 & T2Line2 & T2Line3
T3Line1 & T3Line2 & T3Line3
A line separator would be nice like:
T1Line1 & ~ & T1Line2 & ~ & T1Line3
Each string will be submitted to an access db along with the sku and ordernum . The line separator would be available so I can separate the lines when I retrieve them from the db.
Any ideas ?
Thank you, any help would be appreciated.