function createSearchEngine(objId, winId, parentId, formClass, selectClass, inputClass, submitClass)
 {this.id = objId;                                      //search engine object id
  this.win = winId;                                     //for window event
  this.parentId  = parentId;                            //parent id
  this.parentTag = document.getElementById(parentId);   //parent element

  /* check criterias */
  if (typeof(objId)!='string') {alert("object id is undefined, check the parameters"); return;}
  if (typeof(parentId)!='string'||this.parentTag==null) {alert("searchEngine parent id is undefined, check the parameters"); return;}

  /* define and deploy cars */
  this.form = document.createElement("form");
  this.parentTag.appendChild(this.form);
  this.form.onsubmit  = new Function(this.id+".click()");
  this.form.action    = "";
  this.form.method    = "post";
  this.form.className = formClass;

  this.select = document.createElement("select");
  this.form.appendChild(this.select);
  this.select.className = selectClass;

  this.br = document.createElement("br");
  this.form.appendChild(this.br);

  this.submit = document.createElement("div");
  this.form.appendChild(this.submit);
  this.submit.onclick = new Function(this.id+".click()");
  this.submit.className = submitClass;

  this.input = document.createElement("input");
  this.form.appendChild(this.input);
  this.input.type = "text";
  this.input.className = inputClass;

  this.cars = new Array();

  this.cars[0] = document.createElement("option");
  this.select.appendChild(this.cars[0]);
  this.cars[0].value = "http://search.about.com/fullsearch.htm?terms=qryValue&PM=59_0100_S";
  this.cars[0].innerHTML = "About";

  this.cars[1] = document.createElement("option");
  this.select.appendChild(this.cars[1]);
  this.cars[1].value = "http://www.altavista.com/sites/search/web?q=qryValue&kl=XX&pg=q";
  this.cars[1].innerHTML = "AltaVista";

  this.cars[2] = document.createElement("option");
  this.select.appendChild(this.cars[2]);
  this.cars[2].value = "http://www.altavista.com/sites/search/res_text?sc=on&hl=on&amb=txt&q=qryValue&kl=XX";
  this.cars[2].innerHTML = "AltaVista Raging";

  this.cars[3] = document.createElement("option");
  this.select.appendChild(this.cars[3]);
  this.cars[3].value = "http://search.aol.com/dirsearch.adp?query=qryValue&bfmid=11468709&siteid=38402391&bfpage=aol7";
  this.cars[3].innerHTML = "AOL Search";

  this.cars[4] = document.createElement("option");
  this.select.appendChild(this.cars[4]);
  this.cars[4].value = "http://www.ask.com/main/askjeeves.asp?ask=qryValue&origin=0&optout=1&site_name=Jeeves&metasearch=yes&ads=";
  this.cars[4].innerHTML = "Ask Jeeves";

  this.cars[5] = document.createElement("option");
  this.select.appendChild(this.cars[5]);
  this.cars[5].value = "http://www.bay9.com/cgi-local/search.cgi?keyword=qryValue&AID=1110111&PID=811938&link=&clicktrade=";
  this.cars[5].innerHTML = "Bay9 (Rockets)";

  this.cars[6] = document.createElement("option");
  this.select.appendChild(this.cars[6]);
  this.cars[6].value = "http://www.britannica.com/search?query=qryValue";
  this.cars[6].innerHTML = "Britannica";

  this.cars[7] = document.createElement("option");
  this.select.appendChild(this.cars[7]);
  this.cars[7].value = "http://groups.google.com/groups?q=qryValue&hl=en&lr=&safe=off&site=groups";
  this.cars[7].innerHTML = "Deja (Usenet)";

  this.cars[8] = document.createElement("option");
  this.select.appendChild(this.cars[8]);
  this.cars[8].value = "http://search.dogpile.com/texis/search?q=qryValue&geo=no&fs=web&adultsp=0";
  this.cars[8].innerHTML = "Dogpile";

  this.cars[9] = document.createElement("option");
  this.select.appendChild(this.cars[9]);
  this.cars[9].value = "http://easysearchall.com/search/search/Simple.php?AID=814&country=Global&month=XX&day=XX&year=XX&q=qryValue";
  this.cars[9].innerHTML = "EasySearchAll";

  this.cars[10] = document.createElement("option");
  this.select.appendChild(this.cars[10]);
  this.cars[10].value = "http://affiliate.espotting.com/search/affresults.asp?bkfill=1&hits=10&affiliateId=722&page=1&keyword=qryValue";
  this.cars[10].innerHTML = "eSpotting";

  this.cars[11] = document.createElement("option");
  this.select.appendChild(this.cars[11]);
  this.cars[11].value = "http://www.euroseek.com/query?query=qryValue";
  this.cars[11].innerHTML = "Euroseek";

  this.cars[12] = document.createElement("option");
  this.select.appendChild(this.cars[12]);
  this.cars[12].value = "http://search.excite.com/search.gw?trace=a&search=qryValue";
  this.cars[12].innerHTML = "Excite";

  this.cars[13] = document.createElement("option");
  this.select.appendChild(this.cars[13]);
  this.cars[13].value = "http://www.alltheweb.com/search?cat=web&advanced=1&type=all&query=qryValue&jsact=&lang=any&charset=iso-8859-1&wf%5Bn%5D=3&wf%5B0%5D%5Br%5D=&wf%5B0%5D%5Bq%5D=&wf%5B0%5D%5Bw%5D=&wf%5B1%5D%5Br%5D=%2B&wf%5B1%5D%5Bq%5D=&wf%5B1%5D%5Bw%5D=&wf%5B2%5D%5Br%5D=-&wf%5B2%5D%5Bq%5D=&wf%5B2%5D%5Bw%5D=&dincl=&dexcl=&hits=10&nooc=off";
  this.cars[13].innerHTML = "Fast (All Web)";

  this.cars[14] = document.createElement("option");
  this.select.appendChild(this.cars[14]);
  this.cars[14].value = "http://www.findit-quick.com/cgi-local/search/cobrand.fcgi?Terms=qryValue&affiliate=avenue_it";
  this.cars[14].innerHTML = "FindIt-Quick";

  this.cars[15] = document.createElement("option");
  this.select.appendChild(this.cars[15]);
  this.cars[15].value = "http://www.google.com/search?q=qryValue";
  this.cars[15].innerHTML = "Google";
  this.cars[15].selected = "selected";

  this.cars[16] = document.createElement("option");
  this.select.appendChild(this.cars[16]);
  this.cars[16].value = "http://www.heureka.hu/?ekezet=-1&heureka=qryValue&a_heurekac3=1&a_friss=1&domain=";
  this.cars[16].innerHTML = "Heureka HU";

  this.cars[17] = document.createElement("option");
  this.select.appendChild(this.cars[17]);
  this.cars[17].value = "http://hotbot.lycos.com/?MT=qryValue";
  this.cars[17].innerHTML = "HotBot";

  this.cars[18] = document.createElement("option");
  this.select.appendChild(this.cars[18]);
  this.cars[18].value = "http://service.bfast.com/bfast/click?pgtarg=wbsres&qvref=befree&siteid=38403203&bfpage=search11a&bfmid=20810152&QKW=qryValue";
  this.cars[18].innerHTML = "InfoSpace";

  this.cars[19] = document.createElement("option");
  this.select.appendChild(this.cars[19]);
  this.cars[19].value = "http://search.iwon.com/commerce/multisearch.jsp?searchfor=qryValue&symbol_search_select=short&alias=%2Falias%2Fsearch&type=on";
  this.cars[19].innerHTML = "iWon";

  this.cars[20] = document.createElement("option");
  this.select.appendChild(this.cars[20]);
  this.cars[20].value = "http://ixquick.com/do/metasearch.pl?query=qryValue&language=english&cat=web&linkback_url=http%3A%2F%2Fwww.avenue-it.com%2Fbin%2Fmetasearch.html&linkback_sitename=avenue-it.com";
  this.cars[20].innerHTML = "Ixquick";

  this.cars[21] = document.createElement("option");
  this.select.appendChild(this.cars[21]);
  this.cars[21].value = "http://www.jumpforce.com/index.php?Keywords=qryValue&HomeSearch.x=55&HomeSearch.y=8";
  this.cars[21].innerHTML = "Jumpforce";

  this.cars[22] = document.createElement("option");
  this.select.appendChild(this.cars[22]);
  this.cars[22].value = "http://www.kanoodle.com/results.html?query=qryValue&x=60&y=11";
  this.cars[22].innerHTML = "Kanoodle";

  this.cars[23] = document.createElement("option");
  this.select.appendChild(this.cars[23]);
  this.cars[23].value = "http://search.lycos.com/?query=qryValue&x=62&y=12";
  this.cars[23].innerHTML = "Lycos";

  this.cars[24] = document.createElement("option");
  this.select.appendChild(this.cars[24]);
  this.cars[24].value = "http://www.lynxprowler.com/?q=qryValue";
  this.cars[24].innerHTML = "Lynx Prowler";

  this.cars[25] = document.createElement("option");
  this.select.appendChild(this.cars[25]);
  this.cars[25].value = "http://search.mamma.com/Mamma?utfout=1&qtype=0&query=qryValue";
  this.cars[25].innerHTML = "Mamma";

  this.cars[26] = document.createElement("option");
  this.select.appendChild(this.cars[26]);
  this.cars[26].value = "http://search.metacrawler.com/crawler?general=qryValue&method=0&redirect=web&refer=mc-box&adultsp=0";
  this.cars[26].innerHTML = "MetaCrawler";

  this.cars[27] = document.createElement("option");
  this.select.appendChild(this.cars[27]);
  this.cars[27].value = "http://search.msn.com/results.asp?q=qryValue&FORM=SMCRT&cfg=SMCINITIAL&v=1&un=doc";
  this.cars[27].innerHTML = "MSN Search";

  this.cars[28] = document.createElement("option");
  this.select.appendChild(this.cars[28]);
  this.cars[28].value = "http://nbci.dogpile.com/texis/search?geo=no&brand=nbci&q=qryValue";
  this.cars[28].innerHTML = "NBCi (Snap)";

  this.cars[29] = document.createElement("option");
  this.select.appendChild(this.cars[29]);
  this.cars[29].value = "http://search.dmoz.org/cgi-bin/search?search=qryValue";
  this.cars[29].innerHTML = "Open Directory";

  this.cars[30] = document.createElement("option");
  this.select.appendChild(this.cars[30]);
  this.cars[30].value = "http://www.search.com/search?channel=1&tag=st.se.fd..sch&q=qryValue";
  this.cars[30].innerHTML = "Search.com";

  this.cars[31] = document.createElement("option");
  this.select.appendChild(this.cars[31]);
  this.cars[31].value = "http://www.searchfeed.com/rd/SearchResults.jsp?p=632&SearchString=qryValue";
  this.cars[31].innerHTML = "Searchfeed.com";

  this.cars[32] = document.createElement("option");
  this.select.appendChild(this.cars[32]);
  this.cars[32].value = "http://6netave.com/search/search/Simple.php?AID=431851&country=Global&month=XX&day=XX&year=XX&q=qryValue";
  this.cars[32].innerHTML = "6NetAve";

  this.cars[33] = document.createElement("option");
  this.select.appendChild(this.cars[33]);
  this.cars[33].value = "http://search.sprinks.about.com/search.htm?terms=qryValue";
  this.cars[33].innerHTML = "Sprinks";

  this.cars[34] = document.createElement("option");
  this.select.appendChild(this.cars[34]);
  this.cars[34].value = "http://se.stonediver.com/search_results.php?fSearch_id=4d157da41f7d0906&fString=qryValue";
  this.cars[34].innerHTML = "Stonediver";

  this.cars[35] = document.createElement("option");
  this.select.appendChild(this.cars[35]);
  this.cars[35].value = "http://trocadeiro.com/search/Simple.php?AID=19997&country=Global&month=XX&day=XX&year=XX&q=qryValue";
  this.cars[35].innerHTML = "Trocadeiro";

  this.cars[36] = document.createElement("option");
  this.select.appendChild(this.cars[36]);
  this.cars[36].value = "http://msxml.excite.com/info.xcite/search/web/qryValue";
  this.cars[36].innerHTML = "WebCrawler";

  this.cars[37] = document.createElement("option");
  this.select.appendChild(this.cars[37]);
  this.cars[37].value = "http://search.yahoo.com/bin/search?p=qryValue";
  this.cars[37].innerHTML = "Yahoo";

  /* define events */
  this.win.cancelCalls.push(this.id+".cancel()");

  /* define methods */
  this.click = function()
    {searchText = this.input.value;
     if(searchText != "")
       {searchText = searchText.replace(/\s/ig, "+");
        searchUrl  = this.select.value;
        searchUrl  = searchUrl.replace("qryValue", searchText);
        searchWin=window.open(searchUrl,"searchResult","width=screen.availWidth,height=screen.availHeight,scrollbars,toolbar,menubar=1,location=1,resizable=1,status=1,directories=0,top=0,left=0");
        searchWin.focus();
       }
    }

  this.cancel = function()
    {this.id = null;
    }
 }