//SEARCH SCRIPT

function search(){

var title = new Array(68);
var desc = new Array(68);
var links = new Array(68);
var matched = new Array(68);
var key = new Array(68);
var found = new Array(68);
var temp=0;
title[0]=67; 
key[0]=0; 
found[0]=0;

title[1]="art gallery galleries painting painter exhibition";
desc[1]="Kolkata art and gallaries";
links[1]="http://www.kolkatainformation.com/artgallery.html";
matched[1]=0;

title[2]="clubs";
desc[2]="Private clubs of kolkata";
links[2]="http://www.kolkatainformation.com/club.html";
matched[2]=0;

title[3]="tour kolkata museums market places eating cinema clubs culture university library reasearch institute tourist spot";
desc[3]="Tour kolkata";
links[3]="http://www.kolkatainformation.com/tourkolkata.html";
matched[3]=0;

title[4]="Message Board";
desc[4]="Important information about kolkatainformation.com";
links[4]="http://www.kolkatainformation.com/message.html";
matched[4]=0;

title[5]="currency converter inr euro dollar pound sterling yen dm";
desc[5]="Convert your Currency";
links[5]="http://www.kolkatainformation.com/currency.html";
matched[5]=0;

title[6]="features kolkata";
desc[6]="Different topics related to kolkata";
links[6]="http://www.kolkatainformation.com/index.html";
matched[6]=0;

title[7]="cuisine recipe food";
desc[7]="Traditional Bengali recipe";
links[7]="http://www.kolkatainformation.com/cuisine.html";
matched[7]=0;

title[8]="reviews kolkata";
desc[8]="Review on different topics";
links[8]="http://www.kolkatainformation.com/index.html";
matched[8]=0;

title[9]="police station thana traffic dg dig sp commissioner headquarter lalbazar";
desc[9]="Kolkata Police details";
links[9]="http://www.kolkatainformation.com/police.html";
matched[9]=0;

title[10]="post office p.o gpo zip postal code postmaster";
desc[10]="Kolkata Post Office with Zip";
links[10]="http://www.kolkatainformation.com/postoffice.html";
matched[10]=0;

title[11]="library libraries bookshop bookshops book literature nationallibrary";
desc[11]="Kolkata Libraries";
links[11]="http://www.kolkatainformation.com/library.html";
matched[11]=0;

title[12]="publishinghouse publish house publishers";
desc[12]="Publishing houses of kolkata";
links[12]="http://www.kolkatainformation.com/publisher.html";
matched[12]=0;

title[13]="associations ipf compass cab ifa elma";
desc[13]="Corporate Associations";
links[13]="http://www.kolkatainformation.com/association.html";
matched[13]=0;

title[14]="corporate houses";
desc[14]="Corporate houses of kolkata";
links[14]="http://www.kolkatainformation.com/corporate.html";
matched[14]=0;

title[15]="government banks insurance financial foreign scheduled private lic sbi rbi";
desc[15]="Banks Insurance companies of kolkata";
links[15]="http://www.kolkatainformation.com/bank.html";
matched[15]=0;

title[16]="courier services";
desc[16]="Courier and C&F agents of kolkata";
links[16]="http://www.kolkatainformation.com/courier.html";
matched[16]=0;

title[17]="stock index stockindex indices bse nse cse";
desc[17]="Major Domestic and International Stock Indices";
links[17]="http://www.kolkatainformation.com/stock.html";
matched[17]=0;

title[18]="forex us dollar pound sterling dm yen";
desc[18]="Today's Forex rate";
links[18]="http://www.kolkatainformation.com/forex.html";
matched[18]=0;

title[19]="university college cu jadavpur ju ignou rbu";
desc[19]="Universities and Colleges of kolkata ";
links[19]="http://www.kolkatainformation.com/university.html";
matched[19]=0;

title[20]="professional technical medical merine institute institutions";
desc[20]="Professional institutions of kolkata";
links[20]="http://www.kolkatainformation.com/institution.html";
matched[20]=0;

title[21]="schools boys girls coed icse isc wbbse wbchse";
desc[21]="Schools of kolkata streamwise";
links[21]="http://www.kolkatainformation.com/school.html";
matched[21]=0;

title[22]="Colleges science commerce arts";
desc[22]="Colleges in kolkata";
links[22]="http://www.kolkatainformation.com/college.html";
matched[22]=0;

title[23]="disco discotheques nightclub";
desc[23]="Night Clubs of kolkata";
links[23]="http://www.kolkatainformation.com/discotheque.html";
matched[23]=0;

title[24]="cinema cinemahalls halls theatre entertainment movie";
desc[24]="Cinema Halls of kolkata";
links[24]="http://www.kolkatainformation.com/cinema.html";
matched[24]=0;

title[25]="restaurants eatinghouse chinese mughlai continental cuisine vegetarian nonveg cafe coffee shop";
desc[25]="Eating house of kolkata cuisine wise";
links[25]="http://www.kolkatainformation.com/restaurant.html";
matched[25]=0;

title[26]="emergency ambulance blood bloodbank police firebrigade oxygen airlines burning ghat hearse hospital nurse nursinghome railway utility phones";
desc[26]="Utility Phones of Kolkata";
links[26]="http://www.kolkatainformation.com/utility.html";
matched[26]=0;

title[27]="doctors plastic cosmetic surgery services";
desc[27]="Doctors on Phone";
links[27]="http://www.kolkatainformation.com/doctor.html";
matched[27]=0;

title[28]="hospitals cardiac cardiology sskm rgkar rubi nilratan chittaranjan peerless national mediac dental";
desc[28]="Hospital info of kolkata";
links[28]="http://www.kolkatainformation.com/hospital.html";
matched[28]=0;

title[29]="nursinghomes belleview woodland kolkata heart research";
desc[29]="Nursing Homes of kolkata";
links[29]="http://www.kolkatainformation.com/nursinghome.html";
matched[29]=0;

title[30]="diagnostic medical pathology x-ray centers heart research";
desc[30]="Diagnostic Centers of kolkata";
links[30]="http://www.kolkatainformation.com/diagnostic.html";
matched[30]=0;

title[31]="newspaper doordarshan akashbani periodical magazine annandabazar aajkal ganashakti bartaman pratidin telegraph statesman business economics times of india media";
desc[31]="Print Electronic media of the city";
links[31]="http://www.kolkatainformation.com/media.html";
matched[31]=0;

title[32]="researchinstitute researchinstitutions bhaba saha institute nuclear bose";
desc[32]="Research institutes of kolkata";
links[32]="http://www.kolkatainformation.com/research.html";
matched[32]=0;

title[33]="science sciencecity";
desc[33]="Science City information";
links[33]="http://www.kolkatainformation.com/sciencecity.html";
matched[33]=0;

title[34]="marketplace shopping bazar newmarket";
desc[34]="Shopping centers of kolkata location wise";
links[34]="http://www.kolkatainformation.com/bazar.html";
matched[34]=0;

title[35]="jewelry jewellery jewels jewells pc chandra pcchandra jewellers";
desc[35]="Jewelry Shops of kolkata ";
links[35]="http://www.kolkatainformation.com/jewellery.html";
matched[35]=0;

title[36]="sportsclub sportsbodies mohanbagan eastbengal mohamedan club";
desc[36]="Sports details of kolkata";
links[36]="http://www.kolkatainformation.com/club.html";
matched[36]=0;

title[37]="consulates";
desc[37]="Consulate Offices  of kolkata";
links[37]="http://www.kolkatainformation.com/consulate.html";
matched[37]=0;

title[38]="tourist information govt offices government";
desc[38]="Tourist info and guide";
links[38]="http://www.kolkatainformation.com/touristoffice.html";
matched[38]=0;

title[39]="hotels accomodation five four three star taj bengal oberoi grand sonar bangla itc hyatt regency park hindustan";
desc[39]="Accomodation info of kolkata";
links[39]="http://www.kolkatainformation.com/hotel.html";
matched[39]=0;

title[40]="surfacetransport roadtransport ctc sbstc nbstc office state transport";
desc[40]="Road Transport  of kolkata";
links[40]="http://www.kolkatainformation.com/transport.html";
matched[40]=0;

title[41]="airlince airlines airways sahara india british klm indianairlines airport domestic international";
desc[41]="Airlince office address and phones";
links[41]="http://www.kolkatainformation.com/airlines.html";
matched[41]=0;

title[42]="railwayoffice railways rail train metro eastern railway southern northen western office";
desc[42]="Railway office address and phones";
links[42]="http://www.kolkatainformation.com/railways.html";
matched[42]=0;

title[43]="travelagency travelagents agent altair";
desc[43]="Travel Agencies of kolkata";
links[43]="http://www.kolkatainformation.com/travelagent.html";
matched[43]=0;

title[44]="Eatingout";
desc[44]="Eatingout of kolkata";
links[44]="http://www.kolkatainformation.com/restaurant.html";
matched[44]=0;

title[45]="sightseeing tour kolkata darjeeling elgin hotels";
desc[45]="Tour kolkata sitting at your home";
links[45]="http://www.kolkatainformation.com/sight.html";
matched[45]=0;

title[46]="weather index";
desc[46]="Weather of kolkata and around the globe";
links[46]="http://www.kolkatainformation.com/index.html";
matched[46]=0;

title[47]="bullion rate";
desc[47]="Today's Bullion rate of kolkata";
links[47]="http://www.kolkatainformation.com/bullion.html";
matched[47]=0;

title[48]="calender calendar";
desc[48]="Calender for the current Bengali Year";
links[48]="http://www.kolkatainformation.com/calendar/calendar.html";
matched[48]=0;

title[49]="bengali panjika 1409";
desc[49]="Nirghanta for the current Bengali year";
links[49]="http://www.kolkatainformation.com/panjika.html";
matched[49]=0;

title[50]="lifestyle";
desc[50]="Write ups on Life Style";
links[50]="http://www.kolkatainformation.com/index.html";
matched[50]=0;

title[51]="sitemap";
desc[51]="Guide Lines for surfing kolkatainformation.com";
links[51]="http://www.kolkatainformation.com/sitemap.html";
matched[51]=0;

title[52]="sports cricket football";
desc[52]="Sports related matter of kolkata";
links[52]="http://www.kolkatainformation.com/sports.html";
matched[52]=0;

title[53]="healthcare psycho medical treatement kedar banerjee psychiatrist nibs";
desc[53]="Health Care info and write ups";
links[53]="http://www.kolkatainformation.com/healthcare.html";
matched[53]=0;

title[54]="business";
desc[54]="Business information of kolkata";
links[54]="http://www.kolkatainformation.com/index.html";
matched[54]=0;

title[55]="education";
desc[55]="Educational Institutes of kolkata";
links[55]="http://www.kolkatainformation.com/index.html";
matched[55]=0;

title[56]="news";
desc[56]="Today's News";
links[56]="http://www.kolkatainformation.com/news.html";
matched[56]=0;

title[57]="corporation municipalcorporation administration government offices administrative";
desc[57]="Government offices of Kolkata";
links[57]="http://www.kolkatainformation.com/govt.html";
matched[57]=0;

title[58]="great personality personalities swamiji vivekananda";
desc[58]="Eminent persons of kolkata";
links[58]="http://www.kolkatainformation.com/personalities.html";
matched[58]=0;

title[59]="indiancinema tollywood patalghar review movie";
desc[59]="Tollywood Reviews";
links[59]="http://www.kolkatainformation.com/movie.html";
matched[59]=0;


title[60]="horoscope astrology astrologer sunsign";
desc[60]="Horoscope";
links[60]="http://www.astrology-online.com/daily.htm";
matched[60]=0;


title[61]="ecard e-card greetings card";
desc[61]="Greetings card from kolkatainformation.com";
links[61]="http://www.ts.dendriteadhesive.com/kolkata-inf/e-card/e-card.html";
matched[61]=0;


title[62]="sari saree banarasi benarasi baluchuri ikkat tant tantuj iswarchandra pal";
desc[62]="Saree shops of Kolkata";
links[62]="http://www.kolkatainformation.com/saree.html";
matched[62]=0;


title[63]="chambers chamber of commerce";
desc[63]="Chambers of Kolkata";
links[63]="http://www.kolkatainformation.com/chamber.html";
matched[63]=0;


title[64]="matrimonials marraige register bride groom conjugation";
desc[64]="Matrimonial section from Kolkatainformation.com";
links[64]="http://www.kolkatainformation.com/matrimonial.html";
matched[64]=0;


title[65]="employment employee employer service job interview";
desc[65]="Employment section from Kolkatainformation.com";
links[65]="http://www.kolkatainformation.com/employment.html";
matched[65]=0;


title[66]="project guardian nibs kedar banerjee psychiatrist parents children";
desc[66]="Project Guardian";
links[66]="http://www.kolkatainformation.com/project.html";
matched[66]=0;


title[67]="it search compass";
desc[67]="IT Search";
links[67]="http://www.compassindia.com/it-directory/it-main.html";
matched[67]=0;




var skeyword=document.searchengine.keys.value.toLowerCase(); 
var check=1;
var pos=0;
var i=0;
var j=0;
var itemp=0;
var config='';
var output='';
while (true)
{
if (skeyword.indexOf("+") == -1 )
{
key[check]=skeyword;

break;
}
pos=skeyword.indexOf("+");
if (skeyword !="+")     
{
key[check]=skeyword.substring(0,pos); check++;
}
else
{
check--;
break;
}
skeyword=skeyword.substring(pos+1, skeyword.length);  
  if (skeyword.length ==0)
{
check--;
break;
}
}
 key[0]=check;
for ( i=1; i<=key[0];i++)
{
for (j=1;j<=title[0];j++)
{
if (title[j].toLowerCase().indexOf(key[i]) > -1 )
{
matched[j]++;
}
}       
}
for (i=1;i<=title[0];i++)
{
if (matched[i] > 0 )
{
found[0]++;
found[found[0]]=i;
}       
}
for (i=1;i<=found[0]-1;i++)
{
for(j=i+1;j<=found[0];j++)
{
if ( matched[found[i]]< matched[found[j]] )
{
temp= found[j];
found[j]=found[i];
found[i]=temp;
}
}
}



config='toolbar=yes,location=yes,directories=yes,status=yes,menubar=yes,scrollbars=yes,resizable=yes,left=0,top=0,width=800,height=600';
output = window.open ("","outputwindow",config);
output.document.write('<html>');
output.document.write('<title> Kolkata Information Search Results </title>');
output.document.write('<head>'); 
output.document.write('<script language="javascript">function ChangeMenu(file){top.opener.window.location.href = file;window.close();}</script>'); 
output.document.write('</head>');
output.document.write('<BODY  text=#000000  link=#2116C7 vlink =#2116C7 >');
output.document.write('<table width="750" border="0" cellspacing="0" cellpadding="0">');
output.document.write('<tr>');
output.document.write('<td>');
output.document.write('<img src="images/header1.jpg" width="750" height="83" alt="A comprehensive portal on kolkata">');
output.document.write('</td>');
output.document.write('</tr>');
output.document.write('</table>');
output.document.write('<table width="750" border="0" cellspacing="0" cellpadding="0">');
output.document.write('<tr>');
output.document.write('<td align="center">');
output.document.write('<font face="arial" size="3" color="red">');
output.document.write('<b>Your Matches</b></font>');
output.document.write('</td>');  
output.document.write('</tr>');
output.document.write('</table>');
output.document.write('<hr width="720">');
output.document.write('The Keyword(s) you searched :: '.big()); 
for(i=1;i<=key[0]; i++)
{
output.document.write( key[i].bold() +"   "); 
}
output.document.write('<br>');
if(found[0]==0)
{
output.document.write('<hr width="720">');
output.document.write("<b>No matches resulted in this search </b> <br>");
output.document.write("You may close the results and reduce the length/number  of the keywords  <br>");
}
else
{
output.document.write("<hr width='720'> <b> The Results of the search are : </b>");
output.document.write( found[0] +"  Entries found  ".italics()); 
output.document.write("<table border=1 width=750>");
for(i=1;i<=found[0];i++)
{
output.document.write("<tr><td valign=top background='images/cream-bg.gif'>");
output.document.write("<h3>" +i +"</h3>" + "</td>"); 
output.document.write("<td valign=top>"); 
itemp=found[i];
output.document.write(desc[itemp].bold() +"<br>" +"<a href=javascript:ChangeMenu('" +links[itemp]+ "')>" +links[itemp]+ "</a>" +"<br>");
temp= (matched[itemp]/key[0])*100; 
output.document.write("<i> Matched  with keywords  :: "+temp+" %  </i>" );
output.document.write("</td>");
output.document.write("</tr>"); 
matched[itemp]=0;
}
found[0]=0;
output.document.write("</table>");
}
output.document.write ("<form><center>"); 
output.document.write ("<input type='button' value='Start Another Search' onClick = 'self.close()'>") ;
output.document.write ("</center></form>");
output.document.write('</body>');
output.document.write('</html>');
output.document.close();
}