﻿$(document).ready(function() {
    $("#ctl00_ddlWebSites").change(function() {
	    if ($(this)[0].selectedIndex > 1) {
		    window.open($(this).val(), '_blank');
	    }
    });
    function RenderHtml() {
        //Cufon.replace('label'); // Works without a selector engine
        //Cufon.replace('h1'); // Works without a selector engine
        //Cufon.replace('h2'); // Works without a selector engine
        //Cufon.replace('h3'); // Works without a selector engine
        //Cufon.replace('.helv'); // Works without a selector engine
    }
    $(function() {
        RenderHtml();
        $("div.zebra section.panel2:even").addClass("odd");
    });
    function ContactUs() {
        $.colorbox({ href: "/Popup/ContactUs.aspx"});
    }
    loadKampyle();
});

function loadKampyle(){
    var kampyle = "/Services/KampyleDefaut.htm";
    var loc = window.location.href;
    if(loc.indexOf("PropertyResult.aspx") > 0){
        kampyle = "/Services/KampyleSearchResults.htm";
    }else if(loc.indexOf("PropertyDetail.aspx") > 0){
        kampyle = "/Services/KampylePropertyDetail.htm";
    }
    $.get(kampyle,function(response){
        $("body").append(response);
    });
}
