﻿// main.js - DentalProfessional.com 2010

function loadSensodyneResourceTop() {
    window.location = 'Conditions_DentinHypersensitivity_Materials.aspx';
}

function loadSensodyneResourceBottom() {
    window.location = 'Products_Sensodyne_Materials.aspx';
}

function loadPronamelResourceTop() {
    window.location = 'Conditions_AcidErosion_Materials.aspx';
}

function loadPronamelResourceBottom() {
    window.location = 'Products_Pronamel_Materials.aspx';
}

function loadPolidentResourceTop() {
    window.location = 'Conditions_DentureCare_Materials.aspx';
}

function loadPolidentResourceBottom() {
    window.location = 'Products_Polident_Materials.aspx';
}

function loadPoligripResourceTop() {
    window.location = 'Conditions_DentureCare_Materials.aspx';
}

function loadPoligripResourceBottom() {
    window.location = 'Products_Poligrip_Materials.aspx';
}

function loadAquafreshResourceTop() {
    window.location = 'Conditions_GeneralOralCare.aspx';
}

function loadAquafreshResourceBottom() {
    window.location = 'Products_Aquafresh.aspx';
}

function loadBioteneResourceTop() {
    window.location = 'Conditions_DryMouth_Materials.aspx';
}

function loadBioteneResourceBottom() {
    window.location = 'Products_Biotene_Materials.aspx';
}

function loadGlyoxideResourceTop() {
    window.location = 'Conditions_MouthGumIrritation.aspx';
}

function loadGlyoxideResourceBottom() {
    window.location = 'Products_Glyoxide.aspx';
}

function loadMainNoFlash(brand) {
    $('#liHome0 a').removeClass('current');
    $('#liHome1 a').removeClass('current');
    $('#liHome2 a').removeClass('current');
    $('#liHome3 a').removeClass('current');
    $('#liHome4 a').removeClass('current');
    $('#liHome5 a').removeClass('current');
    $('#liHome6 a').removeClass('current');

    switch (brand) {
        case 'Sensodyne':
            $('#liHome0 a').addClass('current');
            document.getElementById('divHomeNoFlash').style.backgroundImage = "url(../images/en/NoFlash/noflashSensodyneHome.gif)";
            break;
        case 'Pronamel':
            $('#liHome1 a').addClass('current');
            document.getElementById('divHomeNoFlash').style.backgroundImage = "url(../images/en/NoFlash/noflashPronamelHome.gif)";
            break;
        case 'Polident':
            $('#liHome2 a').addClass('current');
            document.getElementById('divHomeNoFlash').style.backgroundImage = "url(../images/en/NoFlash/noflashPolidentHome.gif)";
            break;
        case 'Poligrip':
            $('#liHome3 a').addClass('current');
            document.getElementById('divHomeNoFlash').style.backgroundImage = "url(../images/en/NoFlash/noflashPoligripHome.gif)";
            break;
        case 'Aquafresh':
            $('#liHome4 a').addClass('current');
            document.getElementById('divHomeNoFlash').style.backgroundImage = "url(../images/en/NoFlash/noflashAquafreshHome.gif)";
            break;
        case 'Biotene':
            $('#liHome5 a').addClass('current');
            document.getElementById('divHomeNoFlash').style.backgroundImage = "url(../images/en/NoFlash/noflashBioteneHome.gif)";
            break;
        case 'Glyoxide':
            $('#liHome6 a').addClass('current');
            document.getElementById('divHomeNoFlash').style.backgroundImage = "url(../images/en/NoFlash/noflashGlyoxideHome.gif)";
            break;
        default :
            break;
    }

    $('#aResTop').attr('href', 'javascript:load' + brand + 'ResourceTop();');
    $('#aResBottom').attr('href', 'javascript:load' + brand + 'ResourceBottom();');
}

