Hi

Am just trying to set up a basic search on webpage.

I have currently been using some code from HelloWorld example.

My issue is the line containing -- localSearch.setLinkTarget
(google.search.Search.LINK_TARGET_BLANK);

it doews not seem to open results in blank window.

Anyone help?

Thanks.

======== example ========

google.load('search', '1');

function OnLoad() {
  // Create a search control
  var searchControl = new google.search.SearchControl();

  // Add in a full set of searchers
  var localSearch = new google.search.LocalSearch();
  searchControl.addSearcher(localSearch);
  searchControl.addSearcher(new google.search.WebSearch());
  searchControl.addSearcher(new google.search.VideoSearch());
  searchControl.addSearcher(new google.search.BlogSearch());
  searchControl.addSearcher(new google.search.NewsSearch());
  searchControl.addSearcher(new google.search.ImageSearch());
  searchControl.addSearcher(new google.search.BookSearch());
  searchControl.addSearcher(new google.search.PatentSearch());

  // Set the Local Search center point
  localSearch.setCenterPoint("New York, NY");

// new window??
localSearch.setLinkTarget(google.search.Search.LINK_TARGET_BLANK);

  // tell the searcher to draw itself and tell it where to attach
  searchControl.draw(document.getElementById("cse"));

  // execute an inital search
  searchControl.execute("VW GTI");
}

google.setOnLoadCallback(OnLoad);
      </script>

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Google AJAX APIs" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/google-ajax-search-api?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to