Hi Everyone-

I am working on a registration page where people can specify additional meal 
tickets as a quantity. What I need to be able to do is take this information 
that is passed to form a variable called ProductID. I will pass this variable 
to a shopping cart to add the item to the cart. 

The variable needs to be in the format of "ProductID-Quantity".

The form looks similar to this

 <cfoutput query="getMeals">
  <cfset MealField = "Meal" & EventID & "Qty">
<tr<cfif (CurrentRow-1) mod 2> bgcolor="##F3F1ED"</cfif>>
  <input type="hidden" name="MealIDs" value="#EventID#">
  <td align="center">
    <input type="text" name="#MealField#" 
value="#IIf(isDefined("Session."&MealField),"Session."&MealField,0)#" size="2" 
maxlength="3"> x</td>
  <td>
    #Name#</td>
  <td>#DateFormat(Dte,"dddd mmmm d")#,
    #LCase(TimeFormat(StartT,"h:mmtt"))#-#LCase(TimeFormat(EndT,"h:mmtt"))#</td>
  <td>@ #DollarFormat(IIf(Session.Member,"CostMember","CostNonMember") + 
(confPriceAdd * isEarlyBird))# USD</td>
</tr>
</cfoutput>

Once this is submitted, I can get two lists one of the quantity and I query the 
database to get the product IDs of the meals. 

I am able to get two lists from this form.

Session.MealProductID: 4033,4031,4029
Session.MealsQtyList: 2,5,4

Is there anyway I can then take these two lists and create the following?

Session.Meals: 4033-2;4031-5;4029-4

Any advice would be appreciated. 

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Get involved in the latest ColdFusion discussions, product
development sharing, and articles on the Adobe Labs wiki.
http://labs/adobe.com/wiki/index.php/ColdFusion_8

Archive: 
http://www.houseoffusion.com/groups/CF-Newbie/message.cfm/messageid:3091
Subscription: http://www.houseoffusion.com/groups/CF-Newbie/subscribe.cfm
Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.15

Reply via email to