Summary of the invention
For the needs being acquired in e-commerce website to exposure log, according to one aspect of the present invention, this hair
Bright to provide a kind of exposure Log Collect System, the system comprises webpage front-end server, web page browsing client and exposures
Log acquisition server, which is characterized in that
The webpage front-end server is provided comprising with the webpage for exposing element uniquely indicated and exposure data acquisition
Tool;
Exposure data sampling instrument described in the web page browsing client downloads is exposed after exposing element and loading successfully
Light data acquisition, the exposure data sampling instrument extract exposure element from webpage and send packet to exposure log acquisition server
The exposure data of unique mark and relevant information containing the exposure element;
The exposure log acquisition server receives above-mentioned exposure data, and exposure is written after handling the data
Log.
Preferably, in above-mentioned exposure Log Collect System, the exposure data sampling instrument is arranged on webpage
Specific position starting, the specific position show that the exposure element has loaded success.
Preferably, in above-mentioned exposure Log Collect System, the exposure data sampling instrument has following work feelings
Scape:
When exposing element synchronization load and specific information by successful presentation, the exposure data sampling instrument is exposed
Light data acquisition;Or
When exposing element synchronization load and specific information does not have successful presentation, the exposure data sampling instrument is carried out
Exposure data acquisition;Or
When exposing the asynchronous load of element and specific information by successful presentation, the exposure data sampling instrument is exposed
Light data acquisition;Or
When exposing the asynchronous load of element and specific information does not have successful presentation, the exposure data sampling instrument is carried out
Exposure data acquisition.
Preferably, in above-mentioned exposure Log Collect System, the exposure data sampling instrument to exposure log collection
Comprising access data uniquely indicates, city indicates and one or more of cookieId in the relevant information that server is sent.
Preferably, in above-mentioned exposure Log Collect System, the system also includes mapping servers, when the exposure
When log acquisition server receives cookieId, which is pushed to described reflect by the exposure log acquisition server
It penetrates server and carries out cookieId mapping, be only then writing into exposure log.
Another aspect is exposed log collection using system described in claim 1 the present invention provides a kind of
Method, which is characterized in that described method includes following steps:
The web page browsing client downloads exposure data sampling instrument and comprising having the exposure element that uniquely indicates
Webpage;
After exposure element loads successfully, start the exposure data sampling instrument;
The exposure data sampling instrument extracts the unique mark and relevant information of exposure element from webpage, and is organized into
Exposure data;
Above-mentioned exposure data is sent to the exposure log acquisition server by the exposure data sampling instrument;
The exposure log acquisition server receives the exposure data, and is written after handling the data
Expose log.
Preferably, in above-mentioned exposure log collection method, specific position of the exposure data sampling instrument in the page
Starting, the position shows that the exposure element has loaded success.
Preferably, in above-mentioned exposure log collection method, which is characterized in that
When exposing element synchronization load and specific information by successful presentation, the exposure data sampling instrument is exposed
Light data acquisition;Or
When exposing element synchronization load and specific information does not have successful presentation, the exposure data sampling instrument is carried out
Exposure data acquisition;Or
When exposing the asynchronous load of element and specific information by successful presentation, the exposure data sampling instrument is exposed
Light data acquisition;Or
When exposing the asynchronous load of element and specific information does not have successful presentation, the exposure data sampling instrument is carried out
Exposure data acquisition.
Preferably, in above-mentioned exposure log collection method, the exposure data sampling instrument takes to exposure log collection
Comprising access data uniquely indicates, city indicates and one or more of cookieId in the relevant information that business device is sent.
Preferably, in above-mentioned exposure log collection method, the system also includes mapping servers, when the exposure day
When will acquisition server receives cookieId, which is pushed to the mapping by the exposure log acquisition server
Server carries out cookieId mapping, is only then writing into exposure log.
Above-mentioned exposure Log Collect System and method can should synchronize load, asynchronous load, show, do not show
Various requirement completes the acquisition of exposure log, and can map that user's is hidden to protect by the cookieId of mapping server
It is private.
Specific embodiment
Below in conjunction with specific embodiment, the present invention is described in detail, it is to be appreciated that, these embodiments are only
For illustrating the present invention, and do not constitute a limitation of the invention.With reference to Fig. 1, according to one embodiment of present invention, the exposure
Light Log Collect System includes webpage front-end server 1, web page browsing client 2 and exposure log acquisition server 3.
Wherein, a series of merchandise display webpage and exposure data sampling instrument are provided on webpage front-end server 1.Its
In, such as include the merchandise display webpage of some brand television, it include following exposure element in the webpage, that is,
Include following label in webpage:
<a id="baoguang_100100123"></a>
Wherein baoguang_ is the particular prefix for exposing element, and 100100123 be unique mark of the exposure element.
Exposure data sampling instrument is one section of javascript code in the present embodiment, in order to load exposure data acquisition
Tool includes following script label in the beginning section of the webpage:
<script type="text/javascript"src="baoguang.js"></script>
For loading exposure data sampling instrument when web page browsing client 2 opens above-mentioned commodity webpage.
It include exposure data acquisition method in above-mentioned javascript exposure data sampling instrument baoguang.js
OnBaoguang()。
It is adopted to be exposed data after the exposure element that web page browsing client 2 loads above-mentioned merchandise display webpage
Collection, developer can call the exposure data acquisition method in above-mentioned tool in a specific position of its webpage, the position energy
Ensure to expose element load to complete:
<script type="text/javascript">onBaoguang ()</script>
This method OnBaoguang () can analyze the webpage of load, obtain a label in the webpage, and will meet
The elemental recognition of specific format is that exposure element if id is started with baoguang_, is identified as in the present embodiment
Expose element.
After identifying exposure element, above-mentioned exposure data sampling instrument extracts unique mark of the exposure element
100100123 and the relevant information of the commodity, as city indicates cityId, and the cookieId etc. to demarcate user
It is configured to an exposure data, i.e., one complete character string is sent to exposure log acquisition server 3.
After the exposure log acquisition server 3 receives above-mentioned exposure data, it will do it corresponding processing, will believe accordingly
Breath write-in exposure log.
In the above-described embodiments, exposure element is synchronous load with webpage, and only same in exposure element and webpage
Data acquisition is just exposed when step load.
In another embodiment, exposure element and webpage are asynchronous loads, and this asynchronous load can pass through
It the asynchronous behavior of javascript or is loaded back by webpage and transfers to realize.Also, under the asynchronous load condition, still into
The acquisition of row exposure data.
In other embodiments, if be exposed data acquisition is whether to have loaded phase with specific web page contents
Connection.
For example, in one embodiment, exposure data acquisition only just carries out after commodity picture is by successful presentation, that is,
Whether commodity picture displaying is successfully judged in above-mentioned javascript exposure data sampling instrument, such as judges commodity figure
The complete attribute of piece, and judge commodity picture whether in the display area of screen.If commodity picture successful presentation,
It is exposed data acquisition.Certainly, above-mentioned judgement is not limited in commodity picture, is also possible to the other informations such as commodity price,
Such as, only after commodity price successful presentation, just it is exposed data acquisition.
And in another embodiment, unlike above-mentioned rule, do not loaded in commodity picture or commodity price
Exposure data acquisition is still carried out when success.
Whether synchronous load, asynchronous load and the specific information of above-mentioned exposure element show can be according to specifically answering
Any combination is done with scene.I.e., it is possible to realize following four kinds of situations:
When exposing element synchronization load and specific information by successful presentation, the exposure data sampling instrument is exposed
Light data acquisition;
When exposing element synchronization load and specific information does not have successful presentation, the exposure data sampling instrument is carried out
Exposure data acquisition;
When exposing the asynchronous load of element and specific information by successful presentation, the exposure data sampling instrument is exposed
Light data acquisition;
When exposing the asynchronous load of element and specific information does not have successful presentation, the exposure data sampling instrument is carried out
Exposure data acquisition.
It is in one embodiment, described in order to protect the privacy of user since cookieId and specific user are mutually bound
Exposure Log Collect System further includes a mapping server 4, which is used to map cookieId, for example, by using
CookieId is mapped as a puppet id by certain hash algorithm, protects user hidden to cut off log recording and directly contacting for user
It is private.
The concrete operating principle of the mapping server 4 is, after exposure log acquisition server 3 receives cookieId,
The cookieId, which is sent to mapping server 4 after the mapping server 4 maps the cookieId, to be mapped
As a result exposure log acquisition server 3 is returned to, log acquisition server 3 is exposed by the pseudo- id after mapping and is written to exposure log
In.
Another aspect, as shown in Fig. 2, the present invention provides a kind of methods for exposing log collection, according to a reality
Example is applied, described method includes following steps:
Step 2001: the downloading of the web page browsing client 2 exposure data sampling instrument, i.e. baoguang.js, and under
It carries comprising the commodity webpage with the exposure element uniquely indicated;
Step 2002: after exposure element loads successfully, starting the exposure data sampling instrument;
Step 2003: the exposure data sampling instrument extracts the unique mark and correlation letter of exposure element from webpage
Breath, and it is organized into exposure data;
Step 2004: above-mentioned exposure data is sent to the exposure log collection service by the exposure data sampling instrument
Device 3;
Step 2005: the exposure log acquisition server receives the exposure data, and carries out to the data
Write-in exposure log after processing.
It, can be to the load condition and particular webpage content of exposure element in step 2002 in other some embodiments
Whether successful presentation is judged, to decide whether to be exposed data acquisition.That is, specifically there is following four kinds of embodiments:
When exposing element synchronization load and specific information by successful presentation, the exposure data sampling instrument is exposed
Light data acquisition;
When exposing element synchronization load and specific information does not have successful presentation, the exposure data sampling instrument is carried out
Exposure data acquisition;
When exposing the asynchronous load of element and specific information by successful presentation, the exposure data sampling instrument is exposed
Light data acquisition;
When exposing the asynchronous load of element and specific information does not have successful presentation, the exposure data sampling instrument is carried out
Exposure data acquisition.
Above-mentioned specific information can be the information such as commodity picture or commodity price.
Equally, in step 2005, since cookieId and specific user are mutually bound, in order to protect the privacy of user,
It in one embodiment, further include the mapping step of cookieId in step 2005, that is, received in exposure log acquisition server 3
To after cookieId, the cookieId is sent to mapping server 4, the mapping server 4 carries out the cookieId
After mapping, mapping result is returned into exposure log acquisition server 3, exposes log acquisition server 3 for the pseudo- id after mapping
It is written in exposure log.
Above in conjunction with specific embodiment, invention has been described, it will be appreciated that above-described embodiment is not
Restriction of the invention is constituted, protection scope of the present invention is determined by claim.Without departing from thought of the invention, above-mentioned reality
The possibility combination of various technological means in example is applied, and is substituted and is generated with technological means known to those skilled in the art
Technical solution all fall in protection scope of the present invention.