Jump to content

Checkout as guest


vinpkl

Recommended Posts

Hi

I have an old ecommerce website in which all queries are based on LOGIN ID.

select * from user_table where user login id = '$loginid'

Now i have a requirement of creating "CHECKOUT AS GUEST" feature.

So should I create TWO separate database tables for Member and Guest.

OR Single table for both.

And Then on what basis shall i do the queries.

So that my queries should work in both case, whether user is a MEMBER or a GUEST.

Thanks
Vineet
 
Link to comment
https://forums.phpfreaks.com/topic/295904-checkout-as-guest/
Share on other sites

To add to mac's answer, your user table should allow for several different types of users ('member', 'guest') and at that point all you have to focus on is the differences in things like login/logout and checkout behavior between the types, and methods to convert guests to members.

 

You will find that you generate many basically empty guest accounts, but a cron job that looks for accounts with incomplete orders older than a certain age, which then deletes the cart and guest account is easy enough to code.

Link to comment
https://forums.phpfreaks.com/topic/295904-checkout-as-guest/#findComment-1510559
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.