﻿// SITE NAVIVATION URLS

function showtab(num,linkout) {
    //if (linkout==1) {        
        //if (num==1) {window.location.href='default.asp';} // our story
        //if (num==2) {window.location.href='furniture.asp';} // furniture
        //if (num==3) {window.location.href='cabinets.asp';} // cabinets
        //if (num==4) {window.location.href='ArtAndCollectibles.asp';} // arts & Collectibles
        //if (num==5) {window.location.href='Statistics.asp';} // stats
        //if (num==6) {window.location.href='Pricing.asp';} // pricing
        //if (num==7) {window.location.href='WorkshopForm.asp';} // workshops
        //if (num==8) {window.location.href='AssignAClaim.asp';} // assign a claim
        //if (num==9) {window.location.href='Clients.asp';} // client list
        //if (num==10) {window.location.href='UnderConstruction.asp';} // contact us
        //if (num==11) {window.location.href='ContactUs.asp';} // contact us
    //}

    for (i = 1; i <= 8; i++) {
        
        if (i==num) {
            $('#navimg' + i).attr('src', 'images/navigation/nav' + i + '-over.jpg');

        } else {
            $('#navimg' + i).attr('src', 'images/navigation/nav' + i + '.jpg');
        }
    }
}

function SwitchOff (ANAME) {document.getElementById(ANAME).style.display='none';}

function SwitchOn (BNAME) {document.getElementById(BNAME).style.display='inline';}

function SwitchOffParent (ANAME) {parent.document.getElementById(ANAME).style.display='none';}

function SwitchOnParent (BNAME) {parent.document.getElementById(BNAME).style.display='inline';}

function ShowHide (CNAME) {
    var x = document.getElementById(CNAME);
    
    if (x) {
        if (x.style.display=='none') {
            x.style.display = 'inline';
        } else {
            x.style.display = 'none';
        }
    }
}

function setFrameParent(frme,url) {
//alert('Setting Parent frame');
if (navigator.userAgent.indexOf("Firefox")>0) {
        parent.document.getElementById(frme).src=url;
        //alert('for FF');
    } else {
        parent.document[frme].location.href=url;
        //alert('for IE');
    }
}

function setFrame(frme,url) {
//alert(url);
if (navigator.userAgent.indexOf("Firefox")>0) {
        document.getElementById(frme).src=url;
        //alert('for FF');
    } else {
        document[frme].location.href=url;
        //alert('for IE');
    }
}

function displayMessage(div,text) {
    var _x = document.getElementById(div);
    
    if (_x) {
        document.getElementById(div).innerHTML=text;
    }
}
