Right this really is a high level question about creating shopping carts and intergrating with Paypal.
I have an online shop at the moment that has all the product in a DB with categories etc etc. The site currently just pulls the details of the product from the DB and i put these details into a button that then uses the paypal shopping cart. Now we are ready to integrate this fully into paypal.
I am have some ideas about how to do this so here goes....
Firstly i was planning on creating a new table called tblCart and creating some sort of unique session variable for a customer when they add the first product to a cart then use the same session variable each time after that. This would create the online cart that on the site. From this i would then have a checkout option that transferred the entire cart details into an tblOrders and would then create a page to get the user to fill in their personal details (name, address, email, phone etc) and this would get populated into my tblCustomers and the new customer ID added into my tblOrders.
Once this customer has entered their personal detials the checkout option is displayed which will take them to the paypal payments page when they enter their credit/debit card details and make the payment, i then use IPN to send a message back to my server with the order number in say a querystring which i then upload the order record to status completed or pament ok or something along those lines. This would then let me log into an admin panel and see all the orders which have been paid ok and pick/pack them and ship them, marking the order as dispatched along the way. I am ok with moveing the data around and manipulating it once i get the payment confirm back.
Does this seem like a logical flow or have i totally missed a the point and am going in the wrong direction.
Once i know am thinking about this correctly then i will start to progress and will ask further questions along the way on a more technical level.