Search from Google Chrome address bar

I've just published a small update to this site to enable OpenSearch protocol. Thanks to OpenSearch, you can search this blog from any OpenSearch-aware client, including for instance Mozilla Firefox and Google Chrome.

I really like the way how Google Chrome deals with OpenSearch. When you browse and OpenSearch-aware site, Google Chrome fetches the OSDD file and make it immediately available as a shortcut in the address bar. For example, if you open a couple of pages in this site then you type simone you should see the following behavior.

Google Chrome suggests an available OpenSearch provider

If you hit tab, the autocomplete list disappears and you enter the "OpenSearch mode". You can now enter the search query and confirm to view the search results.

Google Chrome integrates OpenSearch provider in the address bar

Creating an OpenSearch OSDD is as simple as writing less than 10 lines of XML code. Here's mine. For more information visit the OpenSearch website.

PS. If you are a Ruby developer, here's a Builder template. Replace TITLE, DESCRIPTION and PATH_TO_SEARCH with your own variables.

xml.OpenSearchDescription "xmlns" => "",
                          "xmlns:moz" => "" do
  xml.ShortName "TITLE"
  xml.Description "DESCRIPTION"
  xml.InputEncoding "UTF-8"
  xml.Url :type => "text/html", :method => "get", :template => "PATH_TO_SEARCH?q={searchTerms}"

  xml.moz :SearchForm, "PATH_TO_SEARCH"