google.load('search', '1');

 // Whenever a search starts, alert the query.
    function searchStart(searchControl, searcher, query) {
      var content = document.getElementById('maincontent');

      content.innerHTML = "<b class=\"searched\">You searched for: " + query + "</b>";
    }
    function OnLoad() {
      // create a search control
      var searchControl = new google.search.SearchControl();

   // Set the Search Control to get the most number of results
      searchControl.setResultSetSize(google.search.Search.LARGE_RESULTSET);
   // Set a callback so that whenever a search is started we will call
	// searchStart
      searchControl.setSearchStartingCallback(this, searchStart);

   // Add in a WebSearch
  var webSearch = new google.search.WebSearch();
  webSearch.setSiteRestriction('www.hygeia.ie');

      // create a draw options object so that we
      // can position the search form root
      var options = new google.search.DrawOptions();

      options.setSearchFormRoot(document.getElementById("searchForm"));

      options2 = new google.search.SearcherOptions();
      options2.setExpandMode(google.search.SearchControl.EXPAND_MODE_OPEN);

      // populate with searchers
      searchControl.addSearcher(webSearch,options2);
      searchControl.setLinkTarget(google.search.Search.LINK_TARGET_SELF);
      searchControl.draw(document.getElementById("searchResults"), options);

    }
