The structure is as follows:
Code: Select all
$_SESSION['cart'][(productid)][(pricingoption)] = $qty;
Code: Select all
$_SESSION['cart'][4][3] = 1;
In my database i have a field where i can store the initial fields like so
"Name|Job Title|Telephone"
these are then exploded to create the text boxes like so
Code: Select all
$options = explode("|",$data->options);
foreach($options as $key=>$value){
#... GENERATE THE TEXT BOXES
}
This is where i'm stuck - how can i get these values and store them in the above cart? Even if i could store them as an array.
I should say that not every product will have options so this has to be dynamic.
If you need any more info please just ask.