views:

291

answers:

1

Hi I've a webpage and want to integrate google search into that page.

Can u people guide me how to do that?

Actually i tried with the code given by the google.

like this

<form action="http://www.duckyvideos.com" id="cse-search-box">
  <div>
    <input type="hidden" name="cx" value="partner-pub-9481442241155955:7j2htu-qsi5" />
    <input type="hidden" name="cof" value="FORID:10" />
    <input type="hidden" name="ie" value="ISO-8859-1" />
    <input type="text" name="q" size="31" />
    <input type="submit" name="sa" value="Search" />
  </div>
</form>

<script type="text/javascript" src="http://www.google.com/coop/cse/brand?form=cse-search-box&amp;amp;lang=en"&gt;&lt;/script&gt;


<div id="cse-search-results"></div>
<script type="text/javascript">
  var googleSearchIframeName = "cse-search-results";
  var googleSearchFormName = "cse-search-box";
  var googleSearchFrameWidth = 800;
  var googleSearchDomain = "www.google.com";
  var googleSearchPath = "/cse";
</script>
<script type="text/javascript" src="http://www.google.com/afsonline/show_afs_search.js"&gt;&lt;/script&gt;

I placed the above code in my webpage. But it is not showing any results.

Whats the problem in that

A: 

The most likely reason your CSE is not showing any results is because Google has not indexed your site yet. This may be the case even if your site is already showing up in regular search results (though if it doesn't show up in regular results, it definitely won't show up in the CSE).

You can verify this by using the test search functionality from the CSE control panel. If there are no results there, it's definitely nothing you're doing wrong.

Make sure Google's spider can find your pages, and wait a bit for them to be indexed, then try again.

Nick Johnson
no actually my pages got indexed can you paste the above code which i posted into a page and test it once
Nagu
I'm sure you're quite capable of testing it yourself. As I said, you can also use the test search facility in the CSE control panel - does that return any results?
Nick Johnson