grabit 0 Newbie Poster

Hi Folks

I have a shopping cart with an array of structures to hold the cart contents.
Wot i want to do is get a list of the contents of the cart contents and then use that list to repopulate the "order" page so it doesnt show any of the existing items in the array.
This will stop them "double ordering" items that are already in the cart array;

My code from the order page is below. This code is at the bottom of the "order" page and adds the ordered items to the cart

<cfif IsDefined("submit")>
<!---<cfset Temp = ArrayClear(session.app_shoppingcart)>
ADD CHOSEN ITEMS TO SHOPPING CART ARRAY--->
<!--- loop over the list of form variables --->
<cfloop list="#fieldnames#" delimiters="," index="i">
<!--- could this be an item that might have been ordered (starts with q_ ) --->
<cfif left(i, 2) is 'Q_'>
<cfset thisQuantity=Evaluate(#i#)>
<!--- has a value -- this item has been ordered --->
<cfif thisQuantity is not ''>
<cfset thisID = ListGetAt(i, 2, "_")>
<cfquery name="addtocart" datasource="#dsn#">
SELECT ID, category, variety, price
FROM celestialstock
WHERE ID = #thisID#
</cfquery>
<cfoutput>
<cfset temp = arrayAppend(session.app_shoppingCart, structNew())>
<cfset session.app_shoppingcart[arrayLen(session.app_shoppingcart)].ID = #thisID#>
<cfset session.app_shoppingcart[arrayLen(session.app_shoppingcart)].quantity = #thisquantity#>
<cfset session.app_shoppingcart[arrayLen(session.app_shoppingcart)].category = #addtocart.category#>
<cfset session.app_shoppingcart[arrayLen(session.app_shoppingcart)].variety = #addtocart.variety#>
<cfset session.app_shoppingcart[arrayLen(session.app_shoppingcart)].price = #addtocart.price#>
</cfoutput>
</cfif>
</cfif>
</cfloop>
<cflocation url="cartContents.cfm">
</cfif>
<!---FINISH ADDING TO CART ARRAY ROUTINE


ANY help would be appreciated
cheer and thanks in advance
Grabit