Free Search Feature for your Site
<!-- The First version of this script is available at --> <!-- http://javascript.internet.com --> <!-- TWO STEPS TO FREE-INSTALL MEGELLEN SEARCH FEATURE: --> <!-- 1. Paste the code into the HEAD of your HTML document --> <!-- 2. Put the last code into the BODY of your HTML document --> <!-- STEP ONE: Copy this code into the <HEAD> of your HTML document --> <SCRIPT LANGUAGE="JavaScript" TYPE="text/javascript"> <!-- Begin Yahoo = "http://search.yahoo.com/bin/search?p="; askjeeves = "http://www.ask.co.uk/reply.asp?sourceid=00386209595797&scope=web&origin=nnnn&qSource=n&ask="; <!-- Alta = "http://www.altavista.digital.com/cgi-bin/query?pg=q&what=web&q="; --> Direct = "http://www.directhit.com/fcgi-bin/DirectHitWeb.fcg?alias=websrch&qry="; Lycos = "http://tracker.tradedoubler.com/click?p=3227&a=335127&g=15562&url=http://www.lycos.co.uk/cgi-bin/pursuit?matchmode=and&mtemp=main&etemp=error&loc=odbottom&lpv=1&query="; <!-- Lycos = "http://www.lycos.com/cgi-bin/pursuit?query="; --> looksmart = "http://www.qksrv.net/click-1714097-6674075?url=http%3A%2F%2Fwww.looksmart.co.uk%2FLookSmartSearch.jsp%3Fmc%3Den-gb%26submit%3DGo%21%26key%3D?"; <!-- Crawler = "http://www.webcrawler.com/cgi-bin/WebQuery?searchText="; --> GoCom = "http://www.go.com/Titles?col=WW&svx=home_searchbox&sv=IS&lk=noframes&qt="; <!-- DejaNews = "http://www.deja.com/products/search/search.xp?PVW=&QRY="; --> Google = "http://www.google.com/search?q="; megellen = "http://search.mamma.com/13413?qtype=0&timeout=4&lang=13413&query= "; <!-- Go2Net = "http://search.metacrawler.com/crawler?method=0&searchType=web&format=portal&cat=web&redirect=&target=&power=1&opendir_p1=&p_region=&query=&general="; --> overture = "http://www.overture.com/d/search/p/befree/?Promo=befree0001770211&?=Go=Go&Promo=befree&Keywords="; Mamma = "http://www.mamma.com/Mamma?p1=1&timeout=4&qtype=0&query="; DogPile = "http://search.dogpile.com/texis/search?geo=no&fs=web&av=custom&engines=goto&engines=looksmart&engines=thunderstone&engines=findwhat&engines=sprinks&engines=directhit&engines=google&engines=infoseek&engines=lycos&engines=kanoodle&engines=opendir&engines=realnames&engines=altavista&engines=yahoo&q="; Excite = "http://www.excite.com/search.gw?searchType=Concept&search="; DMOZ = "http://search.dmoz.org/cgi-bin/search?search="; Snap = "http://www.nbci.com/search/directory/results/1,61,-0,00.html?tag=st.sn.fd.srch.bar&keyword="; Galaxy = "http://www.einet.net/cgi-bin/wais-text-multi?keywords="; var got=0; var url = ""; var plus=""; var mag=""; function search4(item){ stringPlus(); resultsWindow=window.open(); resultsWindow.document.open(); resultsWindow.document.write("<head><title>Close this window " + "to return to Search Page</title></head>" + "<FRAMESET ROWS=50%,50%><FRAMESET COLS=50%,50%>" + "<FRAME NAME='frame0' SRC='" + computeFrameSrc(0) + "'>" + "<FRAME NAME='frame1' SRC='" + computeFrameSrc(1) + "'>" + "</FRAMESET><FRAMESET COLS=50%,50%><FRAME NAME='frame2' " + "SRC='" + computeFrameSrc(2) + "'><FRAME NAME='frame3' " + "SRC='" + computeFrameSrc(3) + "'></FRAMESET></FRAMESET>"); resultsWindow.document.close(); got = 0; } function search2(item){ stringPlus(); resultsWindow=window.open(); resultsWindow.document.open(); resultsWindow.document.write("<head><title>Close this window " + "to return to Total search</title></head><FRAMESET ROWS=50%,50%>" + "<FRAME NAME='frame0' SRC='" + computeFrameSrc(0) + "'><FRAME " + "NAME='frame1' SRC='" + computeFrameSrc(1) + "'></FRAMESET>"); resultsWindow.document.close(); got = 0; } function stringPlus() { for (var j=0; j < window.document.choose4.text.value.length; j++) { if (window.document.choose4.text.value.charAt(j) == " ") mag += "+"; else mag += window.document.choose4.text.value.charAt(j);} } function numChecked(item) { plus = escape(item.text.value); var h=0; num=0; for (var l=0; l < item.check1.length; l++) { if (item.check1[l].checked) { h++; if (h++ <= 4){ if (l == "0"){ num = 1;} else if (l == "1") num = 2; else if (l == "2") num = 3; else if (l == "3") num = 4; else if (l == "4") num = 5; else if (l == "5") num = 6; else if (l == "6") num = 7; else if (l == "7") num = 8; else if (l == "8") num = 9; else if (l == "9") num = 10; else if (l == "10") num = 11; else if (l == "11") num = 12; else if (l == "12") num = 13; else if (l == "13") num = 14; else if (l == "14") num = 15; } } } if (h == 2) Results(num-1); else if (h == 4) search2(item); else search4(item); } function computeFrameSrc(num) { var k=-1; for (var j=got; j < document.choose4.check1.length; j++) { if (document.choose4.check1[j].checked){ k++; if (k++ <= num){ if (j == "0"){ url = Yahoo + plus; got = 1;} else if (j == "1"){ url = DMOZ + plus; got = 2;} else if (j == "2"){ url = askjeeves + plus + "&mode=and"; got = 3;} else if (j == "3"){ url = Lycos + plus + "&backlink=217&maxhits=25"; got = 4;} else if (j == "4"){ url = looksmart + plus + "&maxHits=25"; got = 5;} else if (j == "5"){ url = Google + plus; got = 6;} else if (j == "6"){ url = megellen + plus; got = 7;} else if (j == "7"){ url = overture + plus; got = 8;} else if (j == "8"){ url = Mamma + plus; got = 9;} else if (j == "9"){ url = DogPile + plus; got = 10;} return url; } } } url = "javascript:void(0)"; return url; } function Results(place){ stringPlus(); resultsWin = window.open("","results"); if (place == "0") url = Yahoo + plus; else if (place == "1") url = DMOZ + plus; else if (place == "2") url = askjeeves + plus + "&mode=and"; else if (place == "3") url = Lycos + plus + "&backlink=217&maxhits=25"; else if (place == "4") url = looksmart + plus + "&maxHits=25"; else if (place == "5") url = Google + plus + "&hits=25&disp=Text+Only"; else if (place == "6") url = megellen + plus; else if (place == "7") url = overture + plus; else if (place == "8") url = Mamma + plus; else if (place == "9") url = DogPile + plus; resultsWin.location = url; } // End --> </script> <!-- -------------------------END OF STEP ONE:----------------- --> <!-- --------------- STEP TWO ------------ --> <!-- STEP TWO: Copy this code into the BODY of your HTML document --> <!-- position it where you want the search feature to be displayed --> <TABLE WIDTH="100%" HEIGHT="8" CELLSPACING="0"> <TR> <TD WIDTH="778" HEIGHT="8" VALIGN="MIDDLE" ALIGN="right" BGCOLOR="gold"> <TABLE WIDTH="100%" HEIGHT="8" BORDERCOLOR="maroon" CELLPADDING="0" CELLSPACING="0" BORDER="0"> <TR> <TD WIDTH="100%" BGCOLOR="#ffd700"> <form name="choose4" action="javascript:numChecked(document.choose4) //"> <center> <table><tr><td><b>Directories</b><br> <input type="checkbox" name="check1" value="Yahoo" onClick="choose4.check1.value='Yahoo'">Yahoo<br> <input type="checkbox" name="check1" value="DMOZ" onClick="choose4.check1.value='DMOZ'">DMOZ<br> <!-- <input type="checkbox" name="check1" value="Snap" onClick="choose4.check1.value='Snap'">closed<br><br> --> </td> <td width="15"></td> <td><b> </b><br> <!-- <input type="checkbox" name="check1" value="Snap" onClick="choose4.check1.value='Snap'">closed<br><br> --> <input type="checkbox" name="check1" value="askjeeves" onClick="choose4.check1.value='askjeeves'">Ask Jeeves<br> <!-- <input type="checkbox" name="check1" value="Direct" onClick="choose4.check1.value='Direct'">closed<br> --> <input type="checkbox" name="check1" value="Lycos" onClick="choose4.check1.value='Lycos'">Lycos<br></td> <!-- <input type="checkbox" name="check1" value="Excite" onClick="choose4.check1.value='Excite'">Excite main page only<br> --> <td width="15"></td> <td><b>Search Engines</b><br> <input type="checkbox" name="check1" value="looksmart" onClick="choose4.check1.value='looksmart'">LookSmart<br> <!-- <input type="checkbox" name="check1" value="Go.com" onClick="choose4.check1.value='Go.com'">Go.com main page only<br> --> <!-- <input type="checkbox" name="check1" value="DejaNews" onClick="choose4.check1.value='DejaNews'">closed<br> --> <input type="checkbox" name="check1" value="Google" onClick="choose4.check1.value='Google'">Google<br> </td> <td width="15"></td> <td><b></b><br> <input type="checkbox" name="check1" value="megellen" onClick="choose4.check1.value='megellen'">Megellen<br> <input type="checkbox" name="check1" value="overture" onClick="choose4.check1.value='overture'">Overture<BR></td> <td width="15"></td> <td> </td> </tr></table> </center> <center> <B> Search 4 engines simultaneously :</B> <br> <input type="text" name="text" size=17> <input type="submit" name="send" value="Search"> </center> </form> </TD> </TR> </TABLE> </TD> </TR> </TABLE> <!-- -------END OF STEP TWO - you ARE FINISHED:------ -->
Change the TABLE BGCOLOR from "=gold"
if another colour suits your site better