blondegeek
Baseband Member
- Messages
- 23
Hello! I'm trying to code up a handler for PayPal's IPN (Instant Payment Notification) feature. Since I'm going to be recieving information from a shopping cart and therefore multiple items, I need to make sure that I have a specific number of variables ready to accept the variables from PayPal. For example, if there are 4 different items from the shopping cart I need a variable to accept each:
So if num_cart_items equals 4 then I need:
How do I make this so it will add as many number specifc variables needed depending on the number of items in the shopping cart?
Thanks!
Code:
$num_cart_items =$_POST['num_cart_items']
So if num_cart_items equals 4 then I need:
Code:
$item_name1 = $_POST['item_name1'];
$item_name2 = $_POST['item_name2'];
$item_name3 = $_POST['item_name3'];
$item_name4 = $_POST['item_name4'];
How do I make this so it will add as many number specifc variables needed depending on the number of items in the shopping cart?
Thanks!