Search code examples
htmlgoogle-search

How to include Google Search results on a webpage


I'm doing a webpage about apples (the fruit), I want to include Google search results for apple recipes on the bottom of the page. How can I do this?


Solution

  • You can accomplish this using iframes, but you might want to consider some alternatives... you might want to create a Google Custom Search Engine to serve results only from recipe websites. And, instead of using a frame to display results, you might want to simply make the custom search engine available, so that, only if a user is interested in finding a recipe, he/she may do so. Something else to consider... you might want to monetize this, in which case using Google AdSense would be the way to go.

    <iframe src="http://www.google.com/search?q=apple+recipe" />
    

    If you want to use an iframe, you can use the code above; however, this is not a good design decision.