Prime Services Ltd wrote:
>
> "Isofarro" <spamblock DeleteThis @spamdetector.co.uk> wrote in message
> news:jpmcib.ie1.ln@sidious.isolani.co.uk...
>> Prime Services Ltd wrote:
>>
>> > I'm starting to look at the "add to cart" feature now and trying to
>> > come up with ways of making storing values for retreival in a cart.....
>> > I've been thinking of using cookies to do this, but not every browser
> has
>> > them enabled.....
>> > Has anyone got any alternative suggestions?
>>
>>
>> First, don't store actual information in the cookie. Just store a session
> id
>> which on the server allows you to retrieve the data from a database using
>> that session id.
>
> Yeah, I was just going to store the order code and quantity in the cookie,
> and retreive the rest of the information for the cart from the DB
Abstract it further than that. Store just a session ID in the cookie. The
order code and quantity is something that should be stored in a database.
> I had considered setting up anther DB to hold orders, which would get
> cleared out once the order was retreived, but I'm not sure if hsi is a
> good idea or not. Again, it woudl just hold the order code, quantity and
> users IP addy.
There isn't a consistent one-to-one mapping of users and IP address. that's
why you need a unique identifier like a session id.
One thousand people can all be using one IP address (proxy servers such as
ISPs, businesses and universities), and one visitor could be using six IP
addresses during his visit (AOL's load-balanced proxy servers).
--
Iso.
FAQs: <a style='text-decoration: underline;' href="http://html-faq.com" target="_blank">http://html-faq.com</a> <a style='text-decoration: underline;' href="http://alt-html.org" target="_blank">http://alt-html.org</a> <a style='text-decoration: underline;' href="http://allmyfaqs.com/" target="_blank">http://allmyfaqs.com/</a>
Recommended Hosting: <a style='text-decoration: underline;' href="http://www.affordablehost.com/" target="_blank">http://www.affordablehost.com/</a>
Web Standards: <a style='text-decoration: underline;' href="http://www.webstandards.org/" target="_blank">http://www.webstandards.org/</a><!-- ~MESSAGE_AFTER~ -->
>> Stay informed about: Shopping cart question