/* newWindow
-----------------------------------------------------------------------------*/
function newWindow(mypage, myname, w, h, scroll){
    var winl = (screen.width-w)/2;
    var wint = (screen.height-h)/2;
    var settings = 'height='+h+',';
    settings += 'width='+w+',';
    settings += 'top='+wint+',';
    settings += 'left='+winl+',';
    settings += 'scrollbars='+scroll+',';
    settings += 'resizable=no';
    win = window.open(mypage,myname,settings);
    if (parseInt(navigator.appVersion) >= 4){win.window.focus();}
}
/* changeToMail
-----------------------------------------------------------------------------*/
var mails = new Array();
mails[0] = "con"+"ta"+"ct"+"@e"+"ley"+"ane"+"t.c"+"om";
mails[1] = "";

function changeToMail(id,i,title){
    if (!title) title = "Envoyez-nous un e-mail";
    if (document.getElementById(id)) {
        document.getElementById(id).innerHTML = "<a href='" + "mai" + "lto:" + mails[i] + "' title='" + title + "'>" + mails[i] + "</a>";
    }
}
/* highlightTable
-----------------------------------------------------------------------------*/
function highlightTable(e, highlight, selectable){
    $(e + ' tbody tr:nth-child(2n)').addClass('odd');
    if (highlight){
        $(e + ' tbody tr').hover(
            function(){$(this).addClass('over');},
            function(){$(this).removeClass('over');}
        );
    }
    if (selectable){
        $(e + ' tbody tr').click(function(){
            $(e + ' tr').removeClass('sel');
            $(this).addClass('sel');
        });
    }
}