The code in sidebar.php for this reads as follows:
<li id="search">
<!-- Google CSE Search Box Begins -->
<form action="https://www.haberarts.com/ggsearch.htm" id="searchbox_007824554724251649928:hl-xxbn-w6q">
<input type="hidden" name="cx" value="007824554724251649928:hl-xxbn-w6q" />
<input type="hidden" name="cof" value="FORID:11" />
<input type="text" name="q" size="15" />
<input type="submit" name="sa" value="Search" />
</form>
<script type="text/javascript" src="https://www.google.com/coop/cse/brand?form=searchbox_007824554724251649928%3Ahl-xxbn-w6q&lang=en"></script>
<!-- Google CSE Search Box Ends -->
</li>
A search does return the custom text and style specified in ggsearch.htm, but no search results.The relevant section in ggsearch.htm is as follows:
<div id="results_007824554724251649928:hl-xxbn-w6q"></div>
<script type="text/javascript">
var googleSearchIframeName = "results_007824554724251649928:hl-xxbn-w6q";
var googleSearchFormName = "searchbox_007824554724251649928:hl-xxbn-w6q";
var googleSearchFrameWidth = 600;
var googleSearchFrameborder = 0;
var googleSearchDomain = "www.google.com";
var googleSearchPath = "/cse";
</script>
<script type="text/javascript" src="https://www.google.com/afsonline/show_afs_search.js"></script>
That’s all I know, and thanks!
]]><script type=’application/ld+json’>{“@context”:”http:\/\/schema.org\/true”,”@type”:”WebSite”,”url”:”http:\/\/mycompany.com\/”,”name”:”MYCOMPANY”,”potentialAction”:{“@type”:”SearchAction”,”target”:”http:\/\/mycompany.com\/?s={search_term}”,”query-input”:”required name=search_term”}}</script>
It’s been almost 2 weeks since I have implemented this code, but the search box is still not visible in the search results. Could you please help me sort out this issue? Any help is highly appreciated.
]]>All works with the exception of one: the Google Search box.
I have the Search box widget added into the sidebars. When I go into Easy Adsense settings to ad the code, then hit “save changes”, I get returned a blank screen with this in the url: data:,
If I remove the search box code, it functions normal.
Can you advise on this, please?
Thank you:)
https://www.ads-software.com/plugins/easy-adsense-lite/
]]>I chose the homepage to be the destination for the search results, but it wiped out my opt in box in the process.
The opt in box is visible on every other page except for the homepage.
There’s also a picture in the way of the top right view of the results.
Can anyone help?
]]>Today, I included another Google custom search box at the footer, besides one that was already installed at the header section. And, to my dismay, the W3C validator showed 2 errors as displayed @ https://validator.w3.org/check?uri=http%3a%2f%2fwww%2ejaycjayc%2ecom%2f. Previously, with only one search box at the header, there’s no error and page passed.
Just to let you know that the related codes for both the custom search boxes were copied from my Adsense account and pasted exactly into my site’s template themes.
I’d greatly appreciate if someone could teach me how to rectify the problem as I still wish to have 2 Google search boxes on each of my webpage.
Thank you.
]]>Thanks,
Amber
Info:
Im not a noob in Wp but not a expert either, im just a level above a noob.