Summary of the invention
Embodiment of the present invention proposition is a kind of adds the method for article to shopping cart, thus improves Consumer's Experience.
Embodiment of the present invention proposition is a kind of adds the system of article to shopping cart, thus improves Consumer's Experience.
The technical scheme of embodiment of the present invention is as follows:
Add the method for article to shopping cart, the method comprises:
Login user account number and the user encryption mark corresponding to described login user account number before before preserving in the biscuit (cookie) of browser;
When user does not log in purchase system and this has a selected item, from described cookie, obtain described login user account number before and correspond to the user encryption mark of described login user account number before, and to user present described before login user account number whether add this selected item to described login user before in the shopping cart of purchase system point out user, if, user encryption mark is sent to purchase system with identifying user identity legitimacy, and this selected item is added to described login user before at the shopping cart of purchase system after by checking, if not, then this selected item is added in described cookie.
Preferably, described user encryption mark comprises the inside account number of user in purchase system; Described identifying user identity legitimacy comprises:
Decipher described user encryption mark to obtain the inside account number of user in purchase system, when the inside account number of described user in purchase system and described before login user account number there is predetermined corresponding relation time, determine that user identity is legal; When the inside account number of described user in purchase system and described before login user account number not there is predetermined corresponding relation time, determine that user identity is illegal.
Preferably, described user encryption mark also comprises user's login time and user's signature.
Preferably, describedly add this selected item to described cookie and comprise:
During article before existing in cookie, this selected item is covered described before article; During article before not existing in cookie, this selected item is added in described cookie.
Preferably, the method also comprises: when user logs in purchase system, this selected item is added to this user in the shopping cart of purchase system; And
Send prompting to user, whether add the article be kept in described cookie to this user in the shopping cart of purchase system with reminding user; When user confirm as be time, the article be kept in described cookie are added to this user in the shopping cart of purchase system; When user confirms as no, do not add the article be kept in described cookie to this user in the shopping cart of purchase system.
Add the system of article to shopping cart, this system comprises:
Biscuit (cookie) storage unit, for login user account number before preservation in the biscuit (cookie) of browser and the user encryption mark corresponding to described login user account number before;
Article adding device, for do not log in purchase system as user and this has a selected item time, from described cookie, obtain described login user account number before and correspond to the user encryption mark of described login user account number before, and to user present described before login user account number whether add this selected item to described login user before in the shopping cart of purchase system point out user, if, user encryption mark is sent to purchase system with identifying user identity legitimacy, and this selected item is added to described login user before at the shopping cart of purchase system after by checking, if not, then this selected item is added in described cookie.
Preferably, described user encryption mark comprises the inside account number of user in purchase system;
Article adding device, for deciphering described user encryption mark to obtain the inside account number of user in purchase system, when the inside account number of described user in purchase system and described before login user account number there is predetermined corresponding relation time, determine that user identity is legal; When the inside account number of described user in purchase system and described before login user account number not there is predetermined corresponding relation time, determine that user identity is illegal.
Preferably, described user encryption mark also comprises user's login time and user's signature.
Preferably, article adding device, during for article before existing in cookie, this selected item is covered described before article; During article before not existing in cookie, this selected item is added in described cookie.
Preferably, article adding device, for when user logs in purchase system, adds this user in the shopping cart of purchase system by this selected item; And
Send prompting to user, whether add the article be kept in described cookie to this user in the shopping cart of purchase system with reminding user; When user confirm as be time, the article be kept in described cookie are added to this user in the shopping cart of purchase system; When user confirms as no, do not add the article be kept in described cookie to this user in the shopping cart of purchase system.
As can be seen from technique scheme, in embodiments of the present invention, in the cookie of browser preserve before login user account number and correspond to described before login user account number user encryption mark, when user does not log in purchase system and this has a selected item, from described cookie, obtain described login user account number before and correspond to the user encryption mark of described login user account number before, and to user present described before login user account number whether add this selected item to described login user before in the shopping cart of purchase system point out user, if, user encryption mark is sent to purchase system with identifying user identity legitimacy, and this selected item is added to described login user before at the shopping cart of purchase system after by checking, if not, then this selected item is added in described cookie.Visible, the present invention adopts user account number and the user encryption mark thereof of cookie technology login user before client browser stores, article are added in shopping cart process user, the confirmation adding article prompting is provided, also can adds article when user does not log in in the shopping cart of the respective user of purchase system.
And the present invention can avoid user in shopping process, really do not add the illusion caused in purchase system shopping cart to when article add shopping cart, and article are added in purchase system shopping cart when not logging in; Different user can also be avoided when using same PC and browser, and what article interpolation shopping cart caused influences each other, and promotes Consumer's Experience.
Embodiment
For making the object, technical solutions and advantages of the present invention clearly, below in conjunction with accompanying drawing, the present invention is described in further detail.
Succinct and directly perceived in order to what describe, hereafter by description some representational embodiments, the solution of the present invention is set forth.Details a large amount of in embodiment only understands the solution of the present invention for helping.But these details can be not limited to when clearly, technical scheme of the present invention realizes.In order to avoid unnecessarily fuzzy the solution of the present invention, some embodiments do not describe meticulously, but only give framework.Hereinafter, " comprising " refers to " including but not limited to ", " according to ... " refer to " at least basis ..., but be not limited to only basis ... ".Due to the speech habits of Chinese, when hereinafter not particularly pointing out the quantity of a composition, mean that this composition can be one also can be multiple, or can be regarded as at least one.
The drawback existed when the present invention is directed to the purchase system article interpolation shopping cart of prior art, when logging in before user, login user account number before and the user encryption mark that corresponds to login user account number are before added in the local shopping cart (i.e. cookie) of browser.When this selected item of user, first judge whether user logs in purchase system, if logged in, then the direct login user that this selected item added to is in the shopping cart (i.e. server side) of purchase system; If do not logged in, login user account number before obtaining from the cookie of browser, and point out user whether to add to in this before login user account number by this selected item, if so, then this selected item is added in the shopping cart of login user before in purchase system by the user encryption mark by corresponding to login user account number before.
Fig. 1 adds the method flow diagram of article to shopping cart according to the present invention.
As shown in Figure 1, the method comprises:
Step 101: login user account number and the user encryption mark corresponding to described login user account number before before preserving in the biscuit (cookie) of browser.
Here, when logging in purchase system before user, login user account number before and the user encryption mark that corresponds to login user account number are before added in (cookie) of browser.
Shopping cart is for storing the article to be purchased of user temporarily in purchase system.Local shopping cart is the Item Information that the server of purchase system is temporarily stored in the cookie of client computer browser, when browser sends request to application server, can together be sent to the server of purchase system.In the present invention, before preserving in the cookie of browser login user account number and correspond to before login user account number user encryption mark, the Item Information in local shopping cart can also be preserved in cookie.The shopping cart of purchase system is the Item Information preserved in the server of purchase system.
Step 102: when user does not log in purchase system and this has a selected item, from cookie obtain before login user account number and correspond to before login user account number user encryption mark, and before presenting to user login user account number with point out user whether this selected item is added to before login user in the shopping cart of purchase system, if, user encryption mark is sent to purchase system with identifying user identity legitimacy, and before this selected item being added to after by checking login user at the shopping cart of purchase system, if not, then this selected item is added in cookie.
Login user is kept at server side at the shopping cart of purchase system, does not change with browser and the change logging in PC.
Here, when user does not log in purchase system and this has a selected item, login user account number and correspond to the user encryption mark of login user account number before before obtaining from cookie.And, login user account number before presenting to user, thus prompting user whether this selected item is added to before login user in the shopping cart of purchase system.That user encryption mark is sent to purchase system with identifying user identity legitimacy if user have selected, and when by the shopping cart of login user before this selected item being added to after verifying at purchase system; If user have selected not, then this selected item is added in the cookie of browser.
In one embodiment:
User encryption mark comprises the inside account number of user in purchase system; Described identifying user identity legitimacy comprises:
Decipher described user encryption mark to obtain the inside account number of user in purchase system, when the inside account number of described user in purchase system and described before login user account number there is predetermined corresponding relation time, determine that user identity is legal; When the inside account number of described user in purchase system and described before login user account number not there is predetermined corresponding relation time, determine that user identity is illegal.
Because the login user account number before in cookie may be maliciously tampered, user encryption is therefore utilized to identify authenticating users.
Such as, in purchase system, preserve login account abd@xxx.com in advance; And the corresponding inside account a12345 preserving abd@xxx.com in purchase system.When user once logs in purchase system on a web browser with login account abd@xxx.com, in the cookie of browser, preserve login account abd@xxx.com and identify corresponding to the user encryption of login account abd@xxx.com, and this user encryption mark decrypted after, inner account a12345 can be there is.
Now, the detailed process of identifying user identity legitimacy comprises: based on the decipherment algorithm corresponding to the cryptographic algorithm that user encryption identifies, decrypted user encryption identification is to obtain the inside account number a12345 of user in purchase system, when the inside account number (a12345) of user in purchase system is with when login user account number (abd xxx.com) has predetermined corresponding relation before, determine that user identity is legal; When the inside account number of user in purchase system with before login user account number not there is predetermined corresponding relation time, determine that user identity is illegal.
When login user account number is tampered before, when being such as tampered as ccc@xxx.com by abd@xxx.com, cannot be tampered because user encryption mark is encrypted, a12345 is remained to obtain the inside account number of user in purchase system through decrypted user encryption identification, now purchase system find the inside account number (a12345) of user in purchase system and be tampered before login user account number (ccc@xxx.com) when not there is predetermined corresponding relation, therefore determine that user identity is illegal, now this selected item is not added to be tampered before login user account number (ccc@xxx.com) at the shopping cart of purchase system.
Preferably, user encryption mark also comprises user's login time and user's signature.
In one embodiment:
Add this selected item to described cookie to comprise:
During article before existing in cookie, this selected item is covered described before article; During article before not existing in cookie, this selected item is added in described cookie.
In one embodiment, the method also comprises: when user logs in purchase system, this selected item is added to this user in the shopping cart of purchase system; And
Send prompting to user, whether add the article be kept in described cookie to this user in the shopping cart of purchase system with reminding user; When user confirm as be time, the article be kept in described cookie are added to this user in the shopping cart of purchase system; When user confirms as no, do not add the article be kept in described cookie to this user in the shopping cart of purchase system.
Fig. 2 adds the method flow diagram of article to shopping cart according to embodiment of the present invention.
As shown in Figure 2, the method comprises:
Step 201 ~ 206: user selects article to be purchased, expect to add article to shopping cart.First judge whether user logs in purchase system, if logged in, then article to be added in purchase system in this logged-in user shopping cart; If do not logged in, then perform step 207 and subsequent step thereof;
Step 207 ~ step 210: the cookie obtaining local browser, and before judging whether to exist in cookie login user account and correspond to before login account user encryption mark, if there is no, user is then pointed out to be in non-logging status, and in cookie, add article to be purchased, flow process terminates; If existed, then perform step 211 and subsequent step thereof:
Step 211 ~ step 213: before obtaining from cookie login user user account and correspond to the user encryption mark of login user before, prompting user confirm article to be purchased to be added to this before login user account in the shopping cart of purchase system.If user does not confirm, then article to be purchased to be added in cookie (if there are other article in cookie, then covering other article described); If user confirms, perform step 214 and subsequent step thereof;
Step 214 ~ step 217: submit to the user account of article to be purchased, before login user and user encryption thereof to be identified to purchase system, purchase system decrypted user encryption identification is to obtain the inner account number of user, when confirming that the user account of the inner account number of user with login user before has predetermined corresponding relation, before article to be purchased being added to this, login user is in the shopping cart of purchase system, and flow process terminates.
Fig. 3 is according to user's login process method process flow diagram of the present invention.
As shown in Figure 3, the method comprises:
Step 301 ~ step 305: user logs in purchase system, obtains the cookie of user browser, the user encryption mark of login user account and correspondence before judging whether to exist in cookie.If existed, obtain the item lists of having preserved in cookie, the article in item lists are added to this login user in the shopping cart of purchase system, and process ends; If there is no, then step 306 and subsequent step thereof is performed;
Step 306: the login account and the user encryption mark that obtain current login user, add in cookie by the login account of current login user and user encryption mark, flow process terminates.
The present invention adopts user account number and the user encryption mark thereof of cookie technology login user before client browser stores, article are added in shopping cart process user, the confirmation adding article prompting is provided, also can adds article when user does not log in in the shopping cart of the respective user of purchase system.
The present invention can avoid user in shopping process, does not really add the illusion caused in purchase system shopping cart to, and added to by article in purchase system shopping cart when not logging in when article add shopping cart; Different user can also be avoided when using same PC, browser, and what article interpolation shopping cart caused influences each other, and promotes Consumer's Experience.
Fig. 4 adds the structure drawing of device of article to shopping cart according to the present invention.
As shown in Figure 4, this device comprises:
Cookie storage unit 401, for login user account number before preservation in the biscuit (cookie) of browser and the user encryption mark corresponding to described login user account number before;
Article adding device 402, for do not log in purchase system as user and this has a selected item time, from described cookie, obtain described login user account number before and correspond to the user encryption mark of described login user account number before, and to user present described before login user account number whether add this selected item to described login user before in the shopping cart of purchase system point out user, if, user encryption mark is sent to purchase system with identifying user identity legitimacy, and this selected item is added to described login user before at the shopping cart of purchase system after by checking, if not, then this selected item is added in described cookie.
In one embodiment, user encryption mark comprises the inside account number of user in purchase system;
Article adding device 402, for deciphering described user encryption mark to obtain the inside account number of user in purchase system, when the inside account number of described user in purchase system and described before login user account number there is predetermined corresponding relation time, determine that user identity is legal; When the inside account number of described user in purchase system and described before login user account number not there is predetermined corresponding relation time, determine that user identity is illegal.
In one embodiment, user encryption mark also comprises user's login time and user's signature.
In one embodiment, article adding device 402, during for article before existing in cookie, this selected item is covered described before article; During article before not existing in cookie, this selected item is added in described cookie.
In one embodiment, article adding device 402, for when user logs in purchase system, adds this user in the shopping cart of purchase system by this selected item; And send prompting to user, whether add the article be kept in described cookie to this user in the shopping cart of purchase system with reminding user; When user confirm as be time, the article be kept in described cookie are added to this user in the shopping cart of purchase system; When user confirms as no, do not add the article be kept in described cookie to this user in the shopping cart of purchase system.
In fact, interpolation article that embodiment of the present invention the proposes method to shopping cart can specifically be implemented by various ways.
Such as, the application programming interfaces of certain specification can be followed, be written as adding the method for article to shopping cart the plug-in card program be installed in PC, mobile terminal etc., also can be encapsulated as application program and download use voluntarily for user.When being written as plug-in card program, the multiple card format such as ocx, dll, cab can be implemented as.Also interpolation article that embodiment of the present invention the proposes method to shopping cart can be implemented by the concrete technology such as Flash plug-in unit, RealPlayer plug-in unit, MMS plug-in unit, MIDI staff plug-in unit, ActiveX plug-in unit.
The interpolation article that embodiment of the present invention is proposed by the storing mode that can be stored by instruction or instruction set are stored on various storage medium to the method for shopping cart.These storage mediums include, but are not limited to: floppy disk, CD, DVD, hard disk, flash memory, USB flash disk, CF card, SD card, mmc card, SM card, memory stick (Memory Stick), xD card etc.
In addition, the interpolation article that embodiment of the present invention can also be proposed are applied in the storage medium based on flash memory (Nand flash) to the method for shopping cart, such as USB flash disk, CF card, SD card, SDHC card, mmc card, SM card, memory stick, xD card etc.
In sum, in embodiments of the present invention, in the cookie of browser preserve before login user account number and correspond to described before login user account number user encryption mark, when user does not log in purchase system and this has a selected item, from described cookie, obtain described login user account number before and correspond to the user encryption mark of described login user account number before, and to user present described before login user account number whether add this selected item to described login user before in the shopping cart of purchase system point out user, if, user encryption mark is sent to purchase system with identifying user identity legitimacy, and this selected item is added to described login user before at the shopping cart of purchase system after by checking, if not, then this selected item is added in described cookie.Visible, the present invention adopts user account number and the user encryption mark thereof of cookie technology login user before client browser stores, article are added in shopping cart process user, the confirmation adding article prompting is provided, also can adds article when user does not log in in the shopping cart of the respective user of purchase system.
And the present invention can avoid user in shopping process, really do not add the illusion caused in purchase system shopping cart to when article add shopping cart, and article are added in purchase system shopping cart when not logging in; Different user can also be avoided when using same PC and browser, and what article interpolation shopping cart caused influences each other, and promotes Consumer's Experience.
The above, be only preferred embodiment of the present invention, be not intended to limit protection scope of the present invention.Within the spirit and principles in the present invention all, any amendment done, equivalent replacement, improvement etc., all should be included within protection scope of the present invention.