Add google search to your wordpress website


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. 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 –></p>
<div id=”cse” style=”width:100%;>Loading</div>
<p><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.

If you like this post, please consider sharing it!

Enter Your Mail Address



One Response to “Add google search to your wordpress website”

  1. Hi to every body, it?s my first go to see of this webpage; this weblog carries awesome and genuinely fine material in support of visitors.

Leave a Reply

*