A kind of method of advertisement
Technical field
The present invention relates to computer realm, particularly relate to a kind of method of advertisement.
Background technology
At present, the on record page rendering method for advertisement pushing has two kinds, and the real-time page embeds and page cache technology.
The real-time page embeds, and is the ad-hoc location insertion of advertising code at the page time being deployed in the advertisement pushing equipment Inspection in operator's core network to http response stream, to reach the object of advertisement pushing.But the shortcoming of this mode is, greatly affect the transfer efficiency of core network.Real-time page embedded technology requires that advertisement pushing devices in series is in Backbone network, when ensureing advertisement pushing coverage rate, need advertisement pushing equipment in the http response stream of the overwhelming majority, detect the content of each packet, to find out the particular location that suitable ad code is inserted, owing to needing data packet number to be processed very many, and also there is the situation needing the page to decompress in HTTP stream, equipment must be affected to the transfer capability of packet, and this can cause extreme influence to the transfer efficiency of core network.
Page cache technology, refer to and will need the page cache of advertisement on the server of specifying, insert the ad code of specifying in advance wherein, when advertisement pushing equipment Inspection belongs to the page that active client is accessed the page presetting and need advertisement, loopback HTTP page reorientation packet, substitutes object webpage with the page existing on server and shows to client.This technology solves efficiency, but is the introduction of coverage rate problem.Must arrange in advance owing to needing the webpage pushed, all webpages so just can not be accomplished all to carry out insertion of advertising code and buffer memory, therefore when access is not the page pre-set, or enters when another does not pre-set the page of advertisement pushing from the page having completed advertisement and just no longer present with regard to advertisement.And in network instantly, the content of most Webpage is all upgrading very continually, and correspondingly, just require that the page of buffer memory can be upgraded in time, this makes maintenance work become complex.
Summary of the invention
Technical matters to be solved by this invention is a kind of method of inventing advertisement, and described method had both solved the problem that in advertisement pushing process, core network transmission data efficiency is lowered, and improved again advertisement coverage rate.
The present invention is achieved in that a kind of method of advertisement, comprises the following steps:
The HTTP request of S1, acquisition client, and from HTTP head, resolve object link by advertisement pushing device, described object is linked as the link of the page of user expectation access;
S2, advertisement pushing device generate http response, and in described http response, the position that the viewing area that accessed content by described object link dynamic insertion is corresponding, by position corresponding for ad content insertion of advertising region;
S3, encapsulate described http response, generate protocol package, and described protocol package is sent to client;
S4, client represent the ad content be included in protocol package, and initiate second time HTTP request according to described object link;
Described second time HTTP request is directly forwarded to web page server by S5, advertisement pushing device, and web page server carries out webpage response to described second time HTTP request;
S6, client obtain the response of described webpage, and the viewing area that accesses content described in described webpage response is presented at.
Preferably, before S1, carry out overall page design in client, overall page is divided into access content viewing area and advertising area two parts.
Preferably, before S1, for advertisement pushing device arranges the advertisement pushing time interval, the described propelling movement time interval is not less than showing advertisement duration.
Preferably, after S6, when there occurs the internal links operation to the page of user expectation access, showing advertisements can not be repeated.
Preferably, after S6, when there occurs to user expectation access the page internal links operation after return again described user expectation access the page time, described ad content normally shows.
Preferably, described object link represents with the src field of <iframe> label in HTML.
Preferably, described ad content is advertisement and identifier.
Preferably, described ad content is presented at described advertising area, and access content described in described advertising area is suspended in viewing area.
Preferably, described ad content represent the time reach showing advertisement duration after automatically hide.
Preferably, described ad content represents by Html, CSS or/and JavaScript realizes.
Preferably, in S3, the data volume size of the IP packet that protocol package is corresponding is not more than the MTU of Ethernet, and described IP packet is for generating protocol package, and described IP packet describes the actual content that described protocol package is transmitted.
Preferably, described client is mobile device, and described ad content can be dragged arbitrarily when representing.
Implement the present invention, there is following beneficial effect:
The invention provides a kind of method of advertisement, this method only needs the head of resolving HTTP request, and is achieved the propelling movement of advertisement by advertisement pushing device and web page server.The present invention only needs to resolve HTTP header contents to obtain the object link of access, and HTTP head does not exist the situation of compression, therefore compares HTTP Context resolution, very easily completes; Therefore, when advertisement pushing devices in series is in core network, little on the impact of core network transfer efficiency, and when advertisement pushing equipment is connected in parallel in core network, it exists hardly on the impact of core network; In addition using this method when occurring returning parent page after internal links again, although the page occurred changing the display not affecting advertisement, thus solving the problem of coverage rate, during advertisement pushing, almost can cover any one accessed HTTP page; In addition, pushing the time interval in this method is not less than showing advertisement duration, therefore there will not be the problem that multiple advertisement shows simultaneously.
Accompanying drawing explanation
Fig. 1 is Pages Design figure;
Fig. 2 is a kind of process flow diagram of method of advertisement.
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.
Embodiments provide a kind of method of advertisement, needed mobile device overall page is designed before advertisement pushing, as shown in Figure 1, overall page 1 is divided into access content viewing area 2 and advertising area 3 two parts; Overall page 1 fills the part of mobile device browser for showing completely, and it includes access content viewing area 2 and advertising area 3; And before advertisement, need for the advertisement pushing device for advertisement arranges the advertisement pushing time interval, the described propelling movement time interval is not less than showing advertisement duration;
The method of advertisement comprises the following steps, as shown in Figure 2:
The HTTP request of S1, acquisition mobile device, and from HTTP head, resolve object link by advertisement pushing device, described object is linked as the link of the page of user expectation access;
S2, advertisement pushing device generate http response, in described http response, by position corresponding for the viewing area that accesses content described in described object link dynamic insertion, ad content is inserted position corresponding to described advertising area, the position that described advertising area is corresponding is directly calculated by advertisement pushing device, do not need to carry out dynamic lookup, thus improve response speed; Described link position is the position of src field value in <iframesrc=> label, and this position can calculate when the page shows relative to the off-set value of page beginning;
S3, encapsulate described http response, generate protocol package, and described protocol package is sent to mobile device;
S4, mobile device represent the ad content be included in protocol package, and initiate second time HTTP request according to described object link;
Described second time HTTP request is directly forwarded to web page server by S5, advertisement pushing device, and web page server carries out webpage response to described second time HTTP request; Now, because advertisement pushing device sets the advertisement pushing time interval that one is not less than showing advertisement duration, therefore, now advertisement pushing device can not advertisement, but HTTP request is transferred to web page server;
S6, mobile device obtain the response of described webpage, and the viewing area that accesses content described in described webpage response is presented at.
Because advertisement part presents by duration, and advertisement pushing device also sets the advertisement pushing time interval pushed mobile device, the setting of its size is not less than showing advertisement duration, therefore when there is internal links, within the advertisement pushing time interval, advertisement pushing device does not process internal links request, described linking request is transferred into web page server, response is responsible for by web page server, mobile device receives webpage response and produces Web evolution, described Web evolution does not affect the display that advertisement before internal links occurs, therefore there will not be the problem of multiple showing advertisement, due to mobile device expect the page be in <iframe> label under, even if again perform after therefore there is internal links and return operation, parent page changes, but can not have influence on the displaying of the advertisement outside <iframe>.This method web displaying and ad content display are independently independent of each other, and described showing advertisement duration is greater than 0, and unit is second, is 60 seconds in the present embodiment.
Preferably, the advertisement pushing time interval of advertisement pushing device adjusts according to showing advertisement duration.The advertisement pushing time interval be arranged so that advertisement pushing device needs HTTP request quantity to be processed greatly to reduce, and little on the impact of advertisement coverage rate.
Preferably, described ad content is a very succinct mark, can not affect mobile device user and carry out content of pages reading.
Preferably, described ad content is presented at described advertising area 3, and access content described in described advertising area 3 is suspended in viewing area 2.
Preferably, described ad content use the some or all of technology in Html, CSS and JavaScript be suspended in described in access content on viewing area 2, and it also by these technology on a web browser, is demonstrated, then will automatically hides in showing advertisement duration.Described ad content can be dragged arbitrarily when representing.
Preferably, in S3, the data volume size of the IP packet that protocol package is corresponding is not more than the MTU of Ethernet, and described IP packet is for generating protocol package, and described IP packet describes the actual content that described protocol package is transmitted.The second layer of the corresponding OSI7 layer model of the protocol package in S3, i.e. the encapsulation of data link layer, the form of data link layer protocol bag is as follows
Protocol header H |
The actual content C that protocol package is transmitted |
Agreement tail T |
The maximum length of the C field of this protocol package is MTU (MaximumTransmissionUnit), namely the single protocol package maximum amount of data (unit Byte) that can transmit.When the content needing to transmit is more than MTU, need to generate multiple protocol package to transmit.
The protocol package type standard of two layers of acquiescence use is EthernetII, and transliteration ethernet ii, described MTU is Ethernet MTU.Described protocol package actual content C comes from the third layer of OSI7 layer model, i.e. the IP packet of network layer, therefore, when the packet data of IP described in the present embodiment amount is less than Ethernet MTU, can be packaged into single protocol package, this can simplify the treatment scheme of advertisement pushing device, raises the efficiency.
Above disclosedly be only present pre-ferred embodiments, certainly can not limit the interest field of the present invention with this, therefore according to the equivalent variations that the claims in the present invention are done, still belong to the scope that the present invention is contained.