Multiple Search Engine Search

Most people looking for information on the web will perform a search using a search engine or directory. There are lots of different search engines (and several directories) out there that people can search. Their favourite one will not necessarily find them the best pages on what they are looking for.

Many of these search engines and directories offer a way that you can set up a search box on your own site that your visitors can use to start searching.

How about if instead of offering our visitors the opportunity to search via one search engine we give them a choice of several different search engines/directories that they can choose to search from. Well with this script you can. The selection list contains more than 20 different search engines and directories including all of those in the top 5, many of the top 50, and even a few more obscure ones for them to choose from. What's more the list randomly selects which one will be displayed as the selected/default entry so that they will get the opportunity to see some of the other search engines in the list.

To insert this search selector script into your page the first thing you need to do is to put the following HTML into the body of your page where you want the calculator to appear. The form itself will be added by the JavaScript so that you don't end up with a broken form in your page when your visitor has JavaScript disabled.. This script is completely unobtrusive except for the id used in the div and you can even change that if you need to by simply amending the value in the line above the array at the bottom of the script.

<div id="f"></div>

You also need to add a small piece of HTML just before the </body> tag to link the Javascript into the page so that the script will function.

<script type="text/javascript" src="multi.js"></script>

Next, copy the following JavaScript code and save it in a file called multi.js which you have just linked into your page.

JavaScript

You can easily amend the list of search engines that this script provides to eiter remove existing search engines or to add new ones simply by adding or removing both the option tag identifying the search engine and the corresponding case statement that sets the URL for that search engine.

 

This article written by Stephen Chapman, Felgall Pty Ltd.

go to top

FaceBook Follow
Twitter Follow
Donate