Summary of the invention
The embodiment of the present invention provides a kind of shared method and system of network comment information, many comment contents of identical comment object are all needed to preserve for solving different web sites in prior art, cause the redundancy of storage space on network, the problem of the resource of the waste network bandwidth.
Embodiments provide a kind of shared method of network comment information, comprise,
Determine the unique identifier of the comment object being positioned at a plurality of client-server;
Embed at described client-server and there is described unique identifier and comment on unit one to one with described comment object;
After user terminal is to the comment object input comment content of described client-server, described comment content and described unique identifier are sent back background data base server by described comment unit;
Described comment content stores according to described unique identifier by described background data base server in a database.
According to a further aspect of the shared method of a kind of network comment information of the embodiment of the present invention, determine that the unique identifier of the comment object being arranged in a plurality of client-server comprises further described, data analysis is carried out to described client-server comment object, obtain the eigenwert of described comment object, according to the eigenwert of described comment object, give and there is the identical unique identifier of the comment object of all client-servers of this eigenwert.
According to another further aspect of the shared method of a kind of network comment information of the embodiment of the present invention, above-mentionedly carry out data analysis to described client-server comment object, the eigenwert obtaining described comment object comprises further,
According to the URL address of the comment object of described client-server, using the eigenwert of described URL address as described comment object;
Or, according to the word content of described comment object, using the eigenwert of described word content as described comment object;
Or, according to the MD5 value of the picture of described comment object, using the eigenwert of described MD5 value as described comment object;
Or, according to the bit stream data of the video flowing of described comment object, using the eigenwert of described bit stream data as described comment object.
According to another further aspect of the shared method of a kind of network comment information of the embodiment of the present invention, in the URL address of the comment object according to described client-server, the eigenwert of described URL address as described comment object is comprised further, a plurality of comment objects in described client-server have same URL address, then the difference in identical URL address being commented on Object identifying is different subcharacter values.
According to another further aspect of the shared method of a kind of network comment information of the embodiment of the present invention, in the eigenwert according to described comment object, give the unique identifier that there is the comment object of all client-servers of this eigenwert identical to comprise, the subcharacter value of the URL address eigenwert of described comment object and comment object is merged, gives and there is this eigenwert unique identifier identical with the comment object of all client-servers of subcharacter value.
According to another further aspect of the shared method of a kind of network comment information of the embodiment of the present invention, determining that the unique identifier of the comment object being arranged in a plurality of client-server comprises further, when the eigenwert of the comment object of different clients server is identical, notify described client-server, according to the response of described client-server, give identical unique identifier by the comment object with same characteristic features value, or give different unique identifiers by the comment object of same characteristic features value.
According to another further aspect of the shared method of a kind of network comment information of the embodiment of the present invention, determining that the unique identifier of the comment object being arranged in a plurality of client-server comprises further, receive the instruction of described client-server, the comment object of specifying for specific client-server gives unique identifier.
According to another further aspect of the shared method of a kind of network comment information of the embodiment of the present invention, after user terminal is to the comment object input comment content of described client-server, described comment content and described unique identifier are sent back background data base server and comprise further by described comment unit, described comment unit also obtains the user profile of current input comment content, sends described user profile to described background data base server.
According to another further aspect of the shared method of a kind of network comment information of the embodiment of the present invention, described comment content to store according to described unique identifier and comprises further by described background data base server in a database, when user terminal requests shows the comment content of described comment object, described comment unit sends the solicited message that carry unique identifier to described background data base server, described background data base server matches in a database according to described unique identifier and comments on content accordingly, described comment content is sent to described user terminal.
The embodiment of the present invention additionally provides a kind of shared system of network comment information, comprises,
Comment object identification unit, client-server, comment object, background data base server, comment unit, user terminal, database;
Described comment object identification unit, for determining the unique identifier of the comment object being positioned at a plurality of client-server;
Described client-server, is connected with described comment unit, for carrying described comment object;
Described comment unit, obtain described unique identifier and with described comment object one_to_one corresponding, the comment content inputted the comment object of described client-server by described user terminal and described unique identifier send it back background data base server;
Described background data base server, for storing described comment content in a database according to described unique identifier.
According to a further aspect of the shared system of a kind of network comment information of the embodiment of the present invention, described comment object identification unit comprises further, data analysis module and assignment module; Described data analysis module is used for carrying out data analysis to described comment object, obtains the eigenwert of described comment object; Described assignment module, for the eigenwert according to described comment object, gives and has the identical unique identifier of the comment object of all client-servers of this eigenwert.
According to another further aspect of the shared system of a kind of network comment information of the embodiment of the present invention, described data analysis module also comprises with lower component one of them or multiple combination, URL analysis component, character analysis parts, picture analyzing parts and video flowing analysis component;
Described URL analysis component, for analyzing the URL address of described comment object, using the eigenwert of described URL address as described comment object;
Described character analysis parts, for analyzing the word content of described comment object, using the eigenwert of described word content as described comment object;
Described picture analyzing parts, for calculating the MD5 value of the picture of described comment object, using the eigenwert of described MD5 value as described comment object;
Described video flowing analysis component, for analyzing the bit stream data in the video flowing of described comment object, using the eigenwert of described bit stream data as described comment object.
According to another further aspect of the shared system of a kind of network comment information of the embodiment of the present invention, described data analysis module also comprises sub-URL analysis component, be connected with described URL analysis component, have a plurality of comment object for working as in same URL address, the difference comment Object identifying in identical URL address is different subcharacter values by described sub-URL analysis component; The subcharacter value of the URL address eigenwert of described comment object and comment object merges by described assignment module, gives and has this eigenwert unique identifier identical with the comment object of all client-servers of subcharacter value.
According to another further aspect of the shared system of a kind of network comment information of the embodiment of the present invention, described comment object identification unit also comprises notification module and distribution module; Described notification module, when the eigenwert for the comment object when different client-servers is identical, notifies described client-server; After described distribution module obtains the response of described client-server, give identical unique identifier by the comment object with same characteristic features value, or give different unique identifiers by the comment object of same characteristic features value.
By the embodiment of the present invention, the wasting of resources of the similar comment of different clients server stores can be saved by the unique identifier determining to comment on object, and user can be facilitated to check, and comment object more comments on content.
Embodiment
Below in conjunction with the accompanying drawing in the embodiment of the present invention, be clearly and completely described the technical scheme in the embodiment of the present invention, obviously, described embodiment is only the present invention's part embodiment, instead of whole embodiments.Based on the embodiment in the present invention, those of ordinary skill in the art, not making the every other embodiment obtained under creative work prerequisite, belong to the scope of protection of the invention.
Be illustrated in figure 1 the shared method flow diagram of a kind of network comment information of the embodiment of the present invention.
Comprise, step 101, determine the unique identifier of the comment object being positioned at a plurality of client-server.
Step 102, embeds at described client-server and has described unique identifier and comment on unit one to one with described comment object.
Step 103, after user terminal is to the comment object input comment content of described client-server, described comment content and described unique identifier are sent back background data base server by described comment unit.
Step 104, described comment content stores according to described unique identifier by described background data base server in a database.
Wherein, described client-server can be the server of heterogeneous networks service provider, and described comment object comprises the data contents such as picture, word and video, and described comment content comprises the data contents such as word, picture and video.
Comprise further in described step 101, data analysis is carried out to described client-server comment object, obtain the eigenwert of described comment object, according to the eigenwert of described comment object, give and there is the identical unique identifier of the comment object of all client-servers of this eigenwert, such as can according to the URL address of the comment object of described client-server (Uniform/Universal Resource Locator, URL), using the eigenwert of described URL address as described comment object, for the comment object of the client-server of this URL address of all references, the comment object namely with same characteristic features value gives identical unique identifier, if described comment, to liking text formatting, can also analyze word content, using the eigenwert of described word content as described comment object, for the comment object in all client-servers of same text content gives identical unique identifier, if described comment object is picture, Message Digest Algorithm 5 (the Message Digest Algorithm of described picture can also be calculated, MD5) value, using the eigenwert of described MD5 value as described comment object, give the unique identifier that the comment object had in all client-servers of identical MD5 value is identical, wherein MD5 value just for example, should not become the restriction to the embodiment of the present invention, if described comment object is video flowing, the bit stream data in described video flowing can also be analyzed, using the eigenwert (described bit stream data can be a part of code stream in video flowing or all code stream) of described bit stream data as described comment object, give and there is the identical unique identifier of comment object in the client-server of same code flow data, described bit stream data can part identical or all identical.Wherein said unique identifier can be character string or the numeric string for numeral composition.
In the URL address of the comment object according to described client-server, the eigenwert of described URL address as described comment object is comprised further, a plurality of comment objects in described client-server have same URL address, then the difference in identical URL address being commented on Object identifying is different subcharacter values, the subcharacter value of the URL address eigenwert of described comment object and comment object is merged, gives and there is this eigenwert unique identifier identical with the comment object of all client-servers of subcharacter value.
In addition, can also comprise in a step 101, when the eigenwert of the comment object of different clients server is identical, notify described client-server, according to the response of described client-server, give identical unique identifier by the comment object with same characteristic features value, or give different unique identifiers by the comment object of same characteristic features value.Such as when there is identical comment object (picture) in client-server A, client-server B, client-server C and client-server D, notice is responsible for above-mentioned client-server A to client-server D, according to the response message of client-server, identical unique identifier can be distributed, for client-server D distributes another unique identifier for picture specified in client-server A, client-server B and client-server C.
Also comprise further in described step 101, receive the instruction of described client-server, the comment object of specifying for specific client-server gives unique identifier, such as, the unique identifier of client-server A instruction comment object A ' is 0001, client server B instruction comment object B ' unique identifier be 0002.
Comprise further in described step 103, after user terminal is to the comment object input comment content of described client-server, described comment unit also obtains the user profile of current input comment content, send described user profile to described background data base server, such as can obtain user terminal browse user name in web cache, user sends the user profile comprising the information such as user name to background data base server, so that can find all comment contents relevant with it according to user profile when managing personal account.
Also comprise further after described step 104, when user terminal requests shows the comment content of described comment object, described comment unit sends the solicited message that carry unique identifier to described background data base server, described background data base server matches in a database according to described unique identifier and comments on content accordingly, and described comment content is sent to described user terminal by comment unit.
By the invention described above embodiment, the comment that be can be implemented in different web sites by comment unit can be shared, when no matter user is browsed comment content by what client-server (all having installed comment unit) or is commented on comment object, all can obtain all comment contents for identical comment object simultaneously, save the information redundancy in network, and decrease different clients server repeatedly storage class like repeat comment content.
Be illustrated in figure 2 the structural drawing of the shared system of a kind of network comment information of the embodiment of the present invention.
Comprise, comment object identification unit 201, client-server 202, comment object 203, background data base server 204, comment unit 205, user terminal 206, database 207.
Described comment object identification unit 201, for determining the unique identifier of the comment object 203 being positioned at a plurality of client-server 202.
Described client-server 202, for carrying described comment object 203, and is connected with described comment unit 205.
Described comment unit 205, obtain described unique identifier and with described comment object one_to_one corresponding, the comment content input the comment object 203 of described user terminal 206 to described client-server 202 and described unique identifier send it back background data base server 204.
Described background data base server 204, for storing described comment content according to described unique identifier in database 207.
Described comment object identification unit 201 comprises further, data analysis module 2011 and assignment module 2012, and described data analysis module 2011, for carrying out data analysis to described comment object, obtains the eigenwert of described comment object.Described assignment module 2012, for the eigenwert according to described comment object, gives and has the identical unique identifier of the comment object of all client-servers of this eigenwert.Described assignment module 2012 is also for the instruction according to client-server, and the comment object of specifying for specific client-server gives unique identifier.
Described comment object identification unit 201 also comprises notification module 2013 and distribution module 2014, when described notification module 2013 is identical for the eigenwert of the comment object 203 when different client-servers 202, notifies described client-server 202.After described distribution module 2014 obtains the response of described client-server 202, give identical unique identifier by the comment object with same characteristic features value, or give different unique identifiers by the comment object of same characteristic features value.
Described comment unit 201 also for obtaining the user profile of current input comment content, sends described user profile to described background data base server 204.
Be illustrated in figure 3 the structural representation of embodiment of the present invention data analysis module.
Described data analysis module 300 can comprise with lower component one of them or multiple combination, URL analysis component 301, character analysis parts 302, picture analyzing parts 303, video flowing analysis component 304 and sub-URL analysis component 305.
Described URL analysis component 301, for analyzing the URL address of described comment object, using the eigenwert of described URL address as described comment object.
Described character analysis parts 302, for analyzing word content, using the eigenwert of described word content as described comment object.
Described picture analyzing parts 303, for calculating the MD5 value of described picture, using the eigenwert of described MD5 value as described comment object.
Described video flowing analysis component 304, for analyzing the bit stream data in described video flowing, using the eigenwert of described bit stream data as described comment object.
Described sub-URL analysis component 305, be connected with described URL analysis component 301, in same URL address, there is a plurality of comment object for working as, difference comment Object identifying in identical URL address is different subcharacter values by described sub-URL analysis component 305, to identify the difference comment object in the same page.The subcharacter value of the URL address eigenwert of described comment object and comment object merges by described assignment module 2012, gives and has this eigenwert unique identifier identical with the comment object of all client-servers of subcharacter value.
Be illustrated in figure 4 the data flow diagram of the shared method of embodiment of the present invention kind network comment information.
The comment object of client-server A and client-server B is the section video flowing of same URL address.
Step 401, client-server A and client-server B sends the URL address of comment object to comment object identification unit.
Step 402, comment object identification unit is analyzed URL address, using the eigenwert of URL address as described comment object.
Step 403, the comment object of this video flowing is given the comment object ID of 0001 by comment object identification unit.
Step 404, can generate two identical comment unit by background data base server, and described comment unit obtains comment object ID, and described comment unit can be formed by HTML code.Described background data base server, comment object identification unit can combine, also can be arranged apart.
Step 405, the comment unit these two with identical comment object ID sends to client-server A and client-server B to bind respectively.Wherein, described client-server A and client-server B can comment in the iframe of object at it and embed described comment unit.
Step 406, when user terminal is after described client-server A is to described video flowing input comment content, described comment unit bind with client-server A by described comment object ID with comment on content and send to background data base server.
Step 407, when user terminal is after described client-server B is to described video flowing input comment content, described comment unit bind with client-server B by described comment object ID with comment on content and send to background data base server.
Step 408, the comment unit that described background data base server receives described client-server A and client-server B binding beams back next comment object ID and comment content, above-mentioned comment content is stored in a database according to described comment object ID.
Step 409, when the corresponding comment of user terminal requests display client server A comment object, comment unit on described client-server A to described background data base server send comment object ID, comment unit width, highly, page value (first time is 0), wherein page number value=(pagination number-1), wherein page number value is for getting the data under paging, if each comment is tactic, one page display N bar, n-th page of formula getting comment from database should be get N article (n-1) * N article from database.
Step 410, described background data base server sends all comment contents of described comment object to user terminal by comment unit, acquiescence shows first 20 from page number value.
Step 411, all comment contents that this comment object of described user terminal displays is relevant.
Be illustrated in figure 5 another data flow diagram of the shared method of embodiment of the present invention kind network comment information.
Client-server A has 2 comment objects (being such as picture) in same URL address.
Step 501, client-server A sends the URL address at comment object place to comment object identification unit.
Step 502, comment object identification unit is analyzed URL address and 2 pictures wherein, obtains the eigenwert of URL address and the subcharacter value of each picture.
Step 503, comment object identification unit by the eigenwert of described URL address and the subcharacter value of each picture united, determine comment object ID, such as two pictures are given respectively the comment object ID of 0002 and 0003.
Step 504, can generate two different comment unit by background data base server, and two different comment unit obtain two comment object IDs from comment object identification unit respectively, and described comment unit can be formed by HTML code.
Step 505, the comment unit these two with different comment object ID sends to client-server A to bind respectively.
Step 506, when user terminal is after described client-server A comments on described some pictures, the described comment unit relevant to this picture is by described comment object ID and comment on content and send to background data base server.
Step 507, the comment unit that described background data base server receives described client-server A binding beams back next comment object ID and comment content, above-mentioned comment content is stored in a database according to described comment object ID.
Step 508, when the corresponding comment of user terminal requests display client server A comment object, comment unit on described client-server A to described background data base server send comment object ID, comment unit width, highly, page value (first time is 0), wherein page number value=(pagination number-1).
Step 509, described background data base server sends all comment contents of described comment object to user terminal by comment unit, acquiescence shows first 20 from page number value.
Step 510, all comment contents that this comment object of described user terminal displays is relevant.
Be illustrated in figure 6 another data flow diagram of the shared method of embodiment of the present invention kind network comment information.
The comment object of client-server A and client-server B is identical passage.
Step 601, client-server A and client-server B sends the content of comment object, namely by the word commented on to comment object identification unit.
Step 602, comment object identification unit is analyzed, using word content as eigenwert the word content that client-server A sends over.
Step 603, comment object identification unit is analyzed, using word content as eigenwert the word content that client-server B sends over.
Step 604, comment object identification unit finds that the comment characteristics of objects value of client-server B is worth identical with the comment characteristics of objects of client-server A, sends a notification message to described client-server B.
Step 605, client-server B can according to the selection of oneself, response message is sent to comment object identification unit, such as can agree to use identical eigenwert with the comment object of client-server A, or identical eigenwert can not also be used with the comment object of client-server A.In this example, the comment object of client-server B uses identical eigenwert with the comment object of client-server A.
Step 606, the comment object of this word of client-server A and client-server B is given the comment object ID of 0004 by described comment object identification unit.
Step 607, can generate two identical comment unit by background data base server, and described comment unit obtains comment object ID, and described comment unit can be formed by HTML code.
Step 608, the comment unit these two with identical comment object ID sends to client-server A and client-server B to bind respectively.Wherein, described client-server A and client-server B can comment in the iframe of object at it and embed described comment unit.
Step 609, when user terminal described client-server A to described by comment text event detection comment content after, described comment object ID, the username information commented in content and user terminal webpage are sent to background data base server by the described comment unit bound with client-server A.
Step 610, when user terminal described client-server B to described by comment text event detection comment content after, described comment object ID, the username information commented in content and user terminal webpage are sent to background data base server by the described comment unit bound with client-server B.
Step 611, the comment unit that described background data base server receives described client-server A and client-server B binding beams back the comment object ID, comment content and the username information that come, above-mentioned comment content and username information is stored in a database according to described comment object ID.
Step 612, when all relevant to oneself the comment content of user terminal requests display client server A comment object, described client-server A to described background data base server send comment object ID and username information, comment unit width, highly, page value (first time is 0), wherein page number value=(pagination number-1).
Step 613, described background data base server sends all relevant to its user name comment content of described comment object to user terminal by comment unit, acquiescence shows first 20 from page number value.
Step 614, described user terminal displays and comment content relevant with username information in this comment object.
By above-described embodiment, the comment object of different web sites can share the comment content of all reviewers, saves the storage space of different clients server, and facilitates user to obtain more to comment on content.
Above-described embodiment; object of the present invention, technical scheme and beneficial effect are further described; be understood that; the foregoing is only the specific embodiment of the present invention; be not limited to restriction protection scope of the present invention; within the spirit and principles in the present invention all, any amendment made, equivalent replacement, improvement etc., all should be included within protection scope of the present invention.