CN110162725A - Online page loading method, device, storage medium and computer equipment - Google Patents

Online page loading method, device, storage medium and computer equipment Download PDF

Info

Publication number
CN110162725A
CN110162725A CN201910286582.7A CN201910286582A CN110162725A CN 110162725 A CN110162725 A CN 110162725A CN 201910286582 A CN201910286582 A CN 201910286582A CN 110162725 A CN110162725 A CN 110162725A
Authority
CN
China
Prior art keywords
content code
edition
version
difference
information
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN201910286582.7A
Other languages
Chinese (zh)
Inventor
何力
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Zhejiang Koubei Network Technology Co Ltd
Original Assignee
Zhejiang Koubei Network Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Zhejiang Koubei Network Technology Co Ltd filed Critical Zhejiang Koubei Network Technology Co Ltd
Priority to CN201910286582.7A priority Critical patent/CN110162725A/en
Publication of CN110162725A publication Critical patent/CN110162725A/en
Pending legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/90Details of database functions independent of the retrieved data types
    • G06F16/95Retrieval from the web
    • G06F16/957Browsing optimisation, e.g. caching or content distillation
    • G06F16/9574Browsing optimisation, e.g. caching or content distillation of access to content, e.g. by caching

Landscapes

  • Engineering & Computer Science (AREA)
  • Databases & Information Systems (AREA)
  • Theoretical Computer Science (AREA)
  • Data Mining & Analysis (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Information Transfer Between Computers (AREA)

Abstract

The invention discloses a kind of online page loading method, device, storage medium and computer equipments, it is related to information technology field, main purpose is to be able to ascend the loading velocity of the online page, so as to promote the efficiency of online page load, which comprises reception includes the online page load instruction of second edition information;Judge that whether corresponding with the first version content code of local cache second edition information first version information is identical;If not, then the request of difference content Code obtaining is sent to server, the request of difference content Code obtaining carries first version information and second edition information, receive the difference content code of the server feedback, and according to the difference content code and the first version content code, the second edition content code is generated;The second edition content code is executed, loads the online page to realize.The present invention is suitable for the load of the online page.

Description

Online page loading method, device, storage medium and computer equipment
Technical field
The present invention relates to information technology field, more particularly to a kind of online page loading method, device, storage medium and Computer equipment.
Background technique
With the continuous development of information technology, business provider would generally multiterminal barcode scanning and the corresponding page of multiterminal dispensing business Face.In order to promote the loading performance of the page, these pages would generally be in online form at multiple external client containers or end It is run on the browser of end, i.e., client or browser would generally load the online page requested from server.
Currently, client is usually requested in the corresponding full dose of the online page to server when loading to the online page Hold code to be loaded.However, server online page request to be treated is more, if being directed to each online page server Full dose content code is fed back, network needs to transmit a large amount of content code, causes the loading velocity of the online page slower, thus Cause the loading efficiency of the online page lower.
Summary of the invention
In view of this, the present invention provides a kind of online page loading method, device, storage medium and computer equipment, it is main The loading velocity for being to be able to ascend the online page of syllabus, so as to promote the efficiency of online page load.
According to the present invention in a first aspect, providing a kind of online page loading method, comprising:
Reception includes the online page load instruction of second edition information;
Judge second edition information first version letter whether corresponding with the first version content code of local cache Manner of breathing is same;
If it is not, then sending the request of difference content Code obtaining to server, the difference content Code obtaining request is carried There are the first version information and the second edition information, the server is used for according to the first version information, described Second edition information and default difference algorithm calculate the second edition content code of the online page with respect to first version content code Difference content code;
The difference content code of the server feedback is received, and according to the difference content code and described first Release content code generates the second edition content code;
The second edition content code is executed, loads the online page to realize.
Optionally, the difference content code for receiving the server feedback, comprising:
Receive the difference content code and the corresponding station location marker of the difference content code of the server feedback Information;
It is described according to the difference content code and the first version content code, generate the second edition content generation Code, comprising:
The difference content code is fused in the first version content code according to the station location marker information, is obtained To the second edition content code.
Further, described to judge whether the second edition information is corresponding with the first version content code of local cache First version information it is identical after, the method also includes:
If it is not, then executing the first version content code, the online page is loaded to realize.
Further, it is described receive the online page load request for carrying first version information before, the method is also Include:
When receive for the first time include the first version information the online page load instruction when, Xiang Suoshu server First version content code acquisition request is sent, the first version content code acquisition request carries the first version letter Breath;
Receive the first version content code that the server is fed back according to the first version information;
The first version content code is executed, loads the online page to realize, and by the first version content Code cache is to locally.
Second aspect according to the present invention provides another online page loading method, comprising:
The request of client difference content Code obtaining is received, the difference content Code obtaining request carries the online page First version information and second edition information;
According to the first version information and the second edition information, the first version of the online page is inquired respectively Content code and second edition content code;
The difference of the relatively described first version content code of the second edition content code is calculated according to default difference algorithm Different content code;
The difference content code is fed back into the client, the client is used for according to the difference content code With the first version content code of caching, the second edition content code is generated;And the second edition content code is executed, The online page is loaded to realize.
Optionally, the basis is preset difference algorithm and is calculated in the relatively described first version of second edition content code Hold the difference content code of code, comprising:
The second edition content code is divided into multiple code blocks according to preset length;
The multiple code block is matched with the first version content code, and by the first version content generation With the unmatched content code of the multiple code block in code, it is determined as the difference content code.
Optionally, the basis is preset difference algorithm and is calculated in the relatively described first version of second edition content code Hold the difference content code of code, comprising:
The difference content code and the corresponding station location marker of the difference content code are calculated according to default difference algorithm Information;
It is described that the difference content code is fed back into the client, comprising:
The difference content code and the station location marker information are fed back into the client.
Optionally, before the difference content Code obtaining request for receiving client transmission, the method also includes:
Receive the first version content code acquisition request that the client is sent for the first time, the first version content generation Code acquisition request carries the first version information;
Inquire the first content code of the online page according to the first version information, and by the first version Content code feeds back to the client.
The third aspect according to the present invention provides a kind of client, comprising:
Receiving unit, for receive include second edition information the online page load instruction;
Judging unit, for judging whether the second edition information is corresponding with the first version content code of local cache First version information it is identical;
Transmission unit, if the second edition content code corresponding second for the first version information and local cache Version information is not identical, then sends the request of difference content Code obtaining to server, and the difference content Code obtaining request is taken With the first version information and the second edition information, the server is used for according to the first version information, institute Second edition information and default difference algorithm are stated, calculates the second edition content code of the online page with respect to first version content generation The difference content code of code;
The receiving unit is also used to receive the difference content code of the server feedback;
Generation unit, for generating described second according to the difference content code and the first version content code Release content code;
Loading unit loads the online page for executing the second edition content code to realize.
Optionally, the receiving unit, specifically for receiving the difference content code and the institute of the server feedback State the corresponding station location marker information of difference content code;
The generation unit, it is described specifically for being fused to the difference content code according to the station location marker information In first version content code, the second edition content code is obtained.
Further, the loading unit, if can be also used for the second edition of the first version information and local cache The corresponding second edition information of this content code is identical, then executes the second edition content code, with realize load it is described The line page.
Further, the client further include: cache unit,
The transmission unit, be also used to receive for the first time include the first version information the online page load When instruction, Xiang Suoshu server sends first version content code acquisition request, the first version content code acquisition request Carry the first version information;
The receiving unit is also used to receive the first edition that the server is fed back according to the first version information This content code;
The loading unit is also used to execute the second edition content code, loads the online page to realize;
The cache unit, for the second edition content code to be cached to local.
Fourth aspect according to the present invention provides a kind of server, comprising:
Receiving unit, for receiving the request of client difference content Code obtaining, the difference content Code obtaining request Carry the first version information and second edition information of the online page;
Query unit, for inquiring respectively described online according to the first version information and the second edition information The first version content code and second edition content code of the page;
Computing unit, for calculating the relatively described first version of second edition content code according to default difference algorithm The difference content code of content code;
Feedback unit, for the difference content code to be fed back to the client, the client is used for according to institute The first version content code for stating difference content code and caching generates the second edition content code;And execute described Two release content codes load the online page to realize.
Optionally, the computing unit, specifically for being divided into the second edition content code according to preset length Multiple code blocks;The multiple code block is matched with the first version content code, and will be in the first version Hold in code with the unmatched content code of the multiple code block, is determined as the difference content code.
Optionally, the computing unit is specifically used for calculating the difference content code and institute according to default difference algorithm State the corresponding station location marker information of difference content code.
Optionally, the receiving unit is also used to receive the first version content code that the client is sent for the first time Acquisition request, the first version content code acquisition request carry the first version information;
The query unit is also used to inquire the second edition content of the online page according to the second edition information Code;
The feedback unit is also used to the second edition content code feeding back to the client.
5th aspect according to the present invention, provides a kind of storage medium, at least one is stored in the storage medium to hold Row instruction, described execute instruction make processor execute following steps:
Reception includes the online page load instruction of second edition information;
Judge second edition information first version letter whether corresponding with the first version content code of local cache Manner of breathing is same;
If it is not, then sending the request of difference content Code obtaining to server, the difference content Code obtaining request is carried There are the first version information and the second edition information, the server is used for according to the first version information, described Second edition information and default difference algorithm calculate the second edition content code of the online page with respect to first version content code Difference content code;
The difference content code of the server feedback is received, and according to the difference content code and described first Release content code generates the second edition content code;
The second edition content code is executed, loads the online page to realize.
6th aspect according to the present invention, provides a kind of computer equipment, including processor, memory, communication interface and Processor described in communication bus, the memory and the communication interface complete mutual communication by the communication bus, The memory makes the processor execute following steps for storing an at least executable instruction, the executable instruction:
Reception includes the online page load instruction of second edition information;
Judge second edition information first version letter whether corresponding with the first version content code of local cache Manner of breathing is same;
If it is not, then sending the request of difference content Code obtaining to server, the difference content Code obtaining request is carried There are the first version information and the second edition information, the server is used for according to the first version information, described Second edition information and default difference algorithm calculate the second edition content code of the online page with respect to first version content code Difference content code;
The difference content code of the server feedback is received, and according to the difference content code and described first Release content code generates the second edition content code;
The second edition content code is executed, loads the online page to realize.
7th aspect according to the present invention, provides another storage medium, at least one is stored in the storage medium can It executes instruction, described execute instruction makes processor execute following steps:
The request of client difference content Code obtaining is received, the difference content Code obtaining request carries the online page First version information and second edition information;
According to the first version information and the second edition information, the first version of the online page is inquired respectively Content code and second edition content code;
The difference of the relatively described first version content code of the second edition content code is calculated according to default difference algorithm Different content code;
The difference content code is fed back into the client, the client is used for according to the difference content code With the first version content code of caching, the second edition content code is generated;And the second edition content code is executed, The online page is loaded to realize.
Eighth aspect according to the present invention provides another computer equipment, including processor, memory, communication interface Mutual lead to is completed by the communication bus with processor described in communication bus, the memory and the communication interface Letter, the memory make the processor execute following steps for storing an at least executable instruction, the executable instruction:
The request of client difference content Code obtaining is received, the difference content Code obtaining request carries the online page First version information and second edition information;
According to the first version information and the second edition information, the first version of the online page is inquired respectively Content code and second edition content code;
The difference of the relatively described first version content code of the second edition content code is calculated according to default difference algorithm Different content code;
The difference content code is fed back into the client, the client is used for according to the difference content code With the first version content code of caching, the second edition content code is generated;And the second edition content code is executed, The online page is loaded to realize.
The present invention provides a kind of online page loading method, device, storage medium and computer equipment, with current client It usually requests the corresponding full dose content code of the online page to carry out load to server to compare, the present invention includes second in reception Version information the line page load instruction after, can judge the second edition information whether the first version with local cache The corresponding first version information of content code is identical.If the second edition content code of the first version information and local cache Corresponding second edition information is not identical, then sends the request of difference content Code obtaining, the difference content code to server Acquisition request carries the first version information and the second edition information, and the server is used for according to the first edition This information, the second edition information and default difference algorithm calculate the second edition content code of the online page with respect to first The difference content code of release content code.At the same time, the difference content code of the server feedback can be received, According to the difference content code and the first version content code, the second edition content code is generated;And it can hold The row second edition content code loads the online page to realize, to be realized by request difference content file The load of the line page, the content code transmission quantity that can reduce, is able to ascend the loading velocity of the online page, and then is able to ascend The loading efficiency of the online page.
The above description is only an overview of the technical scheme of the present invention, in order to better understand the technical means of the present invention, And it can be implemented in accordance with the contents of the specification, and in order to allow above and other objects of the present invention, feature and advantage can It is clearer and more comprehensible, the followings are specific embodiments of the present invention.
Detailed description of the invention
By reading the following detailed description of the preferred embodiment, various other advantages and benefits are common for this field Technical staff will become clear.The drawings are only for the purpose of illustrating a preferred embodiment, and is not considered as to the present invention Limitation.And throughout the drawings, the same reference numbers will be used to refer to the same parts.In the accompanying drawings:
Fig. 1 shows a kind of flow diagram of online page loading method provided in an embodiment of the present invention;
Fig. 2 shows the flow diagrams of another online page loading method provided in an embodiment of the present invention;
Fig. 3 shows a kind of structural schematic diagram of client provided in an embodiment of the present invention;
Fig. 4 shows the structural schematic diagram of another client provided in an embodiment of the present invention;
Fig. 5 shows a kind of entity structure schematic diagram of computer equipment provided in an embodiment of the present invention.
Fig. 6 shows a kind of structural schematic diagram of server provided in an embodiment of the present invention;
Fig. 7 shows the entity structure schematic diagram of another computer equipment provided in an embodiment of the present invention.
Specific embodiment
Exemplary embodiments of the present disclosure are described in more detail below with reference to accompanying drawings.Although showing the disclosure in attached drawing Exemplary embodiment, it being understood, however, that may be realized in various forms the disclosure without should be by embodiments set forth here It is limited.On the contrary, these embodiments are provided to facilitate a more thoroughly understanding of the present invention, and can be by the scope of the present disclosure It is fully disclosed to those skilled in the art.
As stated in the background art, currently, when loading to the online page, client usually requests online page to server The corresponding full dose content code in face is loaded.However, server online page request to be treated is more, if for each Online page server feeds back full dose content code, and network needs to transmit a large amount of content code, causes adding for the online page Load speed is slower, and the loading efficiency so as to cause the online page is lower.
In order to solve the above-mentioned technical problem, it the embodiment of the invention provides a kind of online page loading method, can apply In client, as shown in Figure 1, which comprises
101, reception includes the online page load instruction of second edition information.
For the embodiment of the present invention, the online page load instruction can for user need to access the second edition When the line page, by click perhaps trigger it is that the online page link of the second edition is triggered or by search input frame The uniform resource locator (Uniform Resource Locator, URL) of the online page of the middle input second edition is simultaneously Click what search button was triggered.The second edition information can be the version number of the online page second edition, described Version number can be v1.0.0, v1.0.1 etc..
102, judge the second edition information first edition whether corresponding with the first version content code of local cache This information is identical.If so, thening follow the steps 103;If it is not, thening follow the steps 106.
Wherein, when the first version content code can access the online page of first version for the first time for user, institute State user end to server request.The first version content code is used to render and load the online page of first version. The first version content code may include related cascading style sheets of the online page in first version (Cascading Style Sheets, CSS) and static resource, the static resource can be Javascript.The static state Resource may include page framework, page pictures, input frame etc..If the second edition information and the first version information phase Together, then illustrate that user requests access to the online page of first version, if the second edition information and the first version information Difference then illustrates that user requests access to the online page of the second edition, and the second edition information can be for than the first edition The new version information of this information, the online page of the second edition can be the online page of update of first version, specifically, described The online page of the second edition change request can be updated the online page of the first version according to.Example Such as, technical staff is based on newly increased requirement, increases picture or newly-increased cascading style sheets etc. newly on the online page of first version.
103, the request of difference content Code obtaining is sent to server.
Wherein, the difference content Code obtaining request carries the first version information and second edition letter Breath, for example, can be carried in difference content Code obtaining request: v2/filename-v1.In order to promote difference content generation The calculating speed of code, the server can be nginx server, nginx server can for it is a it is free, open source, High performance HTTP server and Reverse Proxy, the server can be used for according to the first version information, institute Second edition information and default difference algorithm are stated, calculates the second edition content code of the online page with respect to first version content generation The difference content code of code.The default difference algorithm can be to divide the second edition content code according to preset length For multiple code blocks;It scrolls through in the first version content code with the presence or absence of the multiple code block, and by described the The code block being not present in one release content code is determined as the algorithm of the difference content code.For example, according to described default Difference algorithm calculates difference content code { m:true, c:[...] } of the second edition content with respect to first version content code.With The prior art is compared to the code of server demand file rank, and the embodiment of the present invention is by requesting difference content generation to server Code, the other code load of character level that can be realized static resource update, and can optimize the load of different editions static resource, from And it is able to ascend the loading velocity of the online page.
104, the difference content code of the server feedback is received, and according to the difference content code and described First version content code generates the second edition content code.
It, can be by the way that the difference content code and the first version content code be carried out for the embodiment of the present invention Fusion, to obtain the second edition content code.For example, the difference content code of the server feedback be m:true, c: [...] }, by described in m:true, c:[...] } it is fused on the corresponding position of the first version content code, it can Obtain the first version content code.
105, the second edition content code is executed, loads the online page to realize.
106, the first version content code is executed, loads the online page to realize.
A kind of online page loading method provided in an embodiment of the present invention is usually requested to server with current client The corresponding full dose content code of the line page carries out load and compares, and the present invention is in the online page that reception includes second edition information Load instruction after, can judge the second edition information whether with the first version content code corresponding first of local cache Version information is identical.If first version information second edition information corresponding with the second edition content code of local cache It is not identical, then the request of difference content Code obtaining is sent to server, the difference content Code obtaining request carries described First version information and the second edition information, the server are used for according to the first version information, the second edition This information and default difference algorithm calculate difference of the second edition content code with respect to first version content code of the online page Content code.At the same time, the difference content code that the server feedback can be received, according to the difference content generation Code and the first version content code, generate the second edition content code;And it is able to carry out the second edition content Code loads the online page to realize, to can be dropped by requesting difference content file to realize the load of the online page Low content code transmission quantity, is able to ascend the loading velocity of the online page, and then is able to ascend the loading efficiency of the online page.
Further, in order to better illustrate the process of above-mentioned online page loading method, as to above-described embodiment Refinement and extension, the embodiment of the invention provides several alternative embodiments, but not limited to this, it is specific as follows shown in:
In an alternative embodiment of the invention, the step 104 be can specifically include: receive the server feedback The difference content code and the corresponding station location marker information of the difference content code;According to the station location marker information by institute It states difference content code to be fused in the first version content code, obtains the second edition content code.Wherein, described Station location marker information can be used for identifying position of the difference content code in the second edition content code.
In another alternative embodiment of the invention, the method also includes: it include described when receiving for the first time When the online page of one version information loads instruction, Xiang Suoshu server sends first version content code acquisition request, described First version content code acquisition request carries the first version information;The server is received according to the first version The first version content code of information feedback;The first version content code is executed, loads the online page to realize Face, and the first version content code is cached to local.
Further, the embodiment of the invention provides another online page loading method, it can be applied to server, such as Shown in Fig. 2, which comprises
201, the difference content Code obtaining request that client is sent is received.
Wherein, the difference content Code obtaining request carries the first version information and second edition letter of the online page Breath.The difference content Code obtaining request can be the client in the first version information and institute for detecting local cache State second edition information it is not identical when be sent to the server.The server is obtained receiving the difference content code After taking request, the difference content Code obtaining can be requested to parse, to extract the first version information and second Version information.For example, can request to parse to difference content Code obtaining url, v1 and v2 Liang Ge version number parameter is obtained.
202, according to the first version information and the second edition information, the first of the online page is inquired respectively Release content code and second edition content code.
It should be noted that the first version content code and the first version content code can be technical staff In the content code developed according to page need, and it is uploaded to the server.
203, the relatively described first version content code of second edition content code is calculated according to default difference algorithm Difference content code.
204, the difference content code is fed back into the client.
Wherein, the client can be used for the first version content code according to the difference content code and caching, Generate the second edition content code;And the second edition content code is executed, the online page is loaded to realize.
Further, in order to better illustrate the process of above-mentioned online page loading method, as to above-described embodiment Refinement and extension, the embodiment of the invention provides several alternative embodiments, but not limited to this, it is specific as follows shown in:
In an alternative embodiment of the invention, the step 203 be can specifically include: according to preset length by described Two release content codes are divided into multiple code blocks;It scrolls through in the first version content code with the presence or absence of the multiple Code block, and the code block that will be not present in the first version content code, are determined as the difference content code.It is described pre- What if length can need to be arranged according to user, it system default mode setting, the embodiment of the present invention can not be done herein according to It limits.For example, the preset length can be 100.For example, the second edition content code divide available chunk0, Chunk1, chunk2 ..., chunkN, can in first version content code described in look up by scrolling whether there is chunk0, Chunk1, chunk2 ..., chunkN, if in first version content code be not present chunk1 and chunk100, chunk1 and Chunk100 can be difference content code.
In another alternative embodiment of the invention, the step 203 specifically can also include: according to default difference algorithm Calculate the difference content code and the corresponding station location marker information of the difference content code.It specifically, can be according to default The second edition content code is divided into multiple code blocks by length, and records the corresponding position of the multiple code block Mark.Corresponding, the step 204 can specifically include: the difference content code and the station location marker information are fed back To the client.
In another alternative embodiment of the invention, the method also includes: receive what the client was sent for the first time First version content code acquisition request, the first version content code acquisition request carry the first version information; Inquire the first content code of the online page according to the first version information, and by the first version content code Feed back to the client.
Further, as the specific implementation of Fig. 1, the embodiment of the invention provides a kind of clients, as shown in figure 3, institute Stating client includes: receiving unit 31, judging unit 32, transmission unit 33, generation unit 34 and loading unit 35.
The receiving unit 31 can be used for the online page load instruction that reception includes second edition information.It is described Receiving unit 31 is that reception includes that the online page of second edition information loads the main functional modules of instruction in this client.
The judging unit 32, can be used for judging the second edition information whether in the first version of local cache It is identical to hold the corresponding first version information of code.The judging unit 32 is to judge that the second edition information is in this client The identical main functional modules of no first version information corresponding with the first version content code of local cache.
The transmission unit 33, if can be used for the second edition content code of the first version information and local cache Corresponding second edition information is not identical, then sends the request of difference content Code obtaining, the difference content code to server Acquisition request carries the first version information and the second edition information, and the server is used for according to the first edition This information, the second edition information and default difference algorithm calculate the second edition content code of the online page with respect to first The difference content code of release content code.If the transmission unit 33 is the first version information and local in this client The corresponding second edition information of the second edition content code of caching is not identical, then sends difference content Code obtaining to server The main functional modules of request.
The receiving unit 31 can be also used for the difference content code for receiving the server feedback.It is described to connect Receive the main functional modules that the difference content code of the server feedback is received in unit 31 or this client.
The generation unit 34 can be used for according to the difference content code and the first version content code, raw At the second edition content code.The generation unit 34 is in this client according to the difference content code and described One release content code generates the main functional modules of the second edition content code.
The loading unit 35 can be used for executing the second edition content code, load the online page to realize Face.The loading unit 35 is that the second edition content code is executed in this client, loads the online page to realize The loading unit 35 can be used for executing the second edition content code, load the online page to realize.
In concrete application scene, the receiving unit 31 specifically can be used for receiving the described of the server feedback Difference content code and the corresponding station location marker information of the difference content code;
The generation unit 34 specifically can be used for being merged the difference content code according to the station location marker information Into the first version content code, the second edition content code is obtained.
The loading unit 35, if can be also used for the second edition content generation of the first version information and local cache The corresponding second edition information of code is identical, then executes the second edition content code, loads the online page to realize.
For the embodiment of the present invention, the client further include: cache unit 36, as shown in Figure 4.
The transmission unit 33, can be also used for receiving for the first time include the first version information online page When the load instruction of face, Xiang Suoshu server sends first version content code acquisition request, and the first version content code obtains Request is taken to carry the first version information.
The receiving unit 31 can be also used for receiving the server according to first version information feedback First version content code.
The loading unit 35 can be also used for executing the second edition content code, to realize that load is described online The page.
The cache unit 36 can be used for the second edition content code being cached to local.The cache unit 36 be that the second edition content code is cached to local in this client.
It should be noted that other of each functional module involved by a kind of client provided in an embodiment of the present invention are accordingly retouched It states, can be with reference to the corresponding description of method shown in Fig. 1, details are not described herein.
Based on above-mentioned method as shown in Figure 1, correspondingly, the embodiment of the invention also provides a kind of storage medium, it is described to deposit Be stored with an at least executable instruction in storage media, described execute instruction makes processor execute following steps: reception includes the The online page of two version informations loads instruction;Judge the second edition information whether the first version content with local cache The corresponding first version information of code is identical;It is requested if it is not, then sending difference content Code obtaining to server, in the difference Hold Code obtaining request and carry the first version information and the second edition information, the server is used for according to First version information, the second edition information and default difference algorithm calculate the second edition content code phase of the online page To the difference content code of first version content code;Receive the difference content code of the server feedback, and according to The difference content code and the first version content code, generate the second edition content code;Execute described second Release content code loads the online page to realize.
Based on the embodiment of above-mentioned method as shown in Figure 1 and client as shown in Figure 3, the embodiment of the invention also provides one Kind computer equipment, as shown in figure 5, processor (processor) 41, communication interface (Communications Interface) 42, memory (memory) 43 and communication bus 44.Wherein: processor 41, communication interface 42 and memory 43 pass through Communication bus 44 completes mutual communication.Communication interface 44, for other equipment such as client or other servers etc. Network element communication.Processor 41 can specifically execute the correlation in the conversion method embodiment of above-mentioned data for executing program Step.Specifically, program may include program code, which includes computer operation instruction.Processor 41 may be Central processor CPU or specific integrated circuit ASIC (Application Specific Integrated Circuit), or it is arranged to implement one or more integrated circuits of the embodiment of the present invention.
The one or more processors that terminal includes can be same type of processor, such as one or more CPU;? It can be different types of processor, such as one or more CPU and one or more ASIC.Memory 43, for storing journey Sequence.Memory 43 may include high speed RAM memory, it is also possible to further include nonvolatile memory (non-volatile Memory), a for example, at least magnetic disk storage.Program specifically can be used for so that processor 41 executes following operation: receive It include the online page load instruction of second edition information;Judge the second edition information whether first with local cache The corresponding first version information of release content code is identical;If it is not, then sending the request of difference content Code obtaining, institute to server It states the request of difference content Code obtaining and carries the first version information and the second edition information, the server is used for According to the first version information, the second edition information and default difference algorithm, in the second edition for calculating the online page Hold difference content code of the code with respect to first version content code;Receive the difference content generation of the server feedback Code, and according to the difference content code and the first version content code, generate the second edition content code;It executes The second edition content code loads the online page to realize.
Further, as the specific implementation of Fig. 2, the embodiment of the invention provides a kind of servers, as shown in fig. 6, institute Stating server includes: receiving unit 51, query unit 52, computing unit 53 and feedback unit 54.
The receiving unit 51 can be used for receiving the request of client difference content Code obtaining, the difference content generation Code acquisition request carries the first version information and second edition information of the online page;The receiving unit 51 is book server The middle main functional modules for receiving the request of client difference content Code obtaining.
The query unit 52 can be used for being looked into respectively according to the first version information and the second edition information Ask the first version content code and second edition content code of the online page;The query unit 52 is book server root According to the first version information and the second edition information, inquire respectively the online page first version content code and The main functional modules of second edition content code.
The computing unit 53 can be used for calculating the second edition content code with respect to institute according to default difference algorithm State the difference content code of first version content code.The computing unit 33 is in book server according to default difference algorithm meter Calculate the main functional modules of the difference content code of the relatively described first version content code of the second edition content code.
The feedback unit 54 can be used for the difference content code feeding back to the client, the client For the first version content code according to the difference content code and caching, the second edition content code is generated;And The second edition content code is executed, loads the online page to realize.The feedback unit 54 is will in book server The difference content code feeds back to the main functional modules of the client.
In concrete application scene, the computing unit 53 specifically can be used for the second edition according to preset length This content code is divided into multiple code blocks;The multiple code block is matched with the first version content code, and , with the unmatched content code of the multiple code block, the difference content generation will be determined as in the first version content code Code.
The computing unit 53 specifically can be used for calculating the difference content code and described according to presetting difference algorithm The corresponding station location marker information of difference content code.
The receiving unit 51, the first version content code that can be also used for receiving client transmission for the first time obtain Request is taken, the first version content code acquisition request carries the first version information.The receiving unit 51 is this The main functional modules for the second edition content code acquisition request that the client is sent for the first time are received in server.
The query unit 52 is also used to be inquired according to the second edition information in the second edition of the online page Hold code.The query unit 52 is to inquire the second edition of the online page in book server according to the second edition information The main functional modules of this content code.
The feedback unit 54 can be also used for the second edition content code feeding back to the client.
It should be noted that other of each functional module involved by a kind of server provided in an embodiment of the present invention are accordingly retouched It states, can be with reference to the corresponding description of method shown in Fig. 1, details are not described herein.
Based on above-mentioned method as shown in Figure 2, correspondingly, the embodiment of the invention also provides another storage medium, it is described An at least executable instruction is stored in storage medium, described execute instruction makes processor execute following steps: receiving client The difference content Code obtaining of transmission is requested, and the difference content Code obtaining request carries the first version letter of the online page Breath and second edition information;According to the first version information and the second edition information, the online page is inquired respectively First version content code and second edition content code;The second edition content code is calculated according to default difference algorithm The difference content code of the relatively described first version content code;The difference content code is fed back into the client, institute Client is stated for the first version content code according to the difference content code and caching, generates the second edition content Code;And the second edition content code is executed, the online page is loaded to realize.
Based on the embodiment of above-mentioned method as shown in Figure 2 and server as shown in Figure 5, the embodiment of the invention also provides another A kind of computer equipment, as shown in fig. 7, processor (processor) 61, communication interface (Communications Interface) 62, memory (memory) 63 and communication bus 64.Wherein: processor 61, communication interface 62, Yi Jicun Reservoir 63 completes mutual communication by communication bus 64.Communication interface 64, for other equipment such as client or its The network element of its server etc. communicates.Processor 61, for executing program, the conversion method that can specifically execute above-mentioned data is implemented Correlation step in example.Specifically, program may include program code, which includes computer operation instruction.Processing Device 61 may be central processor CPU or specific integrated circuit ASIC (Application Specific Integrated Circuit), or be arranged to implement one or more integrated circuits of the embodiment of the present invention.
The one or more processors that terminal includes can be same type of processor, such as one or more CPU;? It can be different types of processor, such as one or more CPU and one or more ASIC.Memory 43, for storing journey Sequence.Memory 43 may include high speed RAM memory, it is also possible to further include nonvolatile memory (non-volatile Memory), a for example, at least magnetic disk storage.Program specifically can be used for so that processor 41 executes following operation: receive The difference content Code obtaining request that client is sent, the difference content Code obtaining request carry the first of the online page Version information and second edition information;According to the first version information and the second edition information, respectively inquiry it is described The first version content code and second edition content code of the line page;It is calculated in the second edition according to default difference algorithm Hold the difference content code of the relatively described first version content code of code;The difference content code is fed back into the client End, the client are used for the first version content code according to the difference content code and caching, generate the second edition This content code;And the second edition content code is executed, the online page is loaded to realize.
According to the technical solution of the present invention, it can be instructed in the online page load that reception includes second edition information Afterwards, it can judge second edition information first version information whether corresponding with the first version content code of local cache It is identical.If first version information second edition information corresponding with the second edition content code of local cache is not identical, The request of difference content Code obtaining then is sent to server, the difference content Code obtaining request carries the first version Information and the second edition information, the server be used for according to the first version information, the second edition information and Default difference algorithm, calculates difference content generation of the second edition content code with respect to first version content code of the online page Code.At the same time, the difference content code that the server feedback can be received, according to the difference content code and institute First version content code is stated, the second edition content code is generated;And it is able to carry out the second edition content code, with It realizes and loads the online page, so that be can reduce is interior by requesting difference content file to realize the load of the online page Hold code transfer amount, is able to ascend the loading velocity of the online page, and then be able to ascend the loading efficiency of the online page.
In the above-described embodiments, it all emphasizes particularly on different fields to the description of each embodiment, there is no the portion being described in detail in some embodiment Point, reference can be made to the related descriptions of other embodiments.
It is understood that the correlated characteristic in the above method and device can be referred to mutually.In addition, in above-described embodiment " first ", " second " etc. be and not represent the superiority and inferiority of each embodiment for distinguishing each embodiment.
It is apparent to those skilled in the art that for convenience and simplicity of description, the system of foregoing description, The specific work process of device and unit, can refer to corresponding processes in the foregoing method embodiment, and details are not described herein.
Algorithm and display are not inherently related to any particular computer, virtual system, or other device provided herein. Various general-purpose systems can also be used together with teachings based herein.As described above, it constructs required by this kind of system Structure be obvious.In addition, the present invention is also not directed to any particular programming language.It should be understood that can use various Programming language realizes summary of the invention described herein, and the description done above to language-specific is to disclose this hair Bright preferred forms.
In the instructions provided here, numerous specific details are set forth.It is to be appreciated, however, that implementation of the invention Example can be practiced without these specific details.In some instances, well known method, structure is not been shown in detail And technology, so as not to obscure the understanding of this specification.
Similarly, it should be understood that in order to simplify the disclosure and help to understand one or more of the various inventive aspects, Above in the description of exemplary embodiment of the present invention, each feature of the invention is grouped together into single implementation sometimes In example, figure or descriptions thereof.However, the disclosed method should not be interpreted as reflecting the following intention: i.e. required to protect Shield the present invention claims features more more than feature expressly recited in each claim.More precisely, as following Claims reflect as, inventive aspect is all features less than single embodiment disclosed above.Therefore, Thus the claims for following specific embodiment are expressly incorporated in the specific embodiment, wherein each claim itself All as a separate embodiment of the present invention.
Those skilled in the art will understand that can be carried out adaptively to the module in the equipment in embodiment Change and they are arranged in one or more devices different from this embodiment.It can be the module or list in embodiment Member or component are combined into a module or unit or component, and furthermore they can be divided into multiple submodule or subelement or Sub-component.Other than such feature and/or at least some of process or unit exclude each other, it can use any Combination is to all features disclosed in this specification (including adjoint claim, abstract and attached drawing) and so disclosed All process or units of what method or apparatus are combined.Unless expressly stated otherwise, this specification is (including adjoint power Benefit require, abstract and attached drawing) disclosed in each feature can carry out generation with an alternative feature that provides the same, equivalent, or similar purpose It replaces.
In addition, it will be appreciated by those of skill in the art that although some embodiments described herein include other embodiments In included certain features rather than other feature, but the combination of the feature of different embodiments mean it is of the invention Within the scope of and form different embodiments.For example, in the following claims, embodiment claimed is appointed Meaning one of can in any combination mode come using.
Various component embodiments of the invention can be implemented in hardware, or to run on one or more processors Software module realize, or be implemented in a combination thereof.It will be understood by those of skill in the art that can be used in practice Microprocessor or digital signal processor (DSP) realize one in client according to an embodiment of the present invention or server The some or all functions of a little or whole components.The present invention is also implemented as executing method as described herein Some or all device or device programs (for example, computer program and computer program product).Such realization Program of the invention can store on a computer-readable medium, or may be in the form of one or more signals.This The signal of sample can be downloaded from an internet website to obtain, and is perhaps provided on the carrier signal or mentions in any other forms For.
It should be noted that the above-mentioned embodiments illustrate rather than limit the invention, and ability Field technique personnel can be designed alternative embodiment without departing from the scope of the appended claims.In the claims, Any reference symbol between parentheses should not be configured to limitations on claims.Word "comprising" does not exclude the presence of not Element or step listed in the claims.Word "a" or "an" located in front of the element does not exclude the presence of multiple such Element.The present invention can be by means of including the hardware of several different elements and being come by means of properly programmed computer real It is existing.In the unit claims listing several devices, several in these devices can be through the same hardware branch To embody.The use of word first, second, and third does not indicate any sequence.These words can be explained and be run after fame Claim.

Claims (10)

1. a kind of online page loading method characterized by comprising
Reception includes the online page load instruction of second edition information;
Judge second edition information first version information phase whether corresponding with the first version content code of local cache Together;
If it is not, then sending the request of difference content Code obtaining to server, the difference content Code obtaining request is carried First version information and the second edition information are stated, the server is used for according to the first version information, described second Version information and default difference algorithm calculate difference of the second edition content code with respect to first version content code of the online page Different content code;
The difference content code of the server feedback is received, and according to the difference content code and the first version Content code generates the second edition content code;
The second edition content code is executed, loads the online page to realize.
2. the method according to claim 1, wherein the difference content for receiving the server feedback Code, comprising:
Receive the difference content code and the corresponding station location marker information of the difference content code of the server feedback;
It is described that the second edition content code is generated according to the difference content code and the first version content code, Include:
The difference content code is fused in the first version content code according to the station location marker information, obtains institute State second edition content code.
3. a kind of online page loading method characterized by comprising
The difference content Code obtaining request that client is sent is received, the difference content Code obtaining request carries online page The first version information and second edition information in face;
According to the first version information and the second edition information, the first version content of the online page is inquired respectively Code and second edition content code;
In the difference for calculating the relatively described first version content code of the second edition content code according to default difference algorithm Hold code;
The difference content code is fed back into the client, the client is used for gentle according to the difference content code The first version content code deposited generates the second edition content code;And the second edition content code is executed, with reality Now load the online page.
4. a kind of client characterized by comprising
Receiving unit, for receive include second edition information the online page load instruction;
Judging unit, for judging the second edition information whether corresponding with the first version content code of local cache One version information is identical;
Transmission unit, if for the first version information second edition corresponding with the second edition content code of local cache Information is not identical, then sends the request of difference content Code obtaining to server, and the difference content Code obtaining request carries The first version information and the second edition information, the server are used for according to the first version information, described the Two version informations and default difference algorithm calculate the second edition content code of the online page with respect to first version content code Difference content code;
The receiving unit is also used to receive the difference content code of the server feedback;
Generation unit, for generating the second edition according to the difference content code and the first version content code Content code;
Loading unit loads the online page for executing the second edition content code to realize.
5. client according to claim 4, which is characterized in that
The receiving unit, the difference content code and the difference content generation specifically for the reception server feedback The corresponding station location marker information of code;
The generation unit, specifically for the difference content code is fused to described first according to the station location marker information In release content code, the second edition content code is obtained.
6. a kind of server characterized by comprising
Receiving unit, for receiving the request of client difference content Code obtaining, the difference content Code obtaining request is carried There are the first version information and second edition information of the online page;
Query unit, for inquiring the online page respectively according to the first version information and the second edition information First version content code and second edition content code;
Computing unit, for calculating the relatively described first version content of second edition content code according to default difference algorithm The difference content code of code;
Feedback unit, for the difference content code to be fed back to the client, the client is used for according to the difference The first version content code of different content code and caching generates the second edition content code;And execute the second edition This content code loads the online page to realize.
7. a kind of storage medium is stored thereon with computer program, an at least executable instruction is stored in the storage medium, Described execute instruction makes processor execute the corresponding behaviour of online page loading method such as of any of claims 1-2 Make.
8. a kind of computer equipment, including processor described in processor, memory, communication interface and communication bus, the storage Device and the communication interface complete mutual communication by the communication bus, and the memory can be held for storing at least one Row instruction, the executable instruction execute the processor such as online page load of any of claims 1-2 The corresponding operation of method.
9. a kind of storage medium is stored thereon with computer program, an at least executable instruction is stored in the storage medium, Described execute instruction makes processor execute the corresponding operation of online page loading method as claimed in claim 3.
10. a kind of computer equipment, including processor described in processor, memory, communication interface and communication bus, the storage Device and the communication interface complete mutual communication by the communication bus, and the memory can be held for storing at least one Row instruction, it is corresponding that the executable instruction makes the processor execute online page loading method as claimed in claim 3 Operation.
CN201910286582.7A 2019-04-10 2019-04-10 Online page loading method, device, storage medium and computer equipment Pending CN110162725A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201910286582.7A CN110162725A (en) 2019-04-10 2019-04-10 Online page loading method, device, storage medium and computer equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201910286582.7A CN110162725A (en) 2019-04-10 2019-04-10 Online page loading method, device, storage medium and computer equipment

Publications (1)

Publication Number Publication Date
CN110162725A true CN110162725A (en) 2019-08-23

Family

ID=67639030

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201910286582.7A Pending CN110162725A (en) 2019-04-10 2019-04-10 Online page loading method, device, storage medium and computer equipment

Country Status (1)

Country Link
CN (1) CN110162725A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110674435A (en) * 2019-09-27 2020-01-10 网易(杭州)网络有限公司 Page access method, server, terminal, electronic equipment and readable storage medium

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6631520B1 (en) * 1999-05-14 2003-10-07 Xilinx, Inc. Method and apparatus for changing execution code for a microcontroller on an FPGA interface device
CN107729041A (en) * 2017-07-26 2018-02-23 上海壹账通金融科技有限公司 The hot update method of application program, device, terminal and storage medium
CN107783795A (en) * 2017-07-26 2018-03-09 上海壹账通金融科技有限公司 Application program launching method, device, computer equipment and storage medium
CN107784086A (en) * 2017-10-09 2018-03-09 中国平安人寿保险股份有限公司 A kind of loading method of webpage, terminal device and computer-readable recording medium
CN109471988A (en) * 2018-10-12 2019-03-15 平安科技(深圳)有限公司 Page info update method, device, computer equipment and storage medium

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6631520B1 (en) * 1999-05-14 2003-10-07 Xilinx, Inc. Method and apparatus for changing execution code for a microcontroller on an FPGA interface device
CN107729041A (en) * 2017-07-26 2018-02-23 上海壹账通金融科技有限公司 The hot update method of application program, device, terminal and storage medium
CN107783795A (en) * 2017-07-26 2018-03-09 上海壹账通金融科技有限公司 Application program launching method, device, computer equipment and storage medium
CN107784086A (en) * 2017-10-09 2018-03-09 中国平安人寿保险股份有限公司 A kind of loading method of webpage, terminal device and computer-readable recording medium
CN109471988A (en) * 2018-10-12 2019-03-15 平安科技(深圳)有限公司 Page info update method, device, computer equipment and storage medium

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
瞿苏: "基于HTML5 构建离线Web应用的研究与探讨", 《佛山科学技术学院学报(自然科学版)》 *

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110674435A (en) * 2019-09-27 2020-01-10 网易(杭州)网络有限公司 Page access method, server, terminal, electronic equipment and readable storage medium

Similar Documents

Publication Publication Date Title
CN106528432B (en) The construction method and device of test scene data bury a test method
CN106484383B (en) Page rendering method, device and equipment
CN108574604B (en) Test method and device
US9690568B2 (en) Client-side script bundle management system
US8850307B2 (en) Method and apparatus for receiving display limited web page content
US9378298B2 (en) User influenced asynchronous module definition loader
CN109032797A (en) For providing the method and apparatus of web page access
US10158691B2 (en) Method and apparatus for providing network resources at intermediary server
US20160307256A1 (en) Adapting legacy endpoints to modern apis
CN109254854A (en) Asynchronous invoking method, computer installation and storage medium
CN103475744A (en) Resource downloading method, device and system on basis of Web application
CN111931100A (en) Request processing system, method, device, electronic equipment and computer readable medium
CN108595457A (en) A kind of rendering intent and device of the waterfall stream page
CN108924183B (en) Method and device for processing information
CN113382083A (en) Webpage screenshot method and device
CN113452733A (en) File downloading method and device
CN110618768B (en) Information presentation method and device
CN102769625A (en) Client-side Cookie information acquisition method and device
CN110162725A (en) Online page loading method, device, storage medium and computer equipment
CN116368786A (en) Processing deferrable network requests
US9253279B2 (en) Preemptive caching of data
CN111182053A (en) Method and device for downloading file, computer storage medium and terminal
US20140032726A1 (en) Method and apparatus for configuring social networking site sharing functions
CN110647327A (en) Method and device for dynamic control of user interface based on card
CN112948138A (en) Method and device for processing message

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
RJ01 Rejection of invention patent application after publication

Application publication date: 20190823

RJ01 Rejection of invention patent application after publication