function zur_suche(){
    if (uebergabe_suchestart) {
        window.location.href=t3url+uebergabe_suchestart+'&showresult=2';
    }
    else {
        window.location.href=t3url+uebergabe+'&showresult=2';
    }
}

function zum_zielgebiet(){
    window.location.href=t3url+uebergabe+'&detail=zielgebiet&showresult=1';
}

function s_termine(kenner_id){
    //Omniture Tracking
    var omni_sel_nr = startpos + kenner_id + 1;
    omni_sel_nr += "v"+anzahl_treffer_gesamt;
    
    part=regionen_2[kenner_id].split('#');    
    window.location.href=t3url+uebergabe+'&IFF='+part[2]+'&zielgebiets_kenner='+part[10]+'&detail=termine&showresult='+part[11]+'&startposition_hotel='+part[12]+'&sel_position_hotel='+omni_sel_nr;
}

function ortsucher(ort,sortierung){
    part=regionen_2[0].split('#');
    window.location.href=t3url+uebergabe+'&sortierung='+sortierung+'&detail=hotel&startposition=0&zielgebiets_kenner='+part[10]+'&showresult='+part[11]+'&s_ort='+escape(ort);
}

function horder(sortierung)
{
    part=regionen_2[0].split('#');
    window.location.href=t3url+uebergabe+'&sortierung='+sortierung+'&detail=hotel&startposition=0&zielgebiets_kenner='+part[10]+'&showresult='+part[11];
}

function MakeStars(nStars,pfad_images)
{
    var strStars="";
    while(nStars>0){
        strStars+='<img src="'+pfad_images+'/'+((nStars>5)?'1stern_weiss':'1stern_halb_weiss')+'.gif" border="0" class="tt_hot_stars" align="absmiddle">';
        nStars-=10;
    }
    return strStars;
}

function s_hotel_tabelle(pfad_images, nuralt)
{
   var n_AltFlag=0; var n_TopFlag=0;
   var linienchecker = 0; //zähler für zwischenlinien
   var alt_txt;
   var omni_sel_nr;
   if(regionen_2.length <= 0) {}
   else
   {         
        for(i=0;i<regionen_2.length;i++)
        {
            // Omniture Tracking
            omni_sel_nr = startpos + i + 1;
            omni_sel_nr += "v"+anzahl_treffer_gesamt;
             
            parts=regionen_2[i].split("#");
            if(parts[9]==0){
                if(n_TopFlag==0){ 
                    alt_txt="";  
                    n_TopFlag=1;
                }
            }
            else{
                if(n_AltFlag==0){ 
                    alt_txt="&nbsp;(alternativ)";  
                    
                    if(nuralt!=1){
                        //Alternative
                        document.write('<div class="tt_hotTab">');
                        document.write('    <div class="tt_font4b tt_padleft2 tt_lineheight40">Alternative Angebote, die Ihren Urlaubswünschen nahe kommen</div>');
                        document.write('</div>');
                        
                        n_AltFlag=1;
                        var i_alt=0;
                        linienchecker = 0;                         
                    }
                }
            }
            
            var showHotelName = "";
            var count_HotelLength = parts[6].length;
            if (count_HotelLength > 34){
                showHotelName = parts[6].substr(0, 31);
                showHotelName += "...";
            }
            else{
                showHotelName = parts[6];
            }
            var showOrtName = "";
            var count_OrtLength = parts[7].length;
            if (count_OrtLength > 36){
                showOrtName = parts[7].substr(0, 33);
                showOrtName += "...";
            }
            else{
                showOrtName = parts[7];
            }
            
            var abstandInhalte = '';
            if (linienchecker > 0)
                abstandInhalte = ' tt_martop2';
            
            var angAttVal = 0;
            if(parts[14] & 65536){
                angAttVal = 3;
            }
            if(parts[14] & 131072){ 
                if (angAttVal > 0)
                    angAttVal = 5;
                else
                    angAttVal = 2;
            }
            
            // *** Inhalt Angebot
            document.write('<div class="tt_hotBgHotel'+abstandInhalte+'">');
            document.write('<table cellpadding="0" cellspacing="0" border="0">');  
            document.write('<tr>');
            document.write('<td colspan="4" valign="top" height="29">');
            //hotelname, sterne
            document.write('    <div style="float:left;width:500px;height:29px;overflow:hidden;">');
            document.write('        <div class="tt_font15b tt_padleft4 tt_padtop tt_padright" style="white-space:nowrap;" title="'+parts[6]+'">');
            //document.write('        <a class="tt_hotelinfo" href="javascript:void(0);" onClick="oHIB(\''+parts[2]+'\',\''+parts[2]+'\',\''+parts[3]+'\',\'1\',\'\',\'\',\''+parts[4]+'\',\''+parts[13]+'\',\'\',\'\',\'\',\'\',\'\',\'hotel\');return false;">'+showHotelName+'</a>');
            // Omniture Tracking
            document.write('        <a class="tt_hotelinfo" href="javascript:void(0);" onClick="oHIB(\''+parts[2]+'\',\''+parts[2]+'\',\''+parts[3]+'\',\'1\',\'\',\'\',\''+parts[4]+'\',\''+parts[13]+'\',\'\',\'\',\'\',\'\',\'\',\'hotel\',\'\',\'\',\'\',\''+engine+'\',\'\',\''+HLAND+'\',\''+omni_sel_nr+'\',\'\',\'\',\'1\');return false;">'+showHotelName+'</a>');
            document.write('        <span class="tt_marleft">');
            nSterne=Math.floor(parts[4]*10);
            document.write(MakeStars(nSterne,pfad_images));
            document.write('        </span>');
            document.write('        </div>');
            document.write('    </div>');
            //ort
            document.write('    <div style="float:left;width:384px;height:29px;overflow:hidden;" title="'+parts[7]+'">');
            document.write('        <div class="tt_font15b tt_padleft tt_padtop" style="white-space:nowrap;text-align:right;padding-right:23px;">'+showOrtName+'</div>');            
            document.write('    </div>');
            document.write('</td>');
            document.write('</tr>');
            document.write('<tr>');   
            //thumbnail
            document.write('    <td class="tt_hot_colA" valign="top" rowspan="2">');
            //document.write('    <a href="javascript:void(0);" onClick="oHIB(\''+parts[2]+'\',\''+parts[2]+'\',\''+parts[3]+'\',\'1\',\'\',\'\',\''+parts[4]+'\',\''+parts[13]+'\',\'\',\'\',\'\',\'\',\'\',\'hotel\');return false;" title="Informationen zu Hotel und Leistungen anzeigen">');
            // Omniture Tracking
            document.write('    <a href="javascript:void(0);" onClick="oHIB(\''+parts[2]+'\',\''+parts[2]+'\',\''+parts[3]+'\',\'1\',\'\',\'\',\''+parts[4]+'\',\''+parts[13]+'\',\'\',\'\',\'\',\'\',\'\',\'hotel\',\'\',\'\',\'\',\''+engine+'\',\'\',\''+HLAND+'\',\''+omni_sel_nr+'\',\'\',\'\',\'1\');return false;" title="Informationen zu Hotel und Leistungen anzeigen">');
            np=String(parseInt(parts[2]/5000)*5000);
            while(np.length<5)np="0"+np;
            document.write('    <img src="'+imgservPfad+'/images/content/booking_thumbs_mi/'+np+'/THB_999_H'+parts[2]+'.jpg" height="120" width="170" alt="Informationen zu Hotel und Leistungen anzeigen" border="0">'); 
            document.write('    </a>');
            document.write('    </td>');
            // Teaser-Text
            document.write('    <td class="tt_hot_colsBC" valign="top" colspan="2" height="82">');
            if (parts[19] != '') {
                var teaserTitle='Lesen Sie die ausführliche Hotelbeschreibung';
                //document.write('<div class="tt_padtop tt_padright4"><a class="tt_hotteaser" href="javascript:void(0);" onclick="oHIB(\''+parts[2]+'\',\''+parts[2]+'\',\''+parts[3]+'\',\'1\',\'\',\'\',\''+parts[4]+'\',\''+parts[13]+'\',\''+parts[18]+'\',\'\',\'\',\'\',\'\',\'hotel\');return false;" title="'+teaserTitle+'">' + parts[19] + '</a></div>');
                // Omniture Tracking
                document.write('<div class="tt_padtop tt_padright4"><a class="tt_hotteaser" href="javascript:void(0);" onclick="oHIB(\''+parts[2]+'\',\''+parts[2]+'\',\''+parts[3]+'\',\'1\',\'\',\'\',\''+parts[4]+'\',\''+parts[13]+'\',\''+parts[18]+'\',\'\',\'\',\'\',\'\',\'hotel\',\'\',\'\',\'\',\''+engine+'\',\'\',\''+HLAND+'\',\''+omni_sel_nr+'\',\'\',\'\',\'1\');return false;" title="'+teaserTitle+'">' + parts[19] + '</a></div>');
            }             
            document.write('    </td>');
            //Hotelbewertung
            document.write('    <td class="tt_hot_colD" valign="top">');
            document.write('    <div class="tt_padtop">');             
            if(showHbw==1){                 
                if(parts[17]!=''){
                    hbw_details=parts[17].split("_");
                    if(hbw_details[0]>1){
                        str_hbw_txt='Hotelbewertungen';
                    }
                    else{
                        str_hbw_txt='Hotelbewertung';
                    }
                    document.write('<div class="tt_hotDivHbw">');                    
                    document.write('    <div class="tt_font10"><b>'+hbw_details[0]+'</b> '+str_hbw_txt+'</div>');
                    document.write('    <div style="height:18px; line-height:18px;"><div class="tt_hbwImgline_le"><img src="'+pfad_images+'/hbw/scale_small/small_scale_'+hbw_details[2]+'.gif" border="0" alt="Gesamtbewertung" title="Gesamtbewertung '+hbw_details[2].substring(0,1)+'.'+hbw_details[2].substring(1,2)+' von 6"></div><div class="tt_hbwImgline_ri"><span class="tt_font13b">'+hbw_details[2].substring(0,1)+'.'+hbw_details[2].substring(1,2)+'</span></div></div>');
                    //document.write('    <div class="tt_font1" style="height:14px; line-height:14px;">Jetzt <a style="text-decoration:underline;color:#CC0033;font-weight:bold;" href="javascript:void(0);" onClick="oHIB(\''+parts[2]+'\',\''+parts[2]+'\',\''+parts[3]+'\',\'9\',\'\',\'\',\''+parts[4]+'\',\''+parts[13]+'\',\'\',\'\',\'\',\'\',\'\',\'hotel\');" title="Hotelbewertungen anzeigen">alle lesen!</a></div>');
                    // Omniture Tracking
                    document.write('    <div class="tt_font1_1b" style="height:14px; line-height:14px;">Jetzt <a style="text-decoration:underline;color:#003366;font-weight:bold;" href="javascript:void(0);" onClick="oHIB(\''+parts[2]+'\',\''+parts[2]+'\',\''+parts[3]+'\',\'9\',\'\',\'\',\''+parts[4]+'\',\''+parts[13]+'\',\'\',\'\',\'\',\'\',\'\',\'hotel\',\'\',\'\',\'\',\''+engine+'\',\'\',\''+HLAND+'\',\''+omni_sel_nr+'\',\'\',\'\',\'1\');" title="Hotelbewertungen anzeigen" onmouseover="this.style.color=\'#CC0033\';" onmouseout="this.style.color=\'#003366\';">alle lesen</a>!</div>');
                    if(hbw_details[0]>1){
                        document.write('    <div style="clear:both;"><div class="tt_hbw_EmpfLine_le"><span class="tt_font1_1b" style="margin-left:1px;">Weiterempfehlung:</span></div><div class="tt_hbw_EmpfLine_ri"><span class="tt_font1_1b">'+parseInt(hbw_details[1]/10)+'%</span></div></div>');
                    }
                    
                    document.write('</div>');
                }
                else{
                    document.write('&nbsp;');
                    //document.write('<div class="tt_font1" style="text-align:left;">Es liegt noch keine<br>Hotelbewertung der<br>Gäste vor.</div>');
                }
                
            }
            else{
                document.write('&nbsp;');
            }
            document.write('    </div>');              
            document.write('    </td>');
            document.write('</tr><tr>');
            //Hotelinfos
            document.write('    <td class="tt_hot_colB" valign="top" height="43" style="padding-top:7px;">');            
            //document.write('    <div class="tt_hotInfoLink" style="width:84px;" onClick="oHIB(\''+parts[2]+'\',\''+parts[2]+'\',\''+parts[3]+'\',\'1\',\'\',\'\',\''+parts[4]+'\',\''+parts[13]+'\',\'\',\'\',\'\',\'\',\'\',\'hotel\');"><img src="'+pfad_images+'/pfeil_vor_blau.gif" border="0" alt="" class="img_top" style="margin-right:5px;"><span style="text-decoration:underline;">Hotelinfos</span></div>');
            //Hotel auf Merkzettel
            var hotelname=parts[6].replace("'","\\'");
            var ort=parts[7].replace("'","\\'");
            document.write('    <div class="tt_hotInfoLink" style="with:160px; height:18px;float:right;" onClick="set_merkzettel(\''+parts[4]+'\',\''+hotelname+'\',\''+parts[2]+'\',\''+ort+'\',\''+parts[1]+'\',\''+parts[14]+'\',\''+angAttVal+'\');"><img src="'+pfad_images+'/pfeil_vor_blau.gif" border="0" alt="" class="img_top" style="margin-right:5px;"><span onmouseover="this.className=\'tt_hotInfoLinkUnderl\';" onmouseout="this.className=\'tt_hotInfoLink\';">Dieses Hotel merken</span></div>');
            // Omniture Tracking
            document.write('    <div class="tt_hotInfoLink" style="width:84px;" onClick="oHIB(\''+parts[2]+'\',\''+parts[2]+'\',\''+parts[3]+'\',\'1\',\'\',\'\',\''+parts[4]+'\',\''+parts[13]+'\',\'\',\'\',\'\',\'\',\'\',\'hotel\',\'\',\'\',\'\',\''+engine+'\',\'\',\''+HLAND+'\',\''+omni_sel_nr+'\',\'\',\'\',\'1\');"><img src="'+pfad_images+'/pfeil_vor_blau.gif" border="0" alt="" class="img_top" style="margin-right:5px;"><span onmouseover="this.className=\'tt_hotInfoLinkUnderl\';" onmouseout="this.className=\'tt_hotInfoLink\';">Hotelinfos</span></div>');            
            document.write('    </td>');
            //Termin prüfen
            document.write('    <td class="tt_hot_colC tt_padright4" align="right" valign="top" style="padding-top:6px;">');
            document.write('    <a href="javascript:void(0);" onClick="s_termine('+i+');return false;"><img src="'+pfad_images+'/hotelinfo_buchen.gif" border="0" alt="Termine und Buchung" title="Termine und Buchung" onmouseover="this.src=\''+pfad_images+'/hotelinfo_buchen_hover.gif\';" onmouseout="this.src=\''+pfad_images+'/hotelinfo_buchen.gif\';"></a>');
            document.write('    </td>');
            //Termin prüfen + Preis
            document.write('    <td class="tt_hot_colD_preis" valign="top" style="padding-top:3px;">');
            document.write('    <span class="tt_font11b">ab </span><a class="tt_hotlpreis" href="javascript:void(0);" onClick="s_termine('+i+');return false;">'+tt_formatNumber(parts[1])+'&nbsp;&euro;</a> <span class="tt_font11b" style="padding-right:14px;">p.P.</span>');
            document.write('    </td>');
            document.write('</tr></table>');
            document.write('</div>');
            
            if(n_AltFlag==1){
                i_alt++;
            } 
            
            linienchecker ++;                     

        }//Ende for-schleife
        
   }
}

/* ### Funktionen TopHotels ### */
function s_termine_topHotel(kenner_id)
{
    part=topHotels[kenner_id].split('#');
    
    var omni_sel_nr = startpos + kenner_id + 1;
    omni_sel_nr += "v"+anzahl_treffer_gesamt;
    window.location.href=t3url+uebergabe_topHotel+part[20]+'&IFF='+part[2]+'&detail=termine&showresult='+part[12]+'&startposition_hotel='+part[13]+'&sel_position_hotel='+omni_sel_nr+'&TopHotel=1';
    
}
//TopHotels Ausgabe
function s_topHotel()
{    
   var n_AltFlag=0; var n_TopFlag=0;
   var linienchecker = 0; //zähler für zwischenlinien
   var c_strOL,c_strOR,c_strL,c_strM,c_strR,alt_txt,c_strM2,c_strM3,c_strLink,c_strHotel,c_bgColor,idt;
   /* Omniture Tracking */
   var omni_sel_nr;
   
   if(topHotels.length <= 0) {}
   else
   {
        // Abstand
        document.write('<div style="padding-top:8px"></div>');
            
        for(i=0;i<topHotels.length;i++){
            // Omniture Tracking
            omni_sel_nr = startpos + i + 1;
            omni_sel_nr += "v"+anzahl_treffer_gesamt;            
            
            parts=topHotels[i].split("#");
            
            var showHotelName = "";
            var count_HotelLength = parts[6].length;
            if (count_HotelLength > 34){
                showHotelName = parts[6].substr(0, 31);
                showHotelName += "...";
            }
            else{
                showHotelName = parts[6];
            }
            var showOrtName = "";
            var count_OrtLength = parts[7].length;
            if (count_OrtLength > 36){
                showOrtName = parts[7].substr(0, 33);
                showOrtName += "...";
            }
            else{
                showOrtName = parts[7];
            }
            var abstandInhalte = '';
            if (linienchecker > 0)
                abstandInhalte = ' tt_martop2';  
                
            document.write('<div class="tt_hotBgTopHotel'+abstandInhalte+'">');
            document.write('<table cellpadding="0" cellspacing="0" border="0">');  
            document.write('<tr>');
            document.write('<td colspan="4" valign="top" height="29">');
            //hotelname, sterne
            document.write('    <div style="float:left;width:500px;height:29px;overflow:hidden;">');
            document.write('        <div class="tt_font15b tt_padleft4 tt_padtop tt_padright" style="white-space:nowrap;" title="'+parts[6]+'">');
            // Omniture Tracking
            document.write('        <a class="tt_hotelinfo" href="javascript:void(0);" onClick="oHIB(\''+parts[2]+'\',\''+parts[2]+'\',\''+parts[3]+'\',\'1\',\'\',\'\',\''+parts[4]+'\',\''+parts[14]+'\',\'\',\'\',\'\',\'\',\'\',\'hotel\',\'\',\'\',\'\',\''+engine+'\',\'\',\''+HLAND+'\',\''+omni_sel_nr+'\',\'\',\'\',\'1\');return false;">'+showHotelName+'</a>');
            document.write('        <span class="tt_marleft">');
            nSterne=Math.floor(parts[4]*10);
            document.write(MakeStars(nSterne,pfad_images));
            document.write('        </span>');
            document.write('        </div>');
            document.write('    </div>');
            //ort
            document.write('    <div style="float:left;width:384px;height:29px;overflow:hidden;" title="'+parts[7]+'">');
            document.write('        <div class="tt_font15b tt_padleft tt_padtop" style="white-space:nowrap;text-align:right;padding-right:23px;">'+showOrtName+'</div>');            
            document.write('    </div>');
            document.write('</td>');
            document.write('</tr>');
                        
            document.write('<tr>');
            // *** Inhalt Angebot
            
            //thumbnail
            document.write('    <td class="tt_hot_colA" valign="top" rowspan="2">');
            document.write('    <div class="tt_hotThumb" style="position:relative;">');
            //document.write('    <a href="javascript:void(0);" onClick="oHIB(\''+parts[2]+'\',\''+parts[2]+'\',\''+parts[3]+'\',\'1\',\'\',\'\',\''+parts[4]+'\',\''+parts[13]+'\',\'\',\'\',\'\',\'\',\'\',\'hotel\');return false;" title="Informationen zu Hotel und Leistungen anzeigen">');
            // Omniture Tracking
            document.write('    <a href="javascript:void(0);" onClick="oHIB(\''+parts[2]+'\',\''+parts[2]+'\',\''+parts[3]+'\',\'1\',\'\',\'\',\''+parts[4]+'\',\''+parts[14]+'\',\'\',\'\',\'\',\'\',\'\',\'hotel\',\'\',\'\',\'\',\''+engine+'\',\'\',\''+HLAND+'\',\''+omni_sel_nr+'\',\'\',\'\',\'1\');return false;" title="Informationen zu Hotel und Leistungen anzeigen">');
            np=String(parseInt(parts[2]/5000)*5000);
            while(np.length<5)np="0"+np;
            document.write('    <img src="'+imgservPfad+'/images/content/booking_thumbs_mi/'+np+'/THB_999_H'+parts[2]+'.jpg" height="120" width="170" alt="Informationen zu Hotel und Leistungen anzeigen" border="0">'); 
            //PNG Tophotel
            document.write('    <div style="position:absolute;top:7px;left:100px;width:71px;height:74px;z-index:10;"><img src="'+pfad_images+'/tophotel.png" border="0" alt="Top Hotel" title="Top Hotel" style="z-index:10;"></div>');
            document.write('    </a></div>'); 
            document.write('    </div>');           
            document.write('    </td>');
                   
            
            // Teaser-Text
            document.write('    <td class="tt_hot_colsBC" valign="top" colspan="2" height="82">');
            if (parts[23] != '') {
                var teaserTitle='Lesen Sie die ausführliche Hotelbeschreibung';
                document.write('<div class="tt_padtop tt_padright4"><a class="tt_hotteaser" href="javascript:void(0);" onclick="oHIB(\''+parts[2]+'\',\''+parts[2]+'\',\''+parts[3]+'\',\'1\',\'\',\'\',\''+parts[4]+'\',\''+parts[14]+'\',\''+parts[22]+'\',\'\',\'\',\'\',\'\',\'hotel\',\'\',\'\',\'\',\''+engine+'\',\'\',\''+HLAND+'\',\''+omni_sel_nr+'\',\'\',\'\',\'1\');return false;" title="'+teaserTitle+'">' + parts[23] + '</a></div>');
            }                 
            document.write('    </td>');           
            
            //Hotelbewertung 
            document.write('    <td class="tt_hot_colD" valign="top">');
            document.write('    <div class="tt_padtop">');                         
            
            if(showHbw==1){
                if(parts[21]!=''){
                    hbw_details=parts[21].split("_");
                    if(hbw_details[0]>1){
                        str_hbw_txt='Hotelbewertungen';
                    }
                    else{
                        str_hbw_txt='Hotelbewertung';
                    }                    
                    document.write('<div class="tt_hotDivHbw">');                    
                    document.write('    <div class="tt_font10"><b>'+hbw_details[0]+'</b> '+str_hbw_txt+'</div>');
                    document.write('    <div style="height:18px; line-height:18px;"><div class="tt_hbwImgline_le"><img src="'+pfad_images+'/hbw/scale_small/small_scale_'+hbw_details[2]+'.gif" border="0" alt="Gesamtbewertung" title="Gesamtbewertung '+hbw_details[2].substring(0,1)+'.'+hbw_details[2].substring(1,2)+' von 6"></div><div class="tt_hbwImgline_ri"><span class="tt_font13b">'+hbw_details[2].substring(0,1)+'.'+hbw_details[2].substring(1,2)+'</span></div></div>');
                    // Omniture Tracking
                    document.write('    <div class="tt_font1_1b" style="height:14px; line-height:14px;">Jetzt <a style="text-decoration:underline;color:#003366;font-weight:bold;" href="javascript:void(0);" onClick="oHIB(\''+parts[2]+'\',\''+parts[2]+'\',\''+parts[3]+'\',\'9\',\'\',\'\',\''+parts[4]+'\',\''+parts[14]+'\',\'\',\'\',\'\',\'\',\'\',\'hotel\',\'\',\'\',\'\',\''+engine+'\',\'\',\''+HLAND+'\',\''+omni_sel_nr+'\',\'tophotel\',\'\',\'9\',\'1\');" title="Hotelbewertungen anzeigen" onmouseover="this.style.color=\'#CC0033\';" onmouseout="this.style.color=\'#003366\';">alle lesen</a>!</div>');
                    if(hbw_details[0]>1){
                        document.write('    <div style="clear:both;"><div class="tt_hbw_EmpfLine_le"><span class="tt_font1_1b" style="margin-left:1px;">Weiterempfehlung:</span></div><div class="tt_hbw_EmpfLine_ri"><span class="tt_font1_1b">'+parseInt(hbw_details[1]/10)+'%</span></div></div>');
                    }                    
                    document.write('</div>');                    
                }
                else{
                     document.write('&nbsp;');
                }

            }
            document.write('    </div>');
            document.write('    </td>');
            
            document.write('</tr>');  
            
            
            document.write('<tr>');
            //Hotelinfos
            document.write('    <td class="tt_hot_colB" valign="top" height="43" style="padding-top:7px;">');            
            // Omniture Tracking
            document.write('    <div class="tt_hotInfoLink" style="width:84px;" onClick="oHIB(\''+parts[2]+'\',\''+parts[2]+'\',\''+parts[3]+'\',\'1\',\'\',\'\',\''+parts[4]+'\',\''+parts[14]+'\',\'\',\'\',\'\',\'\',\'\',\'hotel\',\'\',\'\',\'\',\''+engine+'\',\'\',\''+HLAND+'\',\''+omni_sel_nr+'\',\'\',\'\',\'1\');"><img src="'+pfad_images+'/pfeil_vor_blau.gif" border="0" alt="" class="img_top" style="margin-right:5px;"><span onmouseover="this.className=\'tt_hotInfoLinkUnderl\';" onmouseout="this.className=\'tt_hotInfoLink\';">Hotelinfos</span></div>');
            document.write('    </td>');            
            //Termin prüfen
            document.write('    <td class="tt_hot_colC tt_padright4" align="right" valign="top" style="padding-top:6px;">');
            document.write('    <a href="javascript:void(0);" onClick="s_termine_topHotel('+i+');return false;"><img src="'+pfad_images+'/hotelinfo_buchen_gelb.gif" border="0" alt="Termine und Buchung" title="Termine und Buchung" onmouseover="this.src=\''+pfad_images+'/hotelinfo_buchen_over_gelb.gif\';" onmouseout="this.src=\''+pfad_images+'/hotelinfo_buchen_gelb.gif\';"></a>');
            document.write('    </td>');
            //Termin prüfen + Preis
            document.write('    <td class="tt_hot_colD_preis" valign="top" style="padding-top:3px;">');
            document.write('    <span class="tt_font11b">ab </span><a class="tt_hotlpreis" href="javascript:void(0);" onClick="s_termine_topHotel('+i+');return false;">'+tt_formatNumber(parts[1])+'&nbsp;&euro;</a> <span class="tt_font11b" style="padding-right:14px;">p.P.</span>');
            document.write('    </td>');
            document.write('</tr></table>');
            document.write('</div>');
            
            linienchecker ++; 
        }

   }
}

//Transparenz bei png herstellen
function correctPNG()
{
    for(var pc=0; pc<document.images.length; pc++)
    {
        var img = document.images[pc];
        var imgName = img.src.toUpperCase();
        if (imgName.substring(imgName.length-3, imgName.length) == "PNG")
        {
            //alert('PNG '+pc);
            var imgID = (img.id) ? "id='" + img.id + "' " : "";
            var imgClass = (img.className) ? "class='" + img.className + "' " : "";
            var imgTitle = (img.title) ? "title='" + img.title + "' " : "title='" + img.alt + "' ";
            var imgStyle = "display:inline-block;" + img.style.cssText;

            if (img.align == "left") imgStyle = "float:left;" + imgStyle;
            if (img.align == "right") imgStyle = "float:right;" + imgStyle;
            if (img.href) imgStyle = "cursor:hand;" + imgStyle;
            var strNewHTML = "<span " + imgID + imgClass + imgTitle + " style=\"" + "width:" + img.width + "px; height:" + img.height + "px;" + imgStyle + ";" + "filter:progid:DXImageTransform.Microsoft.AlphaImageLoader" + "(src='" + img.src + "', sizingMethod='scale');\"></span>";
            img.outerHTML = strNewHTML;
            //pc = pc-1; /* ??? Endlosschleife */
        }
    }
}


function pageSkip(seiten,apage,sortierung){
    for (t=1;t<=seiten;t++)
    {
        zaehler=(t-1)*10;
        if(t!=apage) {
           document.write('<a href="javascript:void(0);" onClick="skippen('+zaehler+',\''+sortierung+'\');return false;" class="tt_pageskip" title="Angebote der Seite '+t+' abrufen">'+t+'</a>');
        }
        else {
            document.write('<span class="tt_pageaktive">'+t+'</span>');
        }
        if(t!=seiten) document.write('&nbsp;&nbsp;');
    }
}

function pageSkipBySteps(seiten,apage,sortierung,schritt){

    seiten = parseInt(seiten);
    apage = parseInt(apage);
    if(seiten >5)
    {
        if(apage<=5){
          var mPageStart = 1;
          var mPageEnde  = 5;
        }
        else if(apage>(seiten-1)){
          var mPageStart = (seiten-4);
          var mPageEnde  = seiten;
        }
        else{
          var mPageStart = (apage-2);
          if((apage + 2)>seiten){
            mPageStart = (seiten-4);  
          }
          var mPageEnde  = (apage + 2);
          if(mPageEnde > seiten)
            mPageEnde = seiten;
        }
    }
    else
    {
        var mPageStart = 1;
        var mPageEnde  = seiten;
    }

    for(t=mPageStart;t<=mPageEnde;t++)
    {
        var zaehler=(t-1)*schritt;
        if(t!=apage){
            document.write('<a href="javascript:void(0);" onClick="skippen('+zaehler+',\''+sortierung+'\');return false;" class="tt_pageskip" title="Angebote der Seite '+t+' abrufen">'+t+'</a>');
        }
        else{
            document.write('<span class="tt_pageaktive">'+t+'</span>');
            /*
            if(apage < seiten){
                document.write('&nbsp;&nbsp;');
            } 
            */             
        }
        if (t < mPageEnde) {
          document.write('<span style="color:#003366">&nbsp;|&nbsp;</span>');
        } else {
          document.write('&nbsp;');
        }
    }

}

function skippen(zaehler,sortierung){
    part=regionen_2[0].split('#');
    detail="hotel";
    if(DLC && DLC!="") var ldlc="&DLC="+DLC;
    else var ldlc="";
    window.location.href=t3url+uebergabe+'&sortierung='+sortierung+'&detail='+detail+'&startposition='+zaehler+'&zielgebiets_kenner='+part[10]+'&showresult='+part[11];
}

function fillOrte(s_ort){
    for (t=0;t<anzahl_treffer_orte;t++)
    {
       if(s_ort!=escape(Orte[t]))
           document.write('<option value="'+Orte[t]+'">'+Orte[t]+'</option>');
       else
           document.write('<option value="'+Orte[t]+'" SELECTED>'+Orte[t]+'</option>');
    }
}

function set_merkzettel(stern,Hotel_Name,IFF,Ort,preis,hotelattribut,angebotsAttr)
{       
    //MZ-Fenster öffnen beim Aktualisieren
    //window.open(url+'booking/'+ordner_name+'/teaser/merkzettel/merkzettel.php?KID='+KID+'&id='+mtypo_id+'&merkzettel_aktion=safe&merk_win_open=1&mhin_termin='+mhin_termin+'&mrueck_termin='+mrueck_termin+'&Laender_Ref_ID='+escape(Laender_Ref_ID)+'&mdauer='+escape(mdauer)+'&obj_sterne='+escape(stern)+'&mhotname='+encodeURI(Hotel_Name)+'&miff='+IFF+'&mhotort='+encodeURI(Ort)+'&mhotreg='+encodeURI(mhotreg)+'&mzielg='+mzielg+'&mhotland='+encodeURI(mhotland)+'&mpersonen='+escape(mpersonen)+'&mgesamtpreis='+preis+'&mhot_attribut='+escape(hotelattribut)+tmp_sessid+'&ordner_name='+ordner_name+'&hid='+HID+'&mzimmer='+mzimmer+'&mverpflegung='+mverpflegung+'&mabflughafen='+escape(mabflughafen)+'&mang_attribut='+angebotsAttr+'&port='+port+'&t3url='+escape(t3url)+'&url='+escape(url),'merkzettel','height=500,width=760,dependent=yes,scrollbars=no,menubar=no,resizable,status=no,toolbar=no');
    // ####################################################################
    //MZ-Fenster nicht öffnen
    var str_mzURL = t3url+uebergabe+'&detail=hotel&merkzettel_aktion=safe&mhin_termin='+mhin_termin+'&mrueck_termin='+mrueck_termin+'&Laender_Ref_ID='+escape(Laender_Ref_ID)+'&obj_sterne='+escape(stern)+'&mhotname='+encodeURI(Hotel_Name)+'&miff='+IFF+'&mhotort='+encodeURI(Ort)+'&mhotreg='+encodeURI(mhotreg)+'&mzielg='+mzielg+'&mhotland='+encodeURI(mhotland)+'&mpersonen='+escape(mpersonen)+'&mgesamtpreis='+preis+'&mhot_attribut='+escape(hotelattribut)+tmp_sessid+'&ordner_name='+ordner_name+'&hid='+HID+'&mzimmer='+mzimmer+'&mverpflegung='+mverpflegung+'&mabflughafen='+escape(mabflughafen)+'&mang_attribut='+angebotsAttr+'&port='+port+'&t3url='+escape(t3url)+'&url='+escape(url)+'&startposition='+mstartposition;                        
    window.location.href = str_mzURL;
    return true;
}
