Hello,
Further to my post yesterday about cookies being retrieved in a different order using client side JS compared to Vbscript.
This is becoming a nightmare and I wonder if anyone has an idea.
The person doesn't want to use a database, despite all the obvious advantages...sigh...extra cost for hosting is a problem it seems.
When a customer places an order via the cart I have written I want to be able to give them to opportunity of just submitting the same order when they return.
To elaborate, the product is contact lenses - when someone places an order they have to provide a bunch of information based on the prescription. There are 22 values per pair of lenses that need to be saved and recalled plus their contact and optometrist details (another 23 values)
Setting a cookie is no problem, the problem is that the order of key/value pairs ends up in a mess compared to when it is written. There is no way I can assume that the 10th value written is the 10th value retrieved, they are all jumbled up.
Parsing it using string comparisons will work, especially easy if only one order, but if they order say 5 pairs of lenses and I have over 100 values to save and then recall, it becomes a real issue, prone to error.
I know, I know, if it was a db it would be a cinch, but it isn't.
Does anyone have any thoughts on this that might steer me towards a solution?
Steve Davis
hey.you@hahaha.com.au
Further to my post yesterday about cookies being retrieved in a different order using client side JS compared to Vbscript.
This is becoming a nightmare and I wonder if anyone has an idea.
The person doesn't want to use a database, despite all the obvious advantages...sigh...extra cost for hosting is a problem it seems.
When a customer places an order via the cart I have written I want to be able to give them to opportunity of just submitting the same order when they return.
To elaborate, the product is contact lenses - when someone places an order they have to provide a bunch of information based on the prescription. There are 22 values per pair of lenses that need to be saved and recalled plus their contact and optometrist details (another 23 values)
Setting a cookie is no problem, the problem is that the order of key/value pairs ends up in a mess compared to when it is written. There is no way I can assume that the 10th value written is the 10th value retrieved, they are all jumbled up.
Parsing it using string comparisons will work, especially easy if only one order, but if they order say 5 pairs of lenses and I have over 100 values to save and then recall, it becomes a real issue, prone to error.
I know, I know, if it was a db it would be a cinch, but it isn't.
Does anyone have any thoughts on this that might steer me towards a solution?
Steve Davis
hey.you@hahaha.com.au