Hi Gina, Please take a look at this blog post on the subject: http://googleajaxsearchapi.blogspot.com/2010/03/search-form-and-results-on-two.html
If you still have questions, be sure to come back and let us know! Cheers, Adam On Apr 14, 12:13 pm, "~G" <[email protected]> wrote: > I am very new to Javascript.. I would like the search box to be on my > home page however I would like the results to display on a different > page... Could someone show me how I can do this with my current code ? > > <script language="JavaScript" type="text/javascript"> > <!-- > function OnLoad() { > > // Create a search control > var searchControl = new GSearchControl(); > > // site restricted web search with custom label > var siteSearch = new GwebSearch(); > siteSearch.setLinkTarget(GwebSearch.LINK_TARGET_SELF); > siteSearch.setUserDefinedLabel("Search SBSB"); > > siteSearch.setUserDefinedClassSuffix("siteSearch"); > siteSearch.setSiteRestriction("sbsb.com"); > searchControl.addSearcher(siteSearch); > > // tell the searcher to draw itself and tell it where to > attach > searchControl.draw(document.getElementById("searchcontrol")); > > // execute an inital search > searchControl.execute(); > } > //]]> > //--> > </script> > > Thank you so much > Gina -- 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.
