var JSEARCH = {
  requiredAttrParams: ["btn_type" , "btn_lbl" , "kw_lbl" , "cat_lbl" , "loc_lbl" , "div_lbl" ],

  create: function( SO , id , parentid ) {
    DROP.setElementDisplay(parentid, "none");
    var loadfn = function() {
      if (DROP.hasRequiredAttrParams(SO)) {
        JSEARCH.init( SO, id , parentid );
      }
      DROP.setElementDisplay(parentid, "block");
    };
    DROP.addLoadEvent(loadfn);
  },

  init: function( SO , id , parentid ){

    if( !document.getElementById || !document.getElementsByTagName ) return;
    var objTarget = document.getElementById( id );
    var objParent = document.getElementById( parentid );
    if (typeof objTarget.innerHTML == "undefined" || typeof objParent.innerHTML == "undefined") return;

    var strOutPut = '';
    objTarget.innerHTML = '';

    strOutPut += '<form action="" method="post">\n';

    strOutPut += '<span class="wrapper"><label for="' + id + '_keywords">' + SO.kw_lbl + '</label><input type="text" id="' + id + '_keywords" class="txt" maxlength="30" /></span>';

    strOutPut += '<span class="wrapper"><label for="' + id + '_category" class="hide">' + SO.cat_lbl + '</label><select id="' + id + '_category">';
    strOutPut += '<option value="">' + SO.cat_lbl + '</option>';
    strOptions = '';
    for( x=0 ; x<JSEARCH.CatItems.length ; x++ ){
      strOptions += JSEARCH.addOption( JSEARCH.CatItems[x].split('|')[1] , JSEARCH.CatItems[x].split('|')[0] , '' );
    } 
    strOutPut += strOptions;
    strOutPut += '</select></span>';

    strOutPut += '<span class="wrapper"><label for="' + id + '_location" class="hide">' + SO.loc_lbl + '</label><select id="' + id + '_location">';
    strOutPut += '<option value="">' + SO.loc_lbl + '</option>';
    strOptions = '';
    for( x=0 ; x<JSEARCH.LocItems.length ; x++ ){
      strOptions += JSEARCH.addOption( JSEARCH.LocItems[x].split('|')[1] , JSEARCH.LocItems[x].split('|')[0] , '' );
    } 
    strOutPut += strOptions;
    strOutPut += '</select></span>';

    strOutPut += '<span class="wrapper"><label for="' + id + '_division" class="hide">' + SO.loc_lbl + '</label><select id="' + id + '_division">';
    strOutPut += '<option value="">' + SO.div_lbl + '</option>';
    strOptions = '';
    for( x=0 ; x<JSEARCH.DivisionItems.length ; x++ ){
      strOptions += JSEARCH.addOption( JSEARCH.DivisionItems[x].split('|')[1] , JSEARCH.DivisionItems[x].split('|')[0] , '' );
    } 
    strOutPut += strOptions;
    strOutPut += '</select></span>';

    strOutPut += '<a href="#" title="' + SO.btn_lbl + '" class="btn btn' + SO.btn_type + '" id="' + id + '_btn" target="_blank"><span>' + SO.btn_lbl + '</span></a>\n';
    strOutPut += '</form>\n';

    objTarget.innerHTML = strOutPut;

    objButton = document.getElementById( id + '_btn' );
    if( objButton ){
      addEvent( objButton , 'click' , JSEARCH.processClick , false );
    }

    addclass( objTarget , 'selector' );
    objParent.style.overflow = 'visible';
    objParent.style.overflow = '';
  },

  addOption: function( strval , strtext , id ){
    strIdAttrib = id != '' ? ' id="' + id + '"' : '';
    strTemp = '<option value="' + strval + '"' + strIdAttrib + '>' + strtext + '</option>\n';
    return strTemp;
  },

  processClick: function(e){
    var curNode = window.event ? window.event.srcElement: e ? e.target : null;
    if( curNode == null ) return;

    divBase = ascendDOM( curNode , 'div' );
    if( divBase.nodeName.toLowerCase() != 'div' || !divBase.id ) return;

    strSelected = 'http://kcnde.jobseu.recruitadvantage.com/job/job_search_result.cfm?cLang=Danish';

    objKw = document.getElementById( divBase.id + '_keywords' );
    objCat = document.getElementById( divBase.id + '_category' );
    objLoc = document.getElementById( divBase.id + '_location' );
    objDivision = document.getElementById( divBase.id + '_division' );

    strKw = objKw ? escape( objKw.value ) : '';
    strCat = objCat ? objCat.options[objCat.selectedIndex].value : '';
    strLoc = objLoc ? objLoc.options[objLoc.selectedIndex].value : '';
    strDivision = objDivision ? objDivision.options[objDivision.selectedIndex].value : '';

    if( strKw == '' && strCat == '' && strLoc == '' && strDivision == '' ){
      curNode.href = 'http://kcnde.jobseu.recruitadvantage.com/job/job_search.cfm?cLang=Danish';
    }
    else {
 
              { if (strCat == '' ){ (strCat = '0' );}
              if (strLoc == '') { (strLoc = '0');}
              if  (strDivision == '') {(strDivision = '0' );}}
                        curNode.href = strSelected + '&frm_loc_id=' + strLoc + '&frm_ind_id=' + strCat + '&frm_job_type_id=' + strDivision + '&frm_keyword=' + strKw;

         }

    return true;
  },



  CatItems: ["Alle|0", "Administration|3887", "Automobilindustri|3889", "Bank/Finans|3890", "Bioteknologi/Farmakologi|3891", "Butik/Detailhandel|3937", "Call Centre|3892", "Catering/Nærings- og Nydelsesmidler|3893", "Detailhandel /Butik|3934", "Forsikring|3916", "Forskning|3935", "Handel - øvrige|3940", "Hjemmeservice|3911", "Indkøb|3930", "Industri/chauffør|3914", "Industri/produktion og lager|3918", "Informationsteknologi|3915", "Ingeniør rådgivning|3904", "IT - Hardware|3896", "IT - Software|3897", "Jura|3917", "Kantine/køkken|3894", "Klinisk Forskning|3895", "Konsulentvirksomhed|3898", "Kontor og Administration|3925", "Kreativ / Reklame / AD'er|3899", "Kundeservice|3900", "Kvalitetssikring/kontrol|3931", "Lager assistance|3922", "Landbrug|3888", "Ledelse|3907", "Logistik|3919", "Marketing|3921", "Mediavirksomhed|3923", "Messe/udstillinger|3912", "Næringsmiddelindustri/produktion|3906", "Offentlige erhverv|3908", "Olie og gas|3926", "Øvrig handel/tjenester|3928", "Øvrige specialister/tjenester|3938", "Personale administration/udvikling|3913", "Produktion|3920", "Produktion, montering af elektroniske produkter|3902", "Projektstyring|3929", "Regnskab/Økonomi/Revision|3905", "Rekrutterings bureau|3903", "Salg og markedsføring|3933", "Salg/Telesalg|4559", "Sundhed|3909", "Sygepleje|3924", "Teknisk / Ingeniørtjenester|3939", "Transport|3941", "Tung-metal Industrien|3910", "Uddannelsesinstitution/Kursusvirksomhed|3901", "Videnskab|3936"],

  LocItems: ["Alle|0", "Århus Amt|1509", "Bornholms Amt|1510", "Færøerne|1511", "Frederiksborg Amt|1512", "Fyns Amt|1513", "Grønland|1514", "Københavns Amt|1515", "Nordjyllands Amt|1516", "Ribe Amt|1517", "Ringkjøbing Amt|1518", "Roskilde Amt|1519", "Sønderjyllands Amt|1520", "Storstrøms Amt|1521", "Vejle Amt|1522", "Vestsjællands Amt|1523", "Viborg Amt|1524", "International|-1"],

  DivisionItems: ["Alle|0", "Deltid|4", "Fast stilling|3", "Fuld tid|2", "Sæson|12", "Vikar stilling|15"]

};


<!--
//Server:WWb01
-->
