hello , i wanna put Google search in my site like the one on www.softarchive.net, so i generated the 2 codes from my adsense account . the 1st code for the input text search.php <form action="http://www.sitename.com/path/result.php" id="cse-search-box"> <div> <input type="hidden" name="cx" value="partner-pub-0000000000:0000psjncgc" /> <input type="hidden" name="cof" value="FORID:10" /> <input type="hidden" name="ie" value="ISO-8859-1" /> <input type="text" name="q" size="41" /> <input type="submit" name="sa" value="Search" /> </div> </form> <script type="text/javascript" src="/cse/brand?form=cse-search-box&lang=en"></script> PHP: the 2st code for receive the result result.php <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"></script> PHP: but the 2 codes doesn't work and i didnt recieve the the search result on result.php, i recived blank page ,so please help me to got it work . ,beside i wanna search on more than on site ,so how can i add more sites url on the code to got the search result from. thanks
I believe the site you need to do this is http://www.google.com/coop/cse/ In the URL section just enter your domain and then it will be a specific search engine for your site, then just follow the instruction for how to embed it on your site.
the second code is what you would place within your page space as the actual layout of where search results will show. You could use the second code for a "search form" page as long as you kept the "var googleSearchFrameWidth = 800;" within the space of the page you made available. The first code is what you could use as a generic non-branded search bar that will take your visitor's to google's search results formatted page. If you go to my site here you will see how I use regular search bar but with my own logo in results page.
i got the script from http://multiz.com/google , it is free google search script , it is really cool . so i attached it , please tell me if it could work for my needs that i requested to search my site . thanks
Why would you use another person's code embedded search? All you have to do is plugin what site links or domain pages you want to use. This can be done as you make up your search code on google adsense pages.
Thanks to you all I once had the same problem but I was asked to do the same. We learn everyday. Thanks for all your advice men. I commend you for all your help at digitalpoint forum.
Why would you use another person's code embedded search? All you have to do is plugin what site links or domain pages you want to use.