I’m not sure if you will be able to help me with this issue, but I thought I would ask. I am trying to add the Google custom search plugin to my website and they have given me two snippets of code and have told me where I should put it, but I am having trouble finding the area to put the code.
•The first code is for the search box, they said to paste it into a <div> element in your site’s <body> section, where you want the search box to render. We are a little confused on where the <body> section is.
Below is the code:
<script>
(function() {
var cx = ‘012769584818690426314:_glpknab8k0’;
var gcse = document.createElement(‘script’);
gcse.type = ‘text/javascript’;
gcse.async = true;
gcse.src = (document.location.protocol == ‘https:’ ? ‘https:’ : ‘http:’) +
‘//www.google.com/cse/cse.js?cx=’ + cx;
var s = document.getElementsByTagName(‘script’)[0];
s.parentNode.insertBefore(gcse, s);
})();
</script>
<gcse:searchbox></gcse:searchbox>
•The second code is for the search results. They said to paste it into a <div> element in your site’s <body> section, where you want the search results to render. And again we’re confused on where the <body> section is.
<gcse:searchresults></gcse:searchresults>