CN104035970B - A kind of method and apparatus scanned in a browser - Google Patents
A kind of method and apparatus scanned in a browser Download PDFInfo
- Publication number
- CN104035970B CN104035970B CN201410214044.4A CN201410214044A CN104035970B CN 104035970 B CN104035970 B CN 104035970B CN 201410214044 A CN201410214044 A CN 201410214044A CN 104035970 B CN104035970 B CN 104035970B
- Authority
- CN
- China
- Prior art keywords
- search
- webpage
- search engine
- error handle
- error
- 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
Links
- 238000000034 method Methods 0.000 title claims abstract description 50
- 230000000977 initiatory effect Effects 0.000 claims description 53
- 239000000284 extract Substances 0.000 claims description 24
- 238000000605 extraction Methods 0.000 claims description 21
- 230000001960 triggered effect Effects 0.000 claims description 13
- 238000001514 detection method Methods 0.000 claims description 5
- 230000004044 response Effects 0.000 abstract description 4
- 230000006870 function Effects 0.000 description 8
- 238000012545 processing Methods 0.000 description 8
- 238000013515 script Methods 0.000 description 8
- 230000008859 change Effects 0.000 description 4
- 230000009471 action Effects 0.000 description 3
- 230000008901 benefit Effects 0.000 description 3
- 238000005516 engineering process Methods 0.000 description 3
- 238000004590 computer program Methods 0.000 description 2
- 238000010586 diagram Methods 0.000 description 2
- 238000007689 inspection Methods 0.000 description 2
- 230000008569 process Effects 0.000 description 2
- 230000009467 reduction Effects 0.000 description 2
- 238000012546 transfer Methods 0.000 description 2
- 238000004422 calculation algorithm Methods 0.000 description 1
- 235000014510 cooky Nutrition 0.000 description 1
- 238000013461 design Methods 0.000 description 1
- 238000011161 development Methods 0.000 description 1
- 230000000694 effects Effects 0.000 description 1
- 238000012423 maintenance Methods 0.000 description 1
- 230000008520 organization Effects 0.000 description 1
- 238000013519 translation Methods 0.000 description 1
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F16/00—Information retrieval; Database structures therefor; File system structures therefor
- G06F16/90—Details of database functions independent of the retrieved data types
- G06F16/95—Retrieval from the web
- G06F16/951—Indexing; Web crawling techniques
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)
- Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
Abstract
An embodiment of the present invention provides a kind of method and apparatus scanned in a browser, the method includes:In browser side the searching request based on the first search engine is initiated using search key;It detects and the associated error message code of the searching request based on the first search engine;Error message code according to the return initiates error handle request to the corresponding server of the browser;Receive the error handle webpage returned from the corresponding server of the browser according to error handle request;The search characteristics information in the searching request of the first search engine is obtained in the error handle webpage;Described search characteristic information includes search key;In the error handle webpage searching request based on the second search engine is initiated according to described search characteristic information.The embodiment of the present invention avoids user from being again turned on the operations such as search engine, input search key, improves the simplicity of operation and reduces the response times of browser and search engine.
Description
Technical field
The present invention relates to the technical fields of search, more particularly to a kind of method and one kind scanned in a browser
The device scanned in a browser.
Background technology
With the rapid development of network, the network information sharply increases.User in the network information of magnanimity in order to find institute
The network information needed is scanned for usually using search engine.
Search engine refers to is supplied to user to be inquired from internet collection information after centainly arranging automatically
System.Network information vastness is multifarious, and has no order, and all network informations are as the island one by one on vast sea, webpage chain
It is bridge crisscross between these islands to connect, and search engine, then is that user draws an open-and-shut information map,
It is consulted at any time for user.
But due to network problem, the intermittent feelings that cannot be accessed are likely to occur during using some search engines
Condition, on the one hand, after there is such case, user can only open other search engine, re-enter search key into
Row search, search efficiency is very low, and user experience is very poor;On the other hand, the search operation that user repeats, not only increases visitor
The system resource of family end (such as browser) and search engine expends, and increases the occupancy of bandwidth.
Invention content
In view of the above problems, it is proposed that the present invention overcoming the above problem in order to provide one kind or solves at least partly
State a kind of method scanned in a browser of problem and a kind of corresponding device scanned in a browser.
One side according to the present invention provides a kind of method scanned in a browser, including:
In browser side the searching request based on the first search engine is initiated using search key;
It detects and the associated error message code of the searching request based on the first search engine;
Error message code according to the return initiates error handle request to the corresponding server of the browser;
Receive the error handle webpage returned from the corresponding server of the browser according to error handle request;
The search characteristics information in the searching request of the first search engine is obtained in the error handle webpage;It is described to search
Rope characteristic information includes search key;
The search based on the second search engine is initiated in the error handle webpage according to described search characteristic information to ask
It asks.
Optionally, the error message code includes network error message code.
Optionally, the error message code is returned by the corresponding search server of first search engine.
Optionally, the error message code is returned by the corresponding web page server of target webpage;The target webpage is
The webpage redirected from the search result web page that the first search engine is sent.
Optionally, the error handle initiated to the corresponding server of the browser according to the error message code returned
Include in request:
The URL information of the searching request based on the first search engine is initiated using search key.
Optionally, the error handle webpage is the URL letters that the corresponding server of the browser is asked from described search
After identifying first search engine in breath, the corresponding error handle webpage of first engine of extraction.
Optionally, the error handle initiated to the corresponding server of the browser according to the error message code returned
Include in request:
The referer information of the web-page requests redirected from the search result web page that the first search engine is sent.
Optionally, the error handle webpage is the corresponding server of the browser from the web-page requests
After identifying first search engine in referer information, the corresponding error handle webpage of first engine of extraction.
Optionally, it is described obtain the searching request of the first search engine in the error handle webpage in search characteristics
Information includes:
It is extracted in the error handle request of the error handle webpage, is executed using first search engine and searched when secondary
The search characteristics information of rope.
Optionally, described to be extracted in the error handle request of the error handle webpage, drawn using first search
It holds up to execute and includes when the step of search characteristics information of time search:
The error handle request of the error handle webpage is divided into one or more key assignments according to preset separator
Right, the key-value pair includes key name and key assignments;
When the key name is that preset search key identifies, it is crucial as search to extract the corresponding key assignments of the key name
Word.
Optionally, described search characteristic information further includes search-type and/or browser client identification information.
Optionally, described to initiate to draw based on the second search according to described search characteristic information in the error handle webpage
The step of searching request held up includes:
The loaded and displayed entrance object in the error handle webpage;The entrance object includes second search engine
Information and described search characteristic information;
When the entrance object is triggered, the search based on the second search engine is initiated using described search characteristic information
Request.
Optionally, described to include the step of loaded and displayed entrance object in the error handle webpage:
Extract the preset searching request template for being scanned in the second search engine;
It is described please seek template in embedded described search characteristic information, generate entrance object.
Optionally, described to include the step of loaded and displayed entrance object in the error handle webpage:
Extract the preset search box for being scanned in the second search engine;
Described search characteristic information is written in described search frame, generates entrance object.
Optionally, described to initiate to draw based on the second search according to described search characteristic information in the error handle webpage
The step of searching request held up further includes:
The loaded and displayed signature search result in the error handle webpage;The signature search result is to be searched based on first
Index holds up initiation searching request, the search result obtained.
Optionally, second search engine is other search engines other than first search engine.
According to another aspect of the present invention, a kind of device scanned in a browser is provided, including:
First initiation module is asked suitable for initiating the search based on the first search engine using search key in browser side
It asks;
Detection module is adapted to detect for and the searching request based on the first search engine associated error message generation
Code;
Sending module is suitable for initiating mistake to the corresponding server of the browser according to the error message code of the return
Processing request;
Receiving module is suitable for receiving the mistake returned from the corresponding server of the browser according to error handle request
Accidentally processing webpage;
Acquisition module, suitable for obtaining the spy of the search in the searching request of the first search engine in the error handle webpage
Reference ceases;Described search characteristic information includes search key;
Second initiation module is suitable in the error handle webpage initiating to be based on second according to described search characteristic information
The searching request of search engine.
Optionally, the error message code includes network error message code.
Optionally, the error message code is returned by the corresponding search server of first search engine.
Optionally, the error message code is returned by the corresponding web page server of target webpage;The target webpage is
The webpage redirected from the search result web page that the first search engine is sent.
Optionally, the error handle initiated to the corresponding server of the browser according to the error message code returned
Include in request:
The URL information of the searching request based on the first search engine is initiated using search key.
Optionally, the error handle webpage is the URL letters that the corresponding server of the browser is asked from described search
After identifying first search engine in breath, the corresponding error handle webpage of first engine of extraction.
Optionally, the error handle initiated to the corresponding server of the browser according to the error message code returned
Include in request:
The referer information of the web-page requests redirected from the search result web page that the first search engine is sent.
Optionally, the error handle webpage is the corresponding server of the browser from the web-page requests
After identifying first search engine in referer information, the corresponding error handle webpage of first engine of extraction.
Optionally, the acquisition module is further adapted for:
It is extracted in the error handle request of the error handle webpage, is executed using first search engine and searched when secondary
The search characteristics information of rope.
Optionally, the acquisition module is further adapted for:
The error handle request of the error handle webpage is divided into one or more key assignments according to preset separator
Right, the key-value pair includes key name and key assignments;
When the key name is that preset search key identifies, it is crucial as search to extract the corresponding key assignments of the key name
Word.
Optionally, described search characteristic information further includes search-type and/or browser client identification information.
Optionally, second initiation module is further adapted for:
The loaded and displayed entrance object in the error handle webpage;The entrance object includes second search engine
Information and described search characteristic information;
When the entrance object is triggered, the search based on the second search engine is initiated using described search characteristic information
Request.
Optionally, second initiation module is further adapted for:
Extract the preset searching request template for being scanned in the second search engine;
It is described please seek template in embedded described search characteristic information, generate entrance object.
Optionally, second initiation module is further adapted for:
Extract the preset search box for being scanned in the second search engine;
Described search characteristic information is written in described search frame, generates entrance object.
Optionally, second initiation module is further adapted for:
The loaded and displayed signature search result in the error handle webpage;The signature search result is to be searched based on first
Index holds up initiation searching request, the search result obtained;
Optionally, second search engine is other search engines other than first search engine.
The embodiment of the present invention initiates the searching request based on the first search engine, inspection in browser side using search key
To the corresponding server hair of the browser when measuring error message code associated with the searching request based on the first search engine
The error handle webpage that error handle asks and receives server return is played, search characteristics letter is obtained in the error handle webpage
Breath avoids user and is again turned on the operations such as search engine, input search key, improves the simplicity of operation and reduction
The response times of browser and search engine, and then the system resource for reducing browser and search engine expends, reduces
The occupancy of bandwidth, so as to initiate the search based on the second search engine according to search characteristics information in error handle webpage
Request, substantially increases search efficiency, improves user experience.
Above description is only the general introduction of technical solution of the present invention, in order to better understand the technical means of the present invention,
And 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, below the special specific implementation mode for lifting the present invention.
Description of the drawings
By reading the detailed description of hereafter preferred embodiment, various other advantages and benefit are common for this field
Technical staff will become clear.Attached drawing only for the purpose of illustrating preferred embodiments, 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 step of embodiment of the method scanned in a browser according to an embodiment of the invention
Rapid flow chart;
Fig. 2 shows a kind of exemplary plots of error handle webpage according to an embodiment of the invention;
Fig. 3 shows a kind of exemplary plot of error handle webpage according to an embodiment of the invention;
Fig. 4 shows a kind of exemplary plot of error handle webpage according to an embodiment of the invention;
Fig. 5 shows the step flow chart of step 105 according to an embodiment of the invention;
Fig. 6 shows the step flow chart of sub-step S11 according to an embodiment of the invention;
Fig. 7 shows the step flow chart of step 106 according to an embodiment of the invention;
Fig. 8 shows the step flow chart of sub-step S21 according to an embodiment of the invention;
Fig. 9 shows the step flow chart of sub-step S21 according to an embodiment of the invention;
Figure 10 shows the step flow chart of sub-step S21 according to an embodiment of the invention;And
Figure 11 shows a kind of device embodiment scanned in a browser according to an embodiment of the invention
Structure diagram.
Specific implementation mode
The exemplary embodiment of the disclosure is more fully described 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
Completely it is communicated to those skilled in the art.
Referring to Fig.1, show that a kind of method scanned in a browser according to an embodiment of the invention is implemented
The step flow chart of example, can specifically include following steps:
Step 101, in browser side the searching request based on the first search engine is initiated using search key;
Searching request can refer to the instruction of search and the relevant information of some search key that user sends out.For example,
User can initiate searching request, or the search plug-in unit in browser by inputting search key in search-engine web page
Inputs such as (plug-ins can increase function of search in a browser by being interacted with browser, search engine etc.) are searched
Rope keyword initiates searching request etc..When user clicks search control in search-engine web page, it is equivalent to receive
Initiate the instruction of the searching request based on the first search engine;Equally, it search key and clicks when being inputted in searching for plug-in unit
Confirming button or when pressing enter key, also corresponds to receive the instruction for initiating the searching request based on the first search engine.
Wherein, the content of searching request may include the mark of the webpage of user's request of loading and/or the feature of webpage.Net
Page mark can represent the information for the webpage that one uniquely determines, such as uniform resource identifier (Uniform
Resource Identifier, URI), uniform resource identifier can specifically include uniform resource locator (Uniform again
Resource Locator, URL) or uniform resource name (Uniform Resource Name, URN) etc..
It should be noted that the content in searching request can also include search parameter, for identifying in a search engine
Setting information.For example, search parameter may include search-type (such as Webpage search, picture searching, news search, video
Search etc.), and/or browser client identification information (search engine can be searched corresponding with the browser client identification information
User behavior information, and, return and the search results of the user behavior information matches), and/or search result show
The interface languages, and/or browser type etc. of item number, and/or search engine.
The search parameter can have there are one default value, for example, search-type can be defaulted as net in a search engine
Page search, the interface languages of search engine can be defaulted as simplified form of Chinese Character, and the item number that search result is shown can be defaulted as 20,
Etc..And user can change the search parameter by specified function button, for example, can picture be revised as search-type
The interface languages of search engine can be revised as English, can the item number that search result is shown be revised as 30 by search, etc.
Deng.
Step 102, it detects and the associated error message code of the searching request based on the first search engine;
In practical applications, primary search may relate to browser, search engine, the webpage pair redirected from search result
Several main bodys such as the server answered, user can send HTTP (Hypertext in operating every time to corresponding main body
Transfer protocol, hypertext transfer protocol) request, the network of each main body and connection it is possible that mistake,
So that can not normally be browsed, and in the response message for the HTTP request that the main body returns, may include error message generation
Code.
In a kind of optional example of inventive embodiments, the error message code may include network error information generation
Code is caused for identifying the mistake occurred by network facet.
In oneainstance, the error message code can be returned by the corresponding server of first search engine.
In the concrete realization, user asks the search of the first search engine and the relevant information of search key, draws in search
When the server held up goes wrong, the server of search engine can return to error message code.
In another scenario, the error message code is returned by the corresponding server of target webpage;The target network
Page can be the webpage redirected from the search result web page that the first search engine is sent.
In the concrete realization, user asks the search of the first search engine and the relevant information of search key, in positive frequentation
During asking, the first search engine can return to search result web page, which includes search result items, such as
Web page title, web-page summarization, webpage URL information etc., user clicks the search result, can jump to the mesh of corresponding website
Mark webpage.When the server of target webpage goes wrong, the server of target webpage can return to error message generation
Code.
For example, network error message code may include 404 (not finding), indicate that server can not find the net of request of loading
Page.If the request of load is carried out for the webpage being not present on server, server would generally return to this network
Error message code.Alternatively, when Server Error, server can also return to this network error message code.
In another example network error message code may include 403 (having forbidden), server refusal request is indicated.
In another example network error message code may include 101 (handoff protocols), indicate that requestor has required server to cut
Agreement is changed, server has confirmed that and is ready for switching.
Certainly, above-mentioned error message code is intended only as example, can be according to practical feelings when implementing the embodiment of the present invention
Other error message codes are arranged in condition, and the embodiment of the present invention does not limit this.In addition, in addition to above-mentioned error message code
Outside, those skilled in the art can also use other error message codes according to actual needs, the embodiment of the present invention to this not yet
It limits.
Under normal circumstances, target webpage is jumped in search result web page, the HTTP request head sent to target webpage
(header) may include referer information in.The referer information can include a URL information, i.e. user from the URL
The webpage (such as search result web page of the first search engine) that information represents, which sets out, accesses webpage (such as the target of current request
Webpage).Specifically, the referer information can allow client to specify the resource address of request URL, this can allow to take
Business device generates rollback chained list, can be used for logging in, optimizing cache (caching) etc., referer information can allow abolishing or wrong
Connection accidentally is tracked due to the purpose of maintenance.If the URL of request does not have the addresses URL, referer information that cannot be sent,
If specified is the part addresses URL, this address can be a relative address.
For example, user opens the first search engine, and input " weather forecast " and scan for, then first search engine
The example of the URL information of search result can be as follows:
https://www.***.com.hk/searchNewwindow=1&safe=strict&hl=zh-CN&sit
Wherein, " * * * " can indicate the first search engine for e=webhp&source=hp&q=Tian Qiyubaos &btnK=***+ search
Domain name.
Wherein, " q=weather forecasts " can be " weather forecast " with the search key that identity user inputs.
User selects a search result items in the search result web page, jumps to the search result items and corresponds to website
The URL information of target webpage, the target webpage can be as follows:
http://www.weather.com.cn/forecast/
The example of referer information can be as follows at this time:
https://www.***.com.hk/urlSa=t&rct=j&q=&esrc=s&source=web&cd=
2&ved=0CCwQFjAB&url=http%3a%2f%2fwww%2eweather%2ecom%2ec n%2ffor
Ecast%2f&ei=rnpvU4DEO4uA8gWm9IKoAg&usg=AFQjCNGiLX_PHFfeB 8fn xMkKnQwwTBspSQ
Wherein, " * * * " can indicate the domain name of the first search engine.
Step 103, according to the error message code of the return error handle is initiated to the corresponding server of the browser
Request;
When detecting error message code, show mistake occur when time web page access, then it can be corresponding to browser
Server initiates error handle request, the mistake that request processing occurs when time web page access.
It is described corresponding to the browser according to the error message code returned in a kind of alternative embodiment of the present invention
May include having in the error handle request that server is initiated:
The URL information of the searching request based on the first search engine is initiated using search key.
For example, user opens the first search engine, and input " weather forecast " and scan for, then first search engine
The example of the URL information of search result can be as follows:
https://www.***.com.hk/searchNewwindow=1&safe=strict&hl=zh-CN&sit
The &btnK=***+ search of e=webhp&source=hp&q=Tian Qiyubaos
Wherein, " * * * " can indicate the domain name of the first search engine.
It is described to be corresponded to the browser according to the error message code returned in another alternative embodiment of the present invention
Server initiate error handle request in may include having:
The referer information of the web-page requests redirected from the search result web page that the first search engine is sent.
For example, the search result that user searches for " weather forecast " in the first search engine selects one of search result
, and HTTP request, to jump to the website corresponding to result items, the then referer redirected are initiated to the real-time results item
The example of information can be as follows:
https://www.***.com.hk/urlSa=t&rct=j&q=&esrc=s&source=web&cd=
2&ved=0CCwQFjAB&url=http%3a%2f%2fwww%2eweather%2ecom%2ec n%2ffor
Ecast%2f&ei=rnpvU4DEO4uA8gWm9IKoAg&usg=AFQjCNGiLX_PHFfeB 8fn xMkKnQwwTBspSQ
Wherein, " * * * " can indicate the domain name of the first search engine.
Include current hair in the Referer of the head file of HTTP request when initiating request to this above-mentioned network address
The URL information of webpage where when the request risen, i.e. record have such as " https://www.***.com.hk/search
Newwindow=1&safe=strict&hl=zh-CN&site=webhp&source=hp&q=Tian Qiyubaos &btnK
The information of=* * *+search ".It can be seen that being to carry such as " q=weather forecasts " in the referer information, so browser side can carry
The Referer information for taking out the head file of the HTTP request includes a parameter in being asked as error handle, so as to mistake
The server of processing can send the webpage of corresponding error handle according to the Referer information to browser client, and
Browser client is shown to user after being run.This is sent in the error handle webpage that browser end is shown and is loaded with
Java Script scripts, can get the Referer information of the head file of the HTTP request, and pass through the Java
The operation of Script scripts extracts the search key letter of such as " the q=weather forecasts " in the Referer information
Breath, and using the search key extracted the searching request based on another search engine is re-initiated in browser side.
Step 104, it receives from the mistake that the corresponding server of the browser is returned according to error handle request
Manage webpage;
Since mistake occurs for network, and can not the webpage of load request therefore in the embodiment of the present invention, can exist in advance
Built-in at least one error handle webpage in the corresponding server of browser, the error handle webpage can be HTML
(Hypertext Markup Language, hypertext markup language) text receives error handle request in server
When, the error handle webpage is returned to browser, is shown instead of the webpage of load failure.
In the concrete realization, it for each error message code, can be parsed by corresponding text information, it should
Parsing can be as shown in the table:
Error message code | The text information of parsing |
404 | The webpage that you access is not present. |
403 | The webpage that you input can not access, and search for the website related content. |
…… | …… |
The text information that the parsing can be loaded in error handle webpage, with the mistake for prompting user currently to occur.
When the error handle request initiated to the corresponding server of the browser according to the error message code returned
In include, using search key initiate the searching request based on the first search engine URL information when, the error handle
Webpage can be that the corresponding server of the browser identifies that first search is drawn from the URL information that described search is asked
After holding up, the corresponding error handle webpage of first engine of extraction.
When the error handle request initiated to the corresponding server of the browser according to the error message code returned
In include, from the first search engine send search result web page in redirect web-page requests referer information when, it is described
Error handle webpage can identify institute for the corresponding server of the browser from the referer information of the web-page requests
After stating the first search engine, the corresponding error handle webpage of first engine of extraction.
For example, user, in the browser for being identified as " ABC ", by searching for plug-in request search engine A search, " weather is pre-
Report " sends error handle request, which includes that " weather is pre- for search when detecting error message code to server
URL information when report ":
http://www.***.com.hk/searchClient=aff-cs-ABCchromium&ie=UTF-8&q=
Weather forecast
Wherein, " * * * " can indicate the domain name of search engine A.
When server identify for the first search engine after, after extracting first search engine, extract first engine pair
The error handle webpage answered, the error handle webpage can be used for handling the information of logic and display.
For example, the corresponding server of browser identify for search engine A when, at the corresponding mistakes of extraction search engine A
Manage webpage, which can extract for from the URL information when search engine A searches for " weather forecast ".
Step 105, the search characteristics letter in the searching request of the first search engine is obtained in the error handle webpage
Breath;
Search characteristics information can be the information of record search characteristics.Wherein, described search characteristic information may include institute
State search key;And in order to ensure that the comprehensive of search characteristics, described search characteristic information can also include search parameter;It should
Search parameter can specifically include search-type and/or browser client identification information.
For example, as shown in Fig. 2, " webpage " can indicate that search-type is Webpage search, " news " can indicate searching class
Type is news search, and " video " can indicate that search-type is video search, and " picture " can indicate that search-type is searched for picture
Rope, " music " can indicate that search-type is music searching, and " map " can indicate that search-type is map search.
Browser client identification information can be user account, the IP address of user, COOKIE ID etc., as long as can mark
Know user identity, the embodiment of the present invention does not limit this.
In a kind of alternative embodiment of the present invention, referring to Fig. 5, step according to an embodiment of the invention is shown
105 step flow chart, in embodiments of the present invention, step 105 may include following sub-step:
Sub-step S11 is extracted in the error handle request of the error handle webpage, using first search engine
It executes when time search characteristics information of search.
May include search key in searching request, for asking search and the relevant information of the search key.
For example, user can be by inputting search key, or in inputs such as the search plug-in units of browser in search-engine web page
Search key etc..
Content in searching request can also include search parameter, the information for identifying setting in a search engine.
For example, search parameter may include search-type (such as Webpage search, picture searching, news search, video search) and/
Or (search engine can search the user behavior letter corresponding with the browser client identification information to browser client identification information
Breath, and, return and the search result of the user behavior information matches), and/or the item number that shows of search result, and/or search
Index the interface languages held up, and/or browser type etc..In the concrete realization, may include using in error handle request
Search key initiates the URL information of the searching request based on the first search engine, alternatively, being searched from what the first search engine was sent
The referer information of the web-page requests redirected in rope results web page.Can mistake be directed to by the corresponding server of browser
The dynamic web page back to browser local is asked in processing, and (it is raw to be preferably a dynamic for error handle webpage i.e. above-mentioned
At webpage) in by location objects, such as location.href, locally interacted with browser, obtain current net
Page (such as error handle webpage) in URL information (i.e. currently in browser address bar loaded and displayed URL information).
Can also include a kind of JS (JavaScript, literal translation formula script) code, the JS generations in error handle webpage
Code can parse the URL information for the searching request that error handle request includes or the referer information of the web-page requests redirected,
Obtain search characteristics information.
For example, user selected in the search result that the first search engine searches for " weather forecast " in a search result
, and the real-time results item is initiated to ask, to jump to the website corresponding to result items, then the search of first search engine
As a result the example of URL address informations can be as follows:
https://www.***.com.hk/urlSa=t&rct=j&q=&esrc=s&source=web&cd=
2&ved=0CCwQFjAB&url=http%3a%2f%2fwww%2eweather%2ecom%2ec n%2ffor
Ecast%2f&ei=rnpvU4DEO4uA8gWm9IKoAg&usg=AFQjCNGiLX_PHFfeB 8fn xMkKnQwwTBspSQ
Include current hair in the Referer of the head file of HTTP request when initiating request to this above-mentioned network address
The URL information of webpage where when the request risen, i.e. record have such as " https://www.***.com.hk/search
Newwindow=1&safe=strict&hl=zh-CN&site=webhp&source=hp&q=Tian Qiyubaos &btnK
The information of=* * *+search ".It can be seen that being to carry such as " q=weather forecasts " in the referer information, so browser side can carry
The Referer for taking out the head file of the HTTP request includes a parameter in being asked as error handle, so as to error handle
Server the webpage of corresponding error handle can be sent to browser client according to the Referer information, and browsing
Device client is shown to user after being run.This is sent in the error handle webpage that browser end is shown and is loaded with Java
Script scripts can get the Referer information of the head file of the HTTP request, and pass through the Java Script feet
This operation extracts the key word of the inquiry information of such as q=weather forecasts in the Referer information, and using should
The key word of the inquiry extracted re-initiates the searching request based on another search engine in browser side.
In a kind of optional example of the embodiment of the present invention, referring to Fig. 6, son according to an embodiment of the invention is shown
The step flow chart of step S11, in this example, sub-step S11 may include following sub-step:
The error handle request of the error handle webpage is divided into one by sub-step S111 according to preset separator
Or multiple key-value pairs, the key-value pair include key name and key assignments;
Sub-step S112 extracts the corresponding key assignments of the key name when the key name is that preset search key identifies
As search key.
In practical applications, the field in URL information is usually in the form of key1=value1&key2=value2&...
It is identified, wherein key is key name, and value is key assignments.Therefore, URL information can be split as one using " & " as separator
A array, each single item are all the forms of key-value pair key=value.
Wherein, since the first item array including separator is not the form of key=value, first item can be skipped.
By traversing array, the field for being identified as key name with search key is found, corresponding key assignments is returned, is searched for
Keyword.
Search key mark can be used for being identified the field of search key in record URL information, and different
Search engine in different search key can be used to identify.For example, in some search engine, search key mark
Can be " q ", and in some other search engine, search key mark can be " wd " etc..
It should be noted that search key can be used directly, it can also be by different page coding rules
(charset) it is encoded.For example, page coding rule may include UTF-8 and GB2312 etc..Therefore, the embodiment of the present invention
In, the corresponding key assignments of the key name of extraction can also be decoded.
What UTF-8 acquiescences generated is the coding of UTF-8, and acquiescence decoding is also UTF-8, and the pages coding rule such as GB2312
It is also the same.
Decoding for the pages coding rule such as UTF-8 and GB2312 can judge that the page encodes by search engine
Rule then needs to collect the page coding rule that each search engine is applied in advance.
It can also be decoded according to the characteristic of the pages coding rule such as UTF-8 and GB2312.For example, %xx%xx formats
All it is URL codings (UTF-8 or GB2312);Chinese character wants two groups of %xx to form a Chinese character in GB2312, and UTF-8 wants three groups of %xx
Form a Chinese character.
It in addition, for different search parameters, can be identified by searching for corresponding search parameter, obtain search parameter.
For example, in some search engine, cl (Class) can be with identification search type, wherein cl=3 is Webpage search,
Cl=2 is picture searching etc., and pn (Page Number) can identify the number of pages of display result;And draw in some other search
In holding up, hl can show item number, etc. with the interface languages of identification search, num (Number) with identification search result.
Step 106, it initiates to be based on the second search engine according to described search characteristic information in the error handle webpage
Searching request.
In the concrete realization, can be first search to avoid the mistake repeated, second search engine
Other search engines other than engine.
In a kind of alternative embodiment of the present invention, referring to Fig. 7, step according to an embodiment of the invention is shown
106 step flow chart, in embodiments of the present invention, step 106 may include following sub-step:
Sub-step S21, the loaded and displayed entrance object in the error handle webpage;The entrance object includes described
The information and described search characteristic information of two search engines;
In a kind of optional example of the embodiment of the present invention, referring to Fig. 8, son according to an embodiment of the invention is shown
The step flow chart of step S21, in this example, sub-step S21 may include following sub-step:
Sub-step S211 extracts the preset searching request template for being scanned in the second search engine;
Sub-step S212, it is described please seek template in embedded described search characteristic information, generate entrance object.
In embodiments of the present invention, it can be set in advance in the searching request template scanned in different search engines,
The searching request template is expressed according to the searching request organization regulation of corresponding search engine, is reserved with search characteristics information
Position.It is embedded in corresponding search characteristics information in this position, the searching request of the search engine can be generated.
For example, the searching request template scanned in some search engine can be as follows:
http://so.***.cn/sQ="+q+ "s &ie="+encoding
Wherein, "+q+ " can be the position of embedded search key.
And entrance object can be rendered as the form of control or button, when user can be clicked by mouse, touch point
The modes such as the function button hit, specified trigger the entrance object.
For example, as shown in Fig. 2, user in the browser 200 for being identified as " ABC ", is drawn by searching for plug-in request search
Search engine A can not be accessed since mistake occurs in network by holding up A search " weather forecast ", send error handle to server at this time
Request, and the error handle webpage of server return is received, it is shown in label webpage 202.Wherein it is possible in address field
The URL information of the searching request based on the first search engine is initiated in display using search key in 201.At this point it is possible to marking
It is " bad to sign loaded and displayed error message code 203 in webpage 202!Search engine A can not be accessed " to prompt user network
The entrance object 204 of mistake and loaded and displayed search engine B, the entrance object 205 of search engine C and entering for search engine C
Mouth object 206.When user is driven into mouthful object 204 or entrance object 205 or entrance object 206 by mouse or touch point, or
Specified function button is clicked through, entrance object 204 or entrance object 205 or entrance object 206 can be triggered.
In a kind of optional example of the embodiment of the present invention, referring to Fig. 9, son according to an embodiment of the invention is shown
The step flow chart of step S21, in this example, sub-step S21 may include following sub-step:
Sub-step S213 extracts the preset search box for being scanned in the second search engine;
Described search characteristic information is written in sub-step S214 in described search frame, generates entrance object.
In embodiments of the present invention, the search box of the second search engine, the input can be embedded in error handle webpage
The effect of frame is similar with search plug-in unit, can be used for showing search characteristics information, and, it sends and searches for corresponding search engine
Request.
Then entrance object can be rendered as the form of input frame, when user can be clicked by mouse, touch-control is clicked, specified
The modes such as function button trigger the entrance object.
For example, as shown in figure 3, user in the browser 300 for being identified as " ABC ", is drawn by searching for plug-in request search
A search " weather forecast " is held up, but since mistake occurs in network, search engine A can not be accessed, sends mistake to server at this time
Processing request, and the error handle webpage of server return is received, it is shown in label webpage 302.Wherein it is possible on ground
The URL information of the searching request based on the first search engine is initiated in display using search key in location column 301.At this point it is possible to
Loaded and displayed error message code 303 is " bad in label webpage 302!Search engine A can not be accessed " to prompt user network
Generation mistake, the search-type 304 " webpage, news, video, picture, music, map " of one of loaded and displayed search parameter, with
And the search key " weather forecast " of extraction is written in search box 305, the current Logo for showing search engine B
(logotype, logo/mark) B308 indicates that the search engine currently selected is search engine B.Certainly, user can click
Dropdown control 306, displaying search engine C and its LogoC309, search engine D and its LogoD310, and then select search engine C
Or search engine D.User can be clicked by mouse or touch-control clicks search control 307, alternatively, pressing carriage return "enter" key"
Deng the search engine of triggering selection.
Certainly, above-mentioned entrance object is intended only as example, when implementing the embodiment of the present invention, can be set according to actual conditions
Other entrance objects are set, the embodiment of the present invention does not limit this.In addition, other than above-mentioned entrance object, art technology
Personnel can also use other entrance objects, the embodiment of the present invention also not to limit this according to actual needs.
Sub-step S22 is initiated using described search characteristic information based on the second search when the entrance object is triggered
The searching request of engine.
When entrance object is triggered, searching based on corresponding second search engine of entrance object being triggered can be initiated
Rope is asked, and loads and show the search result that second search engine returns.
In a kind of alternative embodiment of the present invention, referring to Figure 10, sub-step according to an embodiment of the invention is shown
The step flow chart of rapid S21, in this example, step 106 may include following sub-step:
Sub-step S31, the loaded and displayed signature search result in the error handle webpage;The signature search result is
Searching request, the search result obtained are initiated based on the first search engine.
Sub-step S32, the loaded and displayed entrance object in the error handle webpage;The entrance object includes described
The information and described search characteristic information of two search engines;
Sub-step S33 is initiated using described search characteristic information based on the second search when the entrance object is triggered
The searching request of engine.
In practical applications, user may be because that certain factors have a particular demands to search engine, different search engines,
It might have different search features;And certain search engines, user behavior information can be recorded, is identified according to browser client
The information searching user behavior information corresponding with the browser client identification information simultaneously returns and the user behavior information matches
Search result.
Also, when time the occurred mistake of browsing, many situations are the mistakes instantaneously occurred.
Therefore, in embodiments of the present invention, in order to keep search result to be more close to the users demand, lower and instantaneously occur
The influence of mistake can send searching request to the first search engine again, obtain search result.
For example, as shown in figure 4, user in the browser 400 for being identified as " ABC ", is drawn by searching for plug-in request search
Search engine A can not be accessed since mistake occurs in network by holding up A search " weather forecast ", send error handle to server at this time
Request, and the error handle webpage of server return is received, it is shown in label webpage 402.Wherein it is possible in address field
The URL information of the searching request based on the first search engine is initiated in display using search key in 401.At this point it is possible to marking
Sign loaded and displayed error message code 403 " this page is not opened ... " and " error message in webpage 402:Connection has been reset "
To prompt user network that mistake and the entrance object 404 of loaded and displayed search engine B occurs, by search key, " weather is pre-
It includes search box that the entrance object 404, which is written, in report ".And can be with loaded and displayed signature search result 406, user can lead to
It crosses hidden function button 405 and hides signature search result 406.When user is driven into mouthful object 404 by mouse or touch point, or
Specified function button is clicked through, entrance object 404 can be triggered.
The embodiment of the present invention initiates the searching request based on the first search engine, inspection in browser side using search key
To the corresponding server hair of the browser when measuring error message code associated with the searching request based on the first search engine
The error handle webpage that error handle asks and receives server return is played, search characteristics letter is obtained in the error handle webpage
Breath avoids user and is again turned on the operations such as search engine, input search key, improves the simplicity of operation and reduction
The response times of browser and search engine, and then the system resource for reducing browser and search engine expends, reduces
The occupancy of bandwidth, so as to initiate the search based on the second search engine according to search characteristics information in error handle webpage
Request, substantially increases search efficiency, improves user experience.
For embodiment of the method, for simple description, therefore it is all expressed as a series of combination of actions, but this field
Technical staff should know that the embodiment of the present invention is not limited by the described action sequence, because implementing according to the present invention
Example, certain steps can be performed in other orders or simultaneously.Next, those skilled in the art should also know that, specification
Described in embodiment belong to preferred embodiment, necessary to the involved action not necessarily embodiment of the present invention.
Referring to Fig.1 1, show that a kind of device scanned in a browser according to an embodiment of the invention is implemented
The structure diagram of example, can specifically include following module:
First initiation module 1101, suitable for initiating searching based on the first search engine using search key in browser side
Rope is asked;
Detection module 1102 is adapted to detect for and the associated error message of the searching request based on the first search engine
Code;
Sending module 1103 is suitable for initiating to the corresponding server of the browser according to the error message code of the return
Error handle is asked;
Receiving module 1104 is suitable for receiving and asks to return from the corresponding server of the browser according to the error handle
Error handle webpage;
Acquisition module 1105, suitable for obtaining searching in the searching request of the first search engine in the error handle webpage
Rope characteristic information;Described search characteristic information includes search key;
Second initiation module 1106, suitable for being based on according to the initiation of described search characteristic information in the error handle webpage
The searching request of second search engine.
To make those skilled in the art more fully understand the embodiment of the present invention, illustrate this hair below by way of specific example
Bright embodiment.
When user is in the browser for being identified as " ABC ", by searching for plug-in request search engine A search, " weather is pre-
Report ", the first initiation module 1101 in the browser use " weather forecast " to send searching request to search engine A.
The request includes URL information when searching for " weather forecast ":
http://www.***.com.hk/searchClient=aff-cs-ABCchromium&ie=UTF-8&q=
Weather forecast
Wherein, " * * * " can indicate the domain name of search engine A.
Since network goes wrong, the search result web page of search engine A can not be normally accessed, search engine A returns wrong
False information code 404.
After detection module 1102 detects the error message code 404, sending module 1103 is to the corresponding clothes of browser
Business device sends error handle request, and error handle request includes initiating searching based on search engine A using search key
The URL information of rope request.
When it is search engine A to identify currently used search engine, extraction corresponds to the corresponding server of the browser
Error handle webpage, and return to the browser.
Receiving module 1104 receives the error handle webpage, and acquisition module 1105 obtains search in the error handle webpage
Search key in the searching request of engine A.
Specifically, acquisition module 1105 can will change error handle net according to preset separator (i.e. above-mentioned " ")
The error handle request of page is divided into one or more key-value pairs (i.e. above-mentioned " q=weather forecasts "), and it includes key to change key-value pair
Name and key assignments extract the corresponding key assignments of the key name and make when the key name is that preset search key identifies (i.e. above-mentioned " q ")
For search key (i.e. above-mentioned " weather forecast ").
Second initiation module 1106 initiates to draw based on the second search in the error handle webpage according to the search key
The searching request held up.
In a kind of optional example of the embodiment of the present invention, the error message code may include network error information generation
Code.
In the concrete realization, the error message code can be returned by the corresponding search server of first search engine
It returns.
In practical applications, the error message code can be returned by the corresponding web page server of target webpage;It is described
Target webpage can be the webpage redirected from the search result web page that the first search engine is sent.
It is described corresponding to the browser according to the error message code returned in a kind of alternative embodiment of the present invention
May include having in the error handle request that server is initiated:
The URL information of the searching request based on the first search engine is initiated using search key.
In a kind of alternative embodiment of the present invention, the error handle webpage can be the corresponding service of the browser
For device after identifying first search engine in the URL information that described search is asked, first engine of extraction is corresponding
Error handle webpage.
It is described corresponding to the browser according to the error message code returned in a kind of alternative embodiment of the present invention
May include having in the error handle request that server is initiated:
The refer information of the web-page requests redirected from the search result web page that the first search engine is sent.
In a kind of alternative embodiment of the present invention, the error handle webpage can be the corresponding service of the browser
After identifying first search engine in the refer information of the web-page requests, first engine of extraction corresponds to device
Error handle webpage.
In a kind of alternative embodiment of the present invention, the acquisition module 1105 can be adapted to:
It is extracted in the error handle request of the error handle webpage, is executed using first search engine and searched when secondary
The search characteristics information of rope.
In a kind of alternative embodiment of the present invention, the acquisition module 1105 can be adapted to:
The error handle request of the error handle webpage is divided into one or more key assignments according to preset separator
Right, the key-value pair includes key name and key assignments;
When the key name is that preset search key identifies, it is crucial as search to extract the corresponding key assignments of the key name
Word.
In a kind of optional example of the embodiment of the present invention, described search characteristic information can also include search-type and/
Or browser client identification information.
In a kind of alternative embodiment of the present invention, second initiation module 1106 can be adapted to:
The loaded and displayed entrance object in the error handle webpage;The entrance object includes second search engine
Information and described search characteristic information;
When the entrance object is triggered, the search based on the second search engine is initiated using described search characteristic information
Request.
In a kind of alternative embodiment of the present invention, second initiation module 1106 can be adapted to:
Extract the preset searching request template for being scanned in the second search engine;
It is described please seek template in embedded described search characteristic information, generate entrance object.
In a kind of alternative embodiment of the present invention, second initiation module 1106 can be adapted to:
Extract the preset search box for being scanned in the second search engine;
Described search characteristic information is written in described search frame, generates entrance object.
In a kind of alternative embodiment of the present invention, second initiation module 1106 can be adapted to:
The loaded and displayed signature search result in the error handle webpage;The signature search result is to be searched based on first
Index holds up initiation searching request, the search result obtained;
In a kind of optional example of the embodiment of the present invention, second search engine can be first search engine
Other search engines in addition.
For device embodiments, since it is basically similar to the method embodiment, so fairly simple, the correlation of description
Place illustrates referring to the part of embodiment of the method.
Algorithm and display be not inherently related to any certain computer, virtual system or miscellaneous equipment provided herein.
Various general-purpose systems can also be used together with teaching based on this.As described above, it constructs required by this kind of system
Structure be obvious.In addition, the present invention is not also directed to any certain programmed language.It should be understood that can utilize various
Programming language realizes the content of 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 the implementation of the present invention
Example can be put into practice 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 description.
Similarly, it should be understood that in order to simplify the disclosure and help to understand one or more of each inventive aspect,
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 method for the disclosure should be construed to reflect following intention:It is i.e. required to protect
Shield the present invention claims the more features of feature than being 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 implementation mode are expressly incorporated in the specific implementation mode, wherein each claim itself
All as a separate embodiment of the present invention.
Those skilled in the art, which are appreciated that, to carry out adaptively the module in the equipment in embodiment
Change and they are arranged in the one or more equipment different from the embodiment.It can be the module or list in embodiment
Member or component be combined into a module or unit or component, and can be divided into addition multiple submodule or subelement or
Sub-component.Other than such feature and/or at least some of process or unit exclude each other, it may be used any
Combination is disclosed to all features disclosed in this specification (including adjoint claim, abstract and attached drawing) and so to appoint
Where all processes or unit of method or equipment are combined.Unless expressly stated otherwise, this specification (including adjoint power
Profit requires, abstract and attached drawing) disclosed in each feature can be by providing the alternative features of identical, equivalent or similar purpose come generation
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 means in of the invention
Within the scope of and form different embodiments.For example, in the following claims, embodiment claimed is appointed
One of meaning mode can use in any combination.
The all parts embodiment of the present invention can be with hardware realization, or to run on one or more processors
Software module realize, or realized with combination thereof.It will be understood by those of skill in the art that can use in practice
Microprocessor or digital signal processor (DSP) come realize it is according to the ... of the embodiment of the present invention scan in a browser set
The some or all functions of some or all components in standby.The present invention is also implemented as described here for executing
Method some or all equipment or program of device (for example, computer program and computer program product).This
The program of the realization present invention of sample can may be stored on the computer-readable medium, or can be with one or more signal
Form.Such signal can be downloaded from internet website and be obtained, and either be provided on carrier signal or with any other
Form provides.
It should be noted that the present invention will be described rather than limits the invention for above-described embodiment, and ability
Field technique personnel can design alternative embodiment without departing from the scope of the appended claims.In the claims,
Any reference mark between bracket 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" before 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 by the same hardware branch
To embody.The use of word first, second, and third does not indicate that any sequence.These words can be explained and be run after fame
Claim.
The embodiment of the invention discloses A1, a kind of methods scanned in a browser, including:
In browser side the searching request based on the first search engine is initiated using search key;
It detects and the associated error message code of the searching request based on the first search engine;
Error message code according to the return initiates error handle request to the corresponding server of the browser;
Receive the error handle webpage returned from the corresponding server of the browser according to error handle request;
The search characteristics information in the searching request of the first search engine is obtained in the error handle webpage;It is described to search
Rope characteristic information includes search key;
The search based on the second search engine is initiated in the error handle webpage according to described search characteristic information to ask
It asks.
A2, the method as described in A1, the error message code include network error message code.
A3, the method as described in A1, the error message code is by the corresponding search server of first search engine
It returns.
A4, the method as described in A1, the error message code are returned by the corresponding web page server of target webpage;It is described
Target webpage is the webpage redirected from the search result web page that the first search engine is sent.
A5, the method as described in A3, it is described to be sent out to the corresponding server of the browser according to the error message code returned
Include in the error handle request risen:
The URL information of the searching request based on the first search engine is initiated using search key.
A6, the method as described in A5, the error handle webpage are the corresponding server of the browser from described search
After identifying first search engine in the URL information of request, the corresponding error handle webpage of first engine of extraction.
A7, the method as described in A4, it is described to be sent out to the corresponding server of the browser according to the error message code returned
Include in the error handle request risen:
The referer information of the web-page requests redirected from the search result web page that the first search engine is sent.
A8, the method as described in A7, the error handle webpage are the corresponding server of the browser from the webpage
After identifying first search engine in the referer information of request, the corresponding error handle of first engine of extraction
Webpage.
A9, the method as described in A5 or A6 or A7 or A8, first search of the acquisition in the error handle webpage are drawn
Search characteristics information in the searching request held up includes:
It is extracted in the error handle request of the error handle webpage, is executed using first search engine and searched when secondary
The search characteristics information of rope.
A10, the method as described in A9, it is described to be extracted in the error handle request of the error handle webpage, using institute
It states the first search engine and executes and include when the step of search characteristics information of time search:
The error handle request of the error handle webpage is divided into one or more key assignments according to preset separator
Right, the key-value pair includes key name and key assignments;
When the key name is that preset search key identifies, it is crucial as search to extract the corresponding key assignments of the key name
Word.
A11, the method as described in A1 or A10, described search characteristic information further include search-type and/or browser client
Identification information.
A12, the method as described in A1 or A2 or A3 or A4 or A5 or A6 or A7 or A8 or A10, it is described at the mistake
Managing the step of initiating the searching request based on the second search engine according to described search characteristic information in webpage includes:
The loaded and displayed entrance object in the error handle webpage;The entrance object includes second search engine
Information and described search characteristic information;
When the entrance object is triggered, the search based on the second search engine is initiated using described search characteristic information
Request.
A13, the method as described in A12, it is described to be wrapped the step of loaded and displayed entrance object in the error handle webpage
It includes:
Extract the preset searching request template for being scanned in the second search engine;
It is described please seek template in embedded described search characteristic information, generate entrance object.
A14, the method as described in A12, it is described to be wrapped the step of loaded and displayed entrance object in the error handle webpage
It includes:
Extract the preset search box for being scanned in the second search engine;
Described search characteristic information is written in described search frame, generates entrance object.
A15, the method as described in A12, it is described to be initiated according to described search characteristic information in the error handle webpage
The step of searching request based on the second search engine further includes:
The loaded and displayed signature search result in the error handle webpage;The signature search result is to be searched based on first
Index holds up initiation searching request, the search result obtained.
A16, the method as described in A1 or A2 or A3 or A4 or A5 or A6 or A7 or A8 or A10 or A13 or A14 or A15, institute
It is other search engines other than first search engine to state the second search engine.
The embodiment of the invention also discloses B17, a kind of devices scanned in a browser, including:
First initiation module is asked suitable for initiating the search based on the first search engine using search key in browser side
It asks;
Detection module is adapted to detect for and the searching request based on the first search engine associated error message generation
Code;
Sending module is suitable for initiating mistake to the corresponding server of the browser according to the error message code of the return
Processing request;
Receiving module is suitable for receiving the mistake returned from the corresponding server of the browser according to error handle request
Accidentally processing webpage;
Acquisition module, suitable for obtaining the spy of the search in the searching request of the first search engine in the error handle webpage
Reference ceases;Described search characteristic information includes search key;
Second initiation module is suitable in the error handle webpage initiating to be based on second according to described search characteristic information
The searching request of search engine.
B18, the device as described in B17, the error message code include network error message code.
B19, the device as described in B17, the error message code is by the corresponding search service of first search engine
Device returns.
B20, the device as described in B17, the error message code are returned by the corresponding web page server of target webpage;Institute
It is the webpage redirected from the search result web page that the first search engine is sent to state target webpage.
B21, the device as described in B19, it is described according to the error message code returned to the corresponding server of the browser
Include in the error handle request of initiation:
The URL information of the searching request based on the first search engine is initiated using search key.
B22, the device as described in B21, the error handle webpage are that the corresponding server of the browser is searched from described
After first search engine being identified in the URL information of rope request, the corresponding error handle net of first engine of extraction
Page.
B23, the device as described in B20, it is described according to the error message code returned to the corresponding server of the browser
Include in the error handle request of initiation:
The referer information of the web-page requests redirected from the search result web page that the first search engine is sent.
B24, the device as described in B23, the error handle webpage are the corresponding server of the browser from the net
After identifying first search engine in the referer information of page request, at the corresponding mistake of first engine of extraction
Manage webpage.
B25, the device as described in B21 or B22 or B23 or B24, the acquisition module are further adapted for:
It is extracted in the error handle request of the error handle webpage, is executed using first search engine and searched when secondary
The search characteristics information of rope.
B26, the device as described in B25, the acquisition module are further adapted for:
The error handle request of the error handle webpage is divided into one or more key assignments according to preset separator
Right, the key-value pair includes key name and key assignments;
When the key name is that preset search key identifies, it is crucial as search to extract the corresponding key assignments of the key name
Word.
B27, the device as described in B17 or B26, described search characteristic information further include that search-type and/or browser are used
Family identification information.
B28, the device as described in B17 or B18 or B19 or B20 or B21 or B22 or B23 or B24 or B26, described second
Initiation module is further adapted for:
The loaded and displayed entrance object in the error handle webpage;The entrance object includes second search engine
Information and described search characteristic information;
When the entrance object is triggered, the search based on the second search engine is initiated using described search characteristic information
Request.
B29, the device as described in B28, second initiation module are further adapted for:
Extract the preset searching request template for being scanned in the second search engine;
It is described please seek template in embedded described search characteristic information, generate entrance object.
B30, the device as described in B28, second initiation module are further adapted for:
Extract the preset search box for being scanned in the second search engine;
Described search characteristic information is written in described search frame, generates entrance object.
B31, the device as described in B28, second initiation module are further adapted for:
The loaded and displayed signature search result in the error handle webpage;The signature search result is to be searched based on first
Index holds up initiation searching request, the search result obtained.
B32, as described in B17 or B18 or B19 or B20 or B21 or B22 or B23 or B24 or B26 or B29 or B30 or B31
Device, second search engine be first search engine other than other search engines.
Claims (30)
1. a kind of method scanned in a browser, including:
In browser side the searching request based on the first search engine is initiated using search key;
It detects and the associated error message code of the searching request based on the first search engine;
According to the error message code returned error handle request is initiated to the corresponding server of the browser;
Receive the error handle webpage returned from the corresponding server of the browser according to error handle request;
The search characteristics information in the searching request of the first search engine is obtained in the error handle webpage;Described search is special
Reference breath includes search key;It is initiated based on the second search according to described search characteristic information in the error handle webpage
The searching request of engine;
It is described to be asked according to search of the described search characteristic information initiation based on the second search engine in the error handle webpage
The step of asking include:
The loaded and displayed entrance object in the error handle webpage;The entrance object includes the letter of second search engine
Breath and described search characteristic information;
When the entrance object is triggered, the search based on the second search engine is initiated using described search characteristic information and is asked
It asks.
2. the method as described in claim 1, which is characterized in that the error message code includes network error message code.
3. the method as described in claim 1, which is characterized in that the error message code is corresponded to by first search engine
Search server return.
4. the method as described in claim 1, which is characterized in that the error message code is taken by the corresponding webpage of target webpage
Business device returns;The target webpage is the webpage redirected from the search result web page that the first search engine is sent.
5. method as claimed in claim 3, which is characterized in that it is described according to the error message code returned to the browser pair
Include in the error handle request that the server answered is initiated:
The URL information of the searching request based on the first search engine is initiated using search key.
6. method as claimed in claim 5, which is characterized in that the error handle webpage is the corresponding service of the browser
Device is after identifying first search engine in the URL information that described search is asked, first search engine pair of extraction
The error handle webpage answered.
7. method as claimed in claim 4, which is characterized in that it is described according to the error message code returned to the browser pair
Include in the error handle request that the server answered is initiated:
The referer information of the web-page requests redirected from the search result web page that the first search engine is sent.
8. the method for claim 7, which is characterized in that the error handle webpage is the corresponding service of the browser
Device after identifying first search engine in the referer information of the web-page requests, draw by first search of extraction
Hold up corresponding error handle webpage.
9. the method as described in claim 5 or 6 or 7 or 8, which is characterized in that described to be obtained in the error handle webpage
Search characteristics information in the searching request of first search engine includes:
It extracts in the error handle request of the error handle webpage, is executed when time search using first search engine
Search characteristics information.
10. method as claimed in claim 9, which is characterized in that the error handle in the error handle webpage is asked
Middle extraction, using first search engine execution when the step of search characteristics information of time search includes:
The error handle request of the error handle webpage is divided into one or more key-value pairs, institute according to preset separator
It includes key name and key assignments to state key-value pair;
When the key name is that preset search key identifies, the corresponding key assignments of the key name is extracted as search key.
11. the method as described in claim 1 or 10, which is characterized in that described search characteristic information further include search-type and/
Or browser client identification information.
12. the method as described in claim 1, which is characterized in that the loaded and displayed entrance in the error handle webpage
The step of object includes:
Extract the preset searching request template for being scanned in the second search engine;
It is described please seek template in embedded described search characteristic information, generate entrance object.
13. the method as described in claim 1, which is characterized in that the loaded and displayed entrance in the error handle webpage
The step of object includes:
Extract the preset search box for being scanned in the second search engine;
Described search characteristic information is written in described search frame, generates entrance object.
14. the method as described in claim 1, which is characterized in that the foundation described search in the error handle webpage
Characteristic information initiates the step of searching request based on the second search engine and further includes:
The loaded and displayed signature search result in the error handle webpage;The signature search result is to be drawn based on the first search
Initiation searching request is held up, the search result obtained.
15. the method as described in claims 1 or 2 or 3 or 4 or 5 or 6 or 7 or 8 or 10 or 12 or 13 or 14, which is characterized in that
Second search engine is other search engines other than first search engine.
16. a kind of device scanned in a browser, including:
First initiation module is suitable for initiating the searching request based on the first search engine using search key in browser side;
Detection module is adapted to detect for and the associated error message code of the searching request based on the first search engine;
Sending module is asked suitable for initiating error handle to the corresponding server of the browser according to the error message code returned
It asks;
Receiving module is suitable for receiving from the mistake that the corresponding server of the browser is returned according to error handle request
Manage webpage;
Acquisition module, suitable for obtaining the letter of the search characteristics in the searching request of the first search engine in the error handle webpage
Breath;Described search characteristic information includes search key;
Second initiation module is suitable in the error handle webpage initiating based on the second search according to described search characteristic information
The searching request of engine;
Second initiation module is further adapted for:
The loaded and displayed entrance object in the error handle webpage;The entrance object includes the letter of second search engine
Breath and described search characteristic information;
When the entrance object is triggered, the search based on the second search engine is initiated using described search characteristic information and is asked
It asks.
17. device as claimed in claim 16, which is characterized in that the error message code includes network error information generation
Code.
18. device as claimed in claim 16, which is characterized in that the error message code is by first search engine pair
The search server answered returns.
19. device as claimed in claim 16, which is characterized in that the error message code is by the corresponding webpage of target webpage
Server returns;The target webpage is the webpage redirected from the search result web page that the first search engine is sent.
20. device as claimed in claim 18, which is characterized in that it is described according to the error message code returned to the browser
Include in the error handle request that corresponding server is initiated:
The URL information of the searching request based on the first search engine is initiated using search key.
21. device as claimed in claim 20, which is characterized in that the error handle webpage is the corresponding clothes of the browser
Device be engaged in after identifying first search engine in the URL information that described search is asked, first search engine of extraction
Corresponding error handle webpage.
22. device as claimed in claim 19, which is characterized in that it is described according to the error message code returned to the browser
Include in the error handle request that corresponding server is initiated:
The referer information of the web-page requests redirected from the search result web page that the first search engine is sent.
23. device as claimed in claim 22, which is characterized in that the error handle webpage is the corresponding clothes of the browser
Device be engaged in after identifying first search engine in the referer information of the web-page requests, first search of extraction
The corresponding error handle webpage of engine.
24. the device as described in claim 20 or 21 or 22 or 23, which is characterized in that the acquisition module is further adapted for:
It extracts in the error handle request of the error handle webpage, is executed when time search using first search engine
Search characteristics information.
25. device as claimed in claim 24, which is characterized in that the acquisition module is further adapted for:
The error handle request of the error handle webpage is divided into one or more key-value pairs, institute according to preset separator
It includes key name and key assignments to state key-value pair;
When the key name is that preset search key identifies, the corresponding key assignments of the key name is extracted as search key.
26. the device as described in claim 16 or 25, which is characterized in that described search characteristic information further includes search-type
And/or browser client identification information.
27. device as claimed in claim 16, which is characterized in that second initiation module is further adapted for:
Extract the preset searching request template for being scanned in the second search engine;
It is described please seek template in embedded described search characteristic information, generate entrance object.
28. device as claimed in claim 16, which is characterized in that second initiation module is further adapted for:
Extract the preset search box for being scanned in the second search engine;
Described search characteristic information is written in described search frame, generates entrance object.
29. device as claimed in claim 16, which is characterized in that second initiation module is further adapted for:
The loaded and displayed signature search result in the error handle webpage;The signature search result is to be drawn based on the first search
Initiation searching request is held up, the search result obtained.
30. the device as described in claim 16 or 17 or 18 or 19 or 20 or 21 or 22 or 23 or 25 or 27 or 28 or 29,
It is characterized in that, second search engine is other search engines other than first search engine.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201410214044.4A CN104035970B (en) | 2014-05-20 | 2014-05-20 | A kind of method and apparatus scanned in a browser |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201410214044.4A CN104035970B (en) | 2014-05-20 | 2014-05-20 | A kind of method and apparatus scanned in a browser |
Publications (2)
Publication Number | Publication Date |
---|---|
CN104035970A CN104035970A (en) | 2014-09-10 |
CN104035970B true CN104035970B (en) | 2018-10-09 |
Family
ID=51466740
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201410214044.4A Active CN104035970B (en) | 2014-05-20 | 2014-05-20 | A kind of method and apparatus scanned in a browser |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN104035970B (en) |
Families Citing this family (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN104965926B (en) * | 2015-07-14 | 2019-03-26 | 安一恒通(北京)科技有限公司 | Webpage providing method and device |
CN105631050B (en) * | 2016-03-01 | 2019-09-17 | 国家计算机网络与信息安全管理中心 | A kind of method and system that the URL search key of rule-based configuration extracts |
Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101751428A (en) * | 2008-12-12 | 2010-06-23 | 汉王科技股份有限公司 | Information search method and device |
CN102214223A (en) * | 2011-06-15 | 2011-10-12 | 奇智软件(北京)有限公司 | Method and system for browser access control |
CN102663071A (en) * | 2012-03-31 | 2012-09-12 | 奇智软件(北京)有限公司 | Searching method and device in browser |
CN102945284A (en) * | 2012-11-22 | 2013-02-27 | 北京奇虎科技有限公司 | Method and device for obtaining status of search engine and browser |
Family Cites Families (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20100114954A1 (en) * | 2008-10-28 | 2010-05-06 | Microsoft Corporation | Realtime popularity prediction for events and queries |
-
2014
- 2014-05-20 CN CN201410214044.4A patent/CN104035970B/en active Active
Patent Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101751428A (en) * | 2008-12-12 | 2010-06-23 | 汉王科技股份有限公司 | Information search method and device |
CN102214223A (en) * | 2011-06-15 | 2011-10-12 | 奇智软件(北京)有限公司 | Method and system for browser access control |
CN102663071A (en) * | 2012-03-31 | 2012-09-12 | 奇智软件(北京)有限公司 | Searching method and device in browser |
CN102945284A (en) * | 2012-11-22 | 2013-02-27 | 北京奇虎科技有限公司 | Method and device for obtaining status of search engine and browser |
Also Published As
Publication number | Publication date |
---|---|
CN104035970A (en) | 2014-09-10 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN104021154B (en) | A kind of method and apparatus scanned in a browser | |
US10362050B2 (en) | System and methods for scalably identifying and characterizing structural differences between document object models | |
US9614862B2 (en) | System and method for webpage analysis | |
CN105335404B (en) | Page info loading method and device | |
JP2022184964A (en) | Systems and methods for direct in-browser markup of elements in internet content | |
CN102663319B (en) | Prompting method and device for download link security | |
CN108268635B (en) | Method and apparatus for acquiring data | |
CN102982117B (en) | Information search method and device | |
US11263062B2 (en) | API mashup exploration and recommendation | |
CN105760379B (en) | Method and device for detecting webshell page based on intra-domain page association relation | |
CN109145078A (en) | The application page of the machine application is indexed | |
CN102375742B (en) | Avoiding display of browser content that may induce a seizure in viewers with photo-sensitivity | |
CN104462074A (en) | Method and device for conducting webpage data translation and browser client side | |
CN106687949A (en) | Search results for native applications | |
US9785710B2 (en) | Automatic crawling of encoded dynamic URLs | |
US10878203B2 (en) | Translation system | |
US9058399B2 (en) | System and method for providing network resource identifier shortening service to computing devices | |
CN103647678A (en) | Method and device for online verification of website vulnerabilities | |
US20120290909A1 (en) | Methods and apparatus of accessing related content on a web-page | |
CA2786418C (en) | Identifying equivalent javascript events | |
CN112637361A (en) | Page proxy method, device, electronic equipment and storage medium | |
CN103530389A (en) | Method and device for improving stopword searching effectiveness | |
KR102214990B1 (en) | System for providing bookmark management and information searching service and method for providing bookmark management and information searching service using it | |
JP2011043924A (en) | Web action history acquisition system, web action history acquisition method, gateway device and program | |
CN104035970B (en) | A kind of method and apparatus scanned in a browser |
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 | ||
TR01 | Transfer of patent right |
Effective date of registration: 20220727 Address after: Room 801, 8th floor, No. 104, floors 1-19, building 2, yard 6, Jiuxianqiao Road, Chaoyang District, Beijing 100015 Patentee after: BEIJING QIHOO TECHNOLOGY Co.,Ltd. Address before: 100088 room 112, block D, 28 new street, new street, Xicheng District, Beijing (Desheng Park) Patentee before: BEIJING QIHOO TECHNOLOGY Co.,Ltd. Patentee before: Qizhi software (Beijing) Co.,Ltd. |
|
TR01 | Transfer of patent right |