Monday 6 August 2012

Add Google Autocomplete to other Search Engines

Learn how you can easily add Google like search suggestions to any other search engine be it Twitter, YouTube, Google Plus or any other.

google autocomplete


When you type a few characters in the search box of your favorite web browser – be it Firefox, Internet Explorer or the Omnibox of Google Chrome – Google tries to predict your search query and offers search suggestions in a drop-down. These predictions are often very accurate and thus you rarely have to type the full search query in the browser.
The problem is that this useful “autocomplete” feature isn’t available in most of the other search engines that are installed in your browser. Just look at Twitter, Amazon, or even YouTube search in your browser – none of them offer autocomplete like Google.
That said, it is actually very easy to integrate Google search suggestions in any other search engine with the help of OpenSearch. To get started, just go toctrlq.org/search and install any of your favorite search engines by clicking on their name. These are compatible with Firefox, Google Chrome and Internet Explorer.
Next go to your browser’s search box, or the address bar depending on what browser you are using, change the default search engine to the one that you just installed and type something. You should see get search suggestions in a drop-down just like Google Search.
The idea is simple. If you have set YouTube+ as your default search engine in the browser, the autocomplete suggestions would still get served from Google but when you press enter, the actual search will happen on YouTube. See video demo:



[*] You can also add autocomplete to your site’s search engine – see example. The OpenSearch code is available below and you just need to change a few parameters in the template to use it with your own Google custom search engine.
<?xml version="1.0" encoding="UTF-8"?>

<OpenSearchDescription xmlns="http://a9.com/-/spec/opensearch/1.1/" xmlns:moz="http://www.mozilla.org/2006/browser/search/">

<ShortName>Digital Inspiration</ShortName>

<Description>Search Digital Inspiration</Description>

<InputEncoding>UTF-8</InputEncoding>

<Image width="16" height="16" type="image/x-icon">http://www.labnol.org/favicon.ico</Image>

<Url type="application/x-suggestions+json" method="GET" template="http://suggestqueries.google.com/complete/search?output=firefox&amp;q={searchTerms}"/>

<Url type="text/html" method="GET" template="http://www.labnol.org/?s={searchTerms}" />

<SearchForm>http://www.labnol.org/</SearchForm>

</OpenSearchDescription>
You can follow us on Twitter or join our Facebook Fan Page for more updates like this and You can also ask a problems related to computers or technology on Ask Tech Inspire+ and get your solutions faster.
Share This Post If U Like!!!

0 comments:

Post a Comment

Related Posts Plugin for WordPress, Blogger...
Powered by Blogger.