Wordpress · Wordpress Setup

WordPress – Add Google Search to Your Website

This is a quick and easy google search app recommended from the Google search developer webspam head honcho himself.  Google launched Google web elements to allow you to add your favorite Google products to your website.   The Google web elements include calendar elements, checkout elements and other cool little Google gadgets.  One in particular that I was interested in was the Google Search Element.     It’s exactly the same search you see on my sidebar.  Try it out the search now.  I didn’t use a WordPress plugin and the search did not come with the Thesis theme.   To add this google search to your website is very simple.

1.  Go to Google Web Elements – Show Custom Search

2.  Configure your google search.  If you want to add just the search engine or if you want to add google Adsense to your search results.  You can add your Adsense publisher ID.   See pic below.

3.  Copy your search code.  Don’t use the code below.  Go to the Google Web Elements to copy your own search code.

<!– Google Custom Search Element –>
<div id=”cse” style=”width:100%;”>Loading</div><script src=”http://www.google.com/jsapi” type=”text/javascript”></script><script type=”text/javascript”>google.load(‘search’, ‘1’);google.setOnLoadCallback(function(){var cse = new google.search.CustomSearchControl();cse.enableAds(‘pub-1719145887610317’);cse.draw(‘cse’);}, true);</script>

4.  Go to your Wordpress Administrator, Click on Appearance, Widgets, Drag the Text widget over to your Sidebar.  The Text widget is for arbitrary text or HTML

5.  Paste the google search text into the Text widget.

You’re done.  Save and refresh your site.  You should now see the google search box show up on your Wordpress site.

Leave a Reply

Your email address will not be published. Required fields are marked *

Captcha Captcha Reload