CN104243584B - The method and apparatus for obtaining resource - Google Patents

The method and apparatus for obtaining resource Download PDF

Info

Publication number
CN104243584B
CN104243584B CN201410476111.XA CN201410476111A CN104243584B CN 104243584 B CN104243584 B CN 104243584B CN 201410476111 A CN201410476111 A CN 201410476111A CN 104243584 B CN104243584 B CN 104243584B
Authority
CN
China
Prior art keywords
resource
webpage
information
request message
preset protocol
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.)
Active
Application number
CN201410476111.XA
Other languages
Chinese (zh)
Other versions
CN104243584A (en
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.)
Conew Network Technology Beijing Co Ltd
Original Assignee
Conew Network Technology Beijing 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 Conew Network Technology Beijing Co Ltd filed Critical Conew Network Technology Beijing Co Ltd
Priority to CN201410476111.XA priority Critical patent/CN104243584B/en
Publication of CN104243584A publication Critical patent/CN104243584A/en
Application granted granted Critical
Publication of CN104243584B publication Critical patent/CN104243584B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Abstract

The present invention proposes a kind of method and apparatus for obtaining resource, and the method for the acquisition resource includes obtaining the info web for the webpage to be accessed, and the info web includes the information for the resource to be obtained;Preset protocol information whether is included in the information for the resource to be obtained described in judgement, and when comprising preset protocol information, is sent for the request message from local acquisition resource;Receive the resource to be obtained described in locally obtain.This method can improve the speed for obtaining resource.

Description

The method and apparatus for obtaining resource
Technical field
The present invention relates to communication technical field, more particularly to a kind of method and apparatus for obtaining resource.
Background technology
With the popularization of mobile phone, user can be surfed the web webpage using mobile phone browser.The webpage that user browses can be with Website including news or novel class.For the ease of reading, mobile phone browser typically both provides reading model this function. , it is necessary to access some resources to aid in showing during reading model shows content.
It is that the resource needed for reading model is obtained from server in correlation technique.But this mode due to need from Resource is obtained in server, acquisition speed is slower.
The content of the invention
It is contemplated that at least solves one of technical problem in correlation technique to a certain extent.
Therefore, it is an object of the present invention to propose a kind of method for obtaining resource, this method can improve acquisition money The speed in source.
It is another object of the present invention to propose a kind of device for obtaining resource.
To reach above-mentioned purpose, the method for the acquisition resource that first aspect present invention embodiment proposes, including:Acquisition will visit The info web for the webpage asked, the info web include the information for the resource to be obtained;The resource to be obtained described in judgement Preset protocol information whether is included in information, and when comprising preset protocol information, is sent for obtaining asking for resource from local Seek message;Receive the resource to be obtained described in locally obtain.
First aspect present invention embodiment propose acquisitions resource method, by judgement the resource to be obtained information in During comprising preset protocol information, send for the request message from local acquisition resource, resource can be obtained from local, relative to Resource is obtained from server, is effectively improved the speed for obtaining resource.
To reach above-mentioned purpose, the device for the acquisition resource that second aspect of the present invention embodiment proposes, including:Obtain mould Block, for obtaining the info web for the webpage to be accessed, the info web includes the information for the resource to be obtained;Handle mould Block, whether preset protocol information is included in the information for judging the resource to be obtained, and including preset protocol information When, send for the request message from local acquisition resource;Receiving module, for receiving what is obtained described in locally obtain Resource.
Second aspect of the present invention embodiment propose acquisitions resource device, by judgement the resource to be obtained information in During comprising preset protocol information, send for the request message from local acquisition resource, resource can be obtained from local, relative to Resource is obtained from server, is effectively improved the speed for obtaining resource.
To reach above-mentioned purpose, the device for the acquisition resource that third aspect present invention embodiment proposes, including:Housing, place Device, memory, circuit board and power circuit are managed, wherein, circuit board is placed in the interior volume that housing surrounds, processor and storage Device is set on circuit boards;Power circuit, for each circuit or the device power supply for test device;Memory can for storage Configuration processor code;The executable program code that processor is stored by reading in memory is run and executable program code Corresponding program, for performing following steps:The info web for the webpage to be accessed is obtained, the info web includes obtaining The information of the resource taken;Whether preset protocol information is included in the information for the resource to be obtained described in judgement, and comprising default During protocol information, send for the request message from local acquisition resource;Receive the resource to be obtained described in locally obtain.
Third aspect present invention embodiment propose acquisitions resource device, by judgement the resource to be obtained information in During comprising preset protocol information, send for the request message from local acquisition resource, resource can be obtained from local, relative to Resource is obtained from server, is effectively improved the speed for obtaining resource.
The additional aspect of the present invention and advantage will be set forth in part in the description, and will partly become from the following description Obtain substantially, or recognized by the practice of the present invention.
Brief description of the drawings
Of the invention above-mentioned and/or additional aspect and advantage will become from the following description of the accompanying drawings of embodiments Substantially and it is readily appreciated that, wherein:
Fig. 1 is the schematic flow sheet of the method for the acquisition resource that one embodiment of the invention proposes;
Fig. 2 is the schematic flow sheet of the method for the acquisition resource that another embodiment of the present invention proposes;
Fig. 3 is the schematic flow sheet of the method for the acquisition resource that another embodiment of the present invention proposes;
Fig. 4 is the structural representation of the device for the acquisition resource that another embodiment of the present invention proposes;
Fig. 5 is the structural representation of the device for the acquisition resource that another embodiment of the present invention proposes.
Embodiment
Embodiments of the invention are described below in detail, the example of the embodiment is shown in the drawings, wherein from beginning to end Same or similar label represents same or similar element or the element with same or like function.Below with reference to attached The embodiment of figure description is exemplary, is only used for explaining the present invention, and is not considered as limiting the invention.On the contrary, this All changes that the embodiment of invention includes falling into the range of the spirit and intension of attached claims, modification and equivalent Thing.
Fig. 1 is the schematic flow sheet of the method for the acquisition resource that one embodiment of the invention proposes, this method includes:
S11:The info web for the webpage to be accessed is obtained, the info web includes the information for the resource to be obtained.
When user needs to access webpage, the net for the webpage to be accessed that browser application module can input according to user Location, the net for obtaining the webpage to be accessed is sent to server by browser kernel parsing module and browser mixed-media network modules mixed-media The request message of page information, after server receives the request message, the info web can be passed through browser mixed-media network modules mixed-media It is sent to browser kernel parsing module.
Info web can include HTML (HyperText Markup language, html) file etc..
The information for the resource to be obtained can be included in info web, for example, ima labels are included in html files, should Ima labels are used to show picture to be obtained, and the information for the picture to be obtained is preserved in the ima labels.
S12:Whether preset protocol information is included in the information for the resource to be obtained described in judgement, and including preset protocol During information, send for the request message from local acquisition resource.
When to obtain resource from local, preset protocol information can be included in the information for the resource to be obtained, for example, Preset protocol information is included in ima labels, preset protocol is, for example, Extension, then can in ima labels with Extension//beginning.
When including preset protocol information in the information for the resource to be obtained, browser kernel parsing module can be to browsing Device application module is sent for the request message from local acquisition resource.
This is used for from the local request message for obtaining resource the information that can include the resource to be obtained, browser application Module can obtain respective resources according to the information for the resource that this to be obtained from local.
S13:Receive the resource to be obtained described in locally obtain.
After browser application module is from local acquisition resource, the resource of acquisition can be sent to browser kernel parsing Module.
Further, referring to Fig. 2, after browser kernel parsing module receives the resource locally obtained, can also include:
S14:The resource to be obtained is included in the webpage to be accessed.
When the present embodiment includes preset protocol information in the information by judging the resource to be obtained, send and be used for from local The request message of resource is obtained, resource can be obtained from local, resource is obtained relative to from server, be effectively improved acquisition The speed of resource.
Fig. 3 is the schematic flow sheet of the method for the acquisition resource that another embodiment of the present invention proposes, this method includes:
S31:Browser application module sends the request message for accessing webpage.
When user will access webpage, the URL for the webpage to be accessed can be inputted in a browser (Uniform Resource Locator, URL) address, request for accessing webpage is sent to trigger browser application module Message.
The request message for being used to access webpage can be represented with LoadUrl.
This is used to access the URL addresses that can carry the webpage to be accessed in the request message of webpage.
S32:Browser kernel parsing module forwards the request message for being used to access webpage.
Browser kernel parsing module can according to the request message for the protocol generation respective protocol to be used, such as HttpRequest or FtpRequest.
S33:Browser mixed-media network modules mixed-media receives this and is used to access the request message of webpage and is sent to server, and receives clothes The info web that business device returns, and the info web that server is returned are sent to browser kernel parsing module.
By taking HTTP (HTTP-Hypertext transfer protocol, HTTP) as an example, browser net Network module can carry the info web that server returns is sent to browser kernel parsing mould in HttpRespond Block.
S34:Browser kernel parsing module parses to the info web of reception, obtains and is included in the info web The resource to be obtained information, and judge the resource to be obtained information in whether include preset protocol information, if so, execution S36, otherwise perform S35.
Wherein, html files can be included in the info web that server returns, being included in the html files needs to obtain Resource information, for example, info web can include the following html files for being used to describe webpage:
<html>
<body>
<Img src=" Extension://local.gif”>
</body>
</html>
In above-mentioned html files<Img src=" Extension://local.gif”>It is resource information, representing will The address of the picture of acquisition.
Specifically, whether can be preset protocol according to the predeterminated position of resource information to judge whether resource information includes Preset protocol information, predeterminated position can be the beginning location of resource information, for example, preset protocol is Extension, due to upper The resource information stated is started with Extension, thus may determine that it uses preset protocol, whereas if resource information is not It is to be started with preset protocol, for example, resource information is:<Img src=" i//A.gif ">, then it is not using default association View.
S35:Browser kernel parsing module sends the request for obtaining resource from server to browser mixed-media network modules mixed-media Message.
The request message for being used to obtain resource from server can be HttpRequest or FtpRequest.
This is used to obtain the routing information that can include the resource to be obtained in the request message of resource from server, such as wraps Containing i//A.gif, server can obtain respective resources according to the routing information, and return to browser kernel parsing module and enter Row webpage, which renders, to be showed.
S36:Browser kernel parsing module is sent for disappearing from the local request for obtaining resource to browser application module Breath.
Wherein, it can be downloaded in advance by browser from server from the resource locally obtained and be pre-stored in this Ground.This can include picture, js codes, html files or css files etc. from the resource locally obtained.
This is used for the information that the resource for needing to obtain can be included from the local request message for obtaining resource, such as comprising local.gif。
Optionally, sending for before the local request message for obtaining resource, methods described can also to include:
Whether the webpage to be accessed described in judgement is to allow the webpage using the preset protocol, to be to allow to use During the webpage of the preset protocol, described be used for from the local request message for obtaining resource is sent.
Specifically, the URL addresses allowed using preset protocol can be pre-configured with browser kernel parsing module, browse Device kernel parsing module can be by the URL addresses carried in the request message for accessing webpage and the URL addresses being pre-configured with It is compared, if the URL addresses carried in the request message for accessing webpage belong to the URL addresses being pre-configured with, then May determine that the webpage to be accessed is to allow the webpage using preset protocol.
S37:Resource needed for browser kernel parsing module from local obtain.
Optionally, the resource locally obtained can be compressed package, and when the resource locally obtained is compressed package, browser can To carry out dissection process to the compressed package.
S38:The local resource of acquisition is sent to browser kernel parsing module by browser.
The resource of acquisition can be directly obtain or decompression after resource.
S39:Browser kernel parsing module parses to the local resource, is then shown on webpage.
When the present embodiment includes preset protocol information in the information by judging the resource to be obtained, send and be used for from local The request message of resource is obtained, resource can be obtained from local, resource is obtained relative to from server, be effectively improved acquisition The speed of resource.The present embodiment can reduce local resource expense by locally obtaining the resource of compression.
Fig. 4 is the structural representation of the device for the acquisition resource that another embodiment of the present invention proposes, the device 40 includes obtaining Modulus block 41, processing module 42 and receiving module 43.
Acquisition module 41 is used for the info web for obtaining the webpage to be accessed, and the info web includes the resource to be obtained Information.
When user needs to access webpage, the net for the webpage to be accessed that browser application module can input according to user Location, the net for obtaining the webpage to be accessed is sent to server by browser kernel parsing module and browser mixed-media network modules mixed-media The request message of page information, after server receives the request message, the info web can be passed through browser mixed-media network modules mixed-media It is sent to browser kernel parsing module.
Info web can include HTML (HyperText Markup language, html) file etc..
The information for the resource to be obtained can be included in info web, for example, ima labels are included in html files, should Ima labels are used to show picture to be obtained, and the information for the picture to be obtained is preserved in the ima labels.
Whether processing module 42 includes preset protocol information in the information for judging the resource to be obtained, and is wrapping During information containing preset protocol, send for the request message from local acquisition resource.
In one embodiment, the processing module 42 includes first module 421, as shown in figure 5, the first module 421 Whether preset protocol information is included in information for judging the resource to be obtained, the first module 421 is specifically used for According to the information of predetermined position in the information of the resource to be obtained, judge that the request message for being used to obtain resource is adopted Whether agreement is preset protocol.
When to obtain resource from local, preset protocol information can be included in the information for the resource to be obtained, for example, Preset protocol information is included in ima labels, preset protocol is, for example, Extension, then can in ima labels with Extension//beginning.
In another embodiment, the processing module 42 includes second unit 422, and the second unit 422 is used to send For also including third unit 423, the third unit 423 from the local request message for obtaining resource, the processing module 42 For judging whether the webpage to be accessed is to allow the webpage using the preset protocol, to be allowed using described During the webpage of preset protocol, trigger the second unit 422 and send described be used for from the local request message for obtaining resource.
When including preset protocol information in the information for the resource to be obtained, browser kernel parsing module can be to browsing Device application module is sent for the request message from local acquisition resource.
This is used for from the local request message for obtaining resource the information that can include the resource to be obtained, browser application Module can obtain respective resources according to the information for the resource that this to be obtained from local.
In another embodiment, the processing module 42 also includes the 4th unit 424, and the 4th unit 424 is used to connect Receive the request message for accessing webpage, include the URL addresses of the webpage to be accessed in the request message, the described 3rd If the URL addresses that unit 423 is specifically used for including in the request message for accessing webpage belong to set in advance and permitted Perhaps the URL addresses of the preset protocol are used, then it is to allow the webpage using the preset protocol to judge the webpage.
Receiving module 43 is used to receive the resource to be obtained described in locally obtain.
In one embodiment, the receiving module 43 is specifically used for receiving the packet after decompression, and the packet exists It is local to be preserved with compressing packet form.
After browser application module is from local acquisition resource, the resource of acquisition can be sent to browser kernel parsing Module.
In another embodiment, described device 40 also includes display module 44, as shown in figure 5, the display module 44 is used Content in the packet after by decompression is included on webpage.
When the present embodiment includes preset protocol information in the information by judging the resource to be obtained, send and be used for from local The request message of resource is obtained, resource can be obtained from local, resource is obtained relative to from server, be effectively improved acquisition The speed of resource.
The embodiment of the present invention additionally provides a kind of client device, and the client device includes housing, processor, storage Device, circuit board and power circuit, wherein, circuit board is placed in the interior volume that housing surrounds, and processor and memory are arranged on On circuit board;Power circuit, for each circuit or the device power supply for client device;Memory is used to store executable journey Sequence code;The executable program code that processor is stored by reading in memory is corresponding with executable program code to run Program, for performing following steps:
S11’:The info web for the webpage to be accessed is obtained, the info web includes the information for the resource to be obtained.
When user needs to access webpage, the net for the webpage to be accessed that browser application module can input according to user Location, the net for obtaining the webpage to be accessed is sent to server by browser kernel parsing module and browser mixed-media network modules mixed-media The request message of page information, after server receives the request message, the info web can be passed through browser mixed-media network modules mixed-media It is sent to browser kernel parsing module.
Info web can include HTML (HyperText Markup language, html) file etc..
The information for the resource to be obtained can be included in info web, for example, ima labels are included in html files, should Ima labels are used to show picture to be obtained, and the information for the picture to be obtained is preserved in the ima labels.
S12’:Whether preset protocol information is included in the information for the resource to be obtained described in judgement, and including default association When discussing information, send for the request message from local acquisition resource.
When to obtain resource from local, preset protocol information can be included in the information for the resource to be obtained, for example, Preset protocol information is included in ima labels, preset protocol is, for example, Extension, then can in ima labels with Extension//beginning.
When including preset protocol information in the information for the resource to be obtained, browser kernel parsing module can be to browsing Device application module is sent for the request message from local acquisition resource.
This is used for from the local request message for obtaining resource the information that can include the resource to be obtained, browser application Module can obtain respective resources according to the information for the resource that this to be obtained from local.
S13’:Receive the resource to be obtained described in locally obtain.
After browser application module is from local acquisition resource, the resource of acquisition can be sent to browser kernel parsing Module.
Further, referring to Fig. 2, after browser kernel parsing module receives the resource locally obtained, can also include:
S14’:The resource to be obtained is included in the webpage to be accessed.
When the present embodiment includes preset protocol information in the information by judging the resource to be obtained, send and be used for from local The request message of resource is obtained, resource can be obtained from local, resource is obtained relative to from server, be effectively improved acquisition The speed of resource.
In another embodiment, executable program code that processor is stored by reading in memory runs and can perform Program corresponding to program code, for performing following steps:
S31’:Browser application module sends the request message for accessing webpage.
When user will access webpage, the URL for the webpage to be accessed can be inputted in a browser (Uniform Resource Locator, URL) address, request for accessing webpage is sent to trigger browser application module Message.
The request message for being used to access webpage can be represented with LoadUrl.
This is used to access the URL addresses that can carry the webpage to be accessed in the request message of webpage.
S32’:Browser kernel parsing module forwards the request message for being used to access webpage.
Browser kernel parsing module can according to the request message for the protocol generation respective protocol to be used, such as HttpRequest or FtpRequest.
S33’:Browser mixed-media network modules mixed-media receives this and is used to access the request message of webpage and is sent to server, and receives The info web that server returns, and the info web that server is returned are sent to browser kernel parsing module.
By taking HTTP (HTTP-Hypertext transfer protocol, HTTP) as an example, browser net Network module can carry the info web that server returns is sent to browser kernel parsing mould in HttpRespond Block.
S34’:Browser kernel parsing module parses to the info web of reception, obtains and is wrapped in the info web The information of the resource to be obtained contained, and judge whether include preset protocol information in the information for the resource to be obtained, if so, holding Row S36 ', otherwise performs S35 '.
Wherein, html files can be included in the info web that server returns, being included in the html files needs to obtain Resource information, for example, info web can include the following html files for being used to describe webpage:
<html>
<body>
<Img src=" Extension://local.gif”>
</body>
</html>
In above-mentioned html files<Img src=" Extension://local.gif”>It is resource information, representing will The address of the picture of acquisition.
Specifically, whether can be preset protocol according to the predeterminated position of resource information to judge whether resource information includes Preset protocol information, predeterminated position can be the beginning location of resource information, for example, preset protocol is Extension, due to upper The resource information stated is started with Extension, thus may determine that it uses preset protocol, whereas if resource information is not It is to be started with preset protocol, for example, resource information is:<Img src=" i//A.gif ">, then it is not using default association View.
S35’:Browser kernel parsing module sends the request for obtaining resource from server to browser mixed-media network modules mixed-media Message.
The request message for being used to obtain resource from server can be HttpRequest or FtpRequest.
This is used to obtain the routing information that can include the resource to be obtained in the request message of resource from server, such as wraps Containing i//A.gif, server can obtain respective resources according to the routing information, and return to browser kernel parsing module and enter Row webpage, which renders, to be showed.
S36’:Browser kernel parsing module is sent for disappearing from the local request for obtaining resource to browser application module Breath.
Wherein, it can be downloaded in advance by browser from server from the resource locally obtained and be pre-stored in this Ground.This can include picture, js codes, html files or css files etc. from the resource locally obtained.
This is used for the information that the resource for needing to obtain can be included from the local request message for obtaining resource, such as comprising local.gif。
Optionally, sending for before the local request message for obtaining resource, methods described can also to include:
Whether the webpage to be accessed described in judgement is to allow the webpage using the preset protocol, to be to allow to use During the webpage of the preset protocol, described be used for from the local request message for obtaining resource is sent.
Specifically, the URL addresses allowed using preset protocol can be pre-configured with browser kernel parsing module, browse Device kernel parsing module can be by the URL addresses carried in the request message for accessing webpage and the URL addresses being pre-configured with It is compared, if the URL addresses carried in the request message for accessing webpage belong to the URL addresses being pre-configured with, then May determine that the webpage to be accessed is to allow the webpage using preset protocol.
S37’:Resource needed for browser kernel parsing module from local obtain.
Optionally, the resource locally obtained can be compressed package, and when the resource locally obtained is compressed package, browser can To carry out dissection process to the compressed package.
S38’:The local resource of acquisition is sent to browser kernel parsing module by browser.
The resource of acquisition can be directly obtain or decompression after resource.
S39’:Browser kernel parsing module parses to the local resource, is then shown on webpage.
When the present embodiment includes preset protocol information in the information by judging the resource to be obtained, send and be used for from local The request message of resource is obtained, resource can be obtained from local, resource is obtained relative to from server, be effectively improved acquisition The speed of resource.The present embodiment can reduce local resource expense by locally obtaining the resource of compression.
It should be noted that in the description of the invention, term " first ", " second " etc. are only used for describing purpose, without It is understood that to indicate or implying relative importance.In addition, in the description of the invention, unless otherwise indicated, the implication of " multiple " It is two or more.
Any process or method described otherwise above description in flow chart or herein is construed as, and represents to include Module, fragment or the portion of the code of the executable instruction of one or more the step of being used to realize specific logical function or process Point, and the scope of the preferred embodiment of the present invention includes other realization, wherein can not press shown or discuss suitable Sequence, including according to involved function by it is basic simultaneously in the way of or in the opposite order, carry out perform function, this should be of the invention Embodiment person of ordinary skill in the field understood.
It should be appreciated that each several part of the present invention can be realized with hardware, software, firmware or combinations thereof.Above-mentioned In embodiment, software that multiple steps or method can be performed in memory and by suitable instruction execution system with storage Or firmware is realized.If, and in another embodiment, can be with well known in the art for example, realized with hardware Any one of row technology or their combination are realized:With the logic gates for realizing logic function to data-signal Discrete logic, have suitable combinational logic gate circuit application specific integrated circuit, programmable gate array (PGA), scene Programmable gate array (FPGA) etc..
Those skilled in the art are appreciated that to realize all or part of step that above-described embodiment method carries Suddenly it is that by program the hardware of correlation can be instructed to complete, described program can be stored in a kind of computer-readable storage medium In matter, the program upon execution, including one or a combination set of the step of embodiment of the method.
In addition, each functional unit in each embodiment of the present invention can be integrated in a processing module, can also That unit is individually physically present, can also two or more units be integrated in a module.Above-mentioned integrated mould Block can both be realized in the form of hardware, can also be realized in the form of software function module.The integrated module is such as Fruit is realized in the form of software function module and as independent production marketing or in use, can also be stored in a computer In read/write memory medium.
Storage medium mentioned above can be read-only storage, disk or CD etc..
In the description of this specification, reference term " one embodiment ", " some embodiments ", " example ", " specifically show The description of example " or " some examples " etc. means specific features, structure, material or the spy for combining the embodiment or example description Point is contained at least one embodiment or example of the present invention.In this manual, to the schematic representation of above-mentioned term not Necessarily refer to identical embodiment or example.Moreover, specific features, structure, material or the feature of description can be any One or more embodiments or example in combine in an appropriate manner.
Although embodiments of the invention have been shown and described above, it is to be understood that above-described embodiment is example Property, it is impossible to limitation of the present invention is interpreted as, one of ordinary skill in the art within the scope of the invention can be to above-mentioned Embodiment is changed, changed, replacing and modification.

Claims (10)

  1. A kind of 1. method for obtaining resource, it is characterised in that including:
    The info web for the webpage to be accessed is obtained, the info web includes the information for the resource to be obtained;
    Whether preset protocol information is included in the information for the resource to be obtained described in judgement, and when comprising preset protocol information, Send default for whether being included from the local request message for obtaining resource, in the information for the resource to be obtained described in the judgement Protocol information includes:Whether it is preset protocol according to the predeterminated position of the information of the resource to be obtained, is obtained described in judgement Whether preset protocol information is included in the information of the resource taken, the predeterminated position is the beginning location of the information of resource;
    Receive the resource to be obtained described in locally obtain.
  2. 2. according to the method for claim 1, it is characterised in that described to send for the request message from local acquisition resource Before, methods described also includes:
    Whether the webpage to be accessed described in judgement is to allow the webpage using the preset protocol, to be allowed using described During the webpage of preset protocol, described be used for from the local request message for obtaining resource is sent.
  3. 3. according to the method for claim 2, it is characterised in that also include:Receive the request message for accessing webpage, institute The URL addresses that the webpage to be accessed is included in request message are stated, whether the webpage to be accessed described in the judgement is to allow Using the webpage of the preset protocol, including:
    If the URL addresses included in the request message for accessing webpage, which belong to set in advance, to be allowed using described pre- If the URL addresses of agreement, then it is to allow the webpage using the preset protocol to judge the webpage.
  4. 4. according to the method for claim 1, it is characterised in that described to receive the money to be obtained described in locally obtain Source, including:
    The packet after decompression is received, the packet preserves in local to compress packet form.
  5. 5. according to the method for claim 4, it is characterised in that also include:
    Content in packet after decompression is included on webpage.
  6. A kind of 6. device for obtaining resource, it is characterised in that including:
    Acquisition module, for obtaining the info web for the webpage to be accessed, the info web includes the letter for the resource to be obtained Breath;
    Processing module, whether preset protocol information is included in the information for judging the resource to be obtained, and comprising pre- If during protocol information, sending for from the local request message for obtaining resource, the processing module includes first module, and described the Unit one is specifically used for:Whether it is preset protocol according to the predeterminated position of the information of the resource to be obtained, judges described want Whether preset protocol information is included in the information of the resource of acquisition, the predeterminated position is the beginning location of the information of resource;
    Receiving module, for receiving the resource to be obtained described in locally obtain.
  7. 7. device according to claim 6, it is characterised in that the processing module includes second unit, and described second is single Member, which is used to send, to be used for from the local request message for obtaining resource, and the processing module also includes third unit, and the described 3rd is single Member is used for:
    Whether the webpage to be accessed described in judgement is to allow the webpage using the preset protocol, to be allowed using described During the webpage of preset protocol, trigger the second unit and send described be used for from the local request message for obtaining resource.
  8. 8. device according to claim 7, it is characterised in that the processing module also includes Unit the 4th, and the described 4th Unit is used to receive the request message for being used for accessing webpage, the URL of the webpage to be accessed is included in the request message Location, the third unit are specifically used for:If the URL addresses included in the request message for accessing webpage belong to advance The URL addresses allowed using the preset protocol of setting, then judge that the webpage allows to use the preset protocol Webpage.
  9. 9. device according to claim 6, it is characterised in that the receiving module is specifically used for:
    The packet after decompression is received, the packet preserves in local to compress packet form.
  10. 10. device according to claim 9, it is characterised in that also include:
    Display module, for the content in the packet after decompression to be included in webpage.
CN201410476111.XA 2014-09-17 2014-09-17 The method and apparatus for obtaining resource Active CN104243584B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201410476111.XA CN104243584B (en) 2014-09-17 2014-09-17 The method and apparatus for obtaining resource

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201410476111.XA CN104243584B (en) 2014-09-17 2014-09-17 The method and apparatus for obtaining resource

Publications (2)

Publication Number Publication Date
CN104243584A CN104243584A (en) 2014-12-24
CN104243584B true CN104243584B (en) 2017-12-29

Family

ID=52230912

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201410476111.XA Active CN104243584B (en) 2014-09-17 2014-09-17 The method and apparatus for obtaining resource

Country Status (1)

Country Link
CN (1) CN104243584B (en)

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1689306A (en) * 2002-08-17 2005-10-26 迪斯尼实业公司 System for the delivery and dynamic presentation of large media assets over bandwidth constrained networks
CN101119385A (en) * 2007-08-10 2008-02-06 深圳市深信服电子科技有限公司 Method for enhancing HTTP network velocity using WebPush
CN102096712A (en) * 2011-01-28 2011-06-15 深圳市五巨科技有限公司 Method and device for cache-control of mobile terminal
CN103279574A (en) * 2013-06-20 2013-09-04 北京小米科技有限责任公司 Method, device and terminal device for loading explorer pictures

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102792292B (en) * 2009-12-07 2015-12-16 考持·维 The system and method for site performance optimization and internet service process

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1689306A (en) * 2002-08-17 2005-10-26 迪斯尼实业公司 System for the delivery and dynamic presentation of large media assets over bandwidth constrained networks
CN101119385A (en) * 2007-08-10 2008-02-06 深圳市深信服电子科技有限公司 Method for enhancing HTTP network velocity using WebPush
CN102096712A (en) * 2011-01-28 2011-06-15 深圳市五巨科技有限公司 Method and device for cache-control of mobile terminal
CN103279574A (en) * 2013-06-20 2013-09-04 北京小米科技有限责任公司 Method, device and terminal device for loading explorer pictures

Also Published As

Publication number Publication date
CN104243584A (en) 2014-12-24

Similar Documents

Publication Publication Date Title
US10387521B2 (en) Creation and delivery of pre-rendered web pages for accelerated browsing
US7702317B2 (en) System and method to query wireless network offerings
CN104063460B (en) A kind of method and apparatus loading webpage in a browser
CN101079895B (en) A method, system and proxy service device for quick access to Web page
CN110096660B (en) Method and device for loading page pictures and electronic equipment
US8255491B1 (en) Determining a particular type of wireless device to be emulated
CN104469528B (en) A kind of method, apparatus and browser client for carrying out video data loading
CN102917074B (en) A kind of method realizing server-side browser and server
US20170083487A1 (en) Webpage data processing method and device
CN103020160B (en) The using method of the shopping at network information of browser client, device and browser
CN101635895B (en) Website content subscribing system, website content subscribing method, mobile communication terminal and server
US10284686B2 (en) Server, client, system and method for preloading browsed page in browser
CN112559927B (en) Webpage loading method and device
CN102185923A (en) Webpage browsing method for mobile communication equipment terminal
US7987243B2 (en) Method for media discovery
CN107181779A (en) Processing method, the device and system of access request
US20090089420A1 (en) Flash tracking system and method
CN109067816B (en) Game resource pushing method, server and client
US8554792B1 (en) Method and system for providing contents available on the internet to mobile handset
CN101771928A (en) Method and system and proxy server for Webpage transmitting
CN108334516A (en) Information-pushing method and device
CN103957234B (en) The sending method and browser device of file are downloaded in browser
CN104468769A (en) Method, device and system for acquiring network data content and client side
CN112241298A (en) Page display method and device, storage medium and electronic device
CN103561068B (en) A kind of method and device improving web page browsing speed

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant