
/* General */

function OpenWindow(strURL,
                    strName,
                    varParams) {
    window.open(strURL,strName,varParams);
}

function SubmitForm(strFormName) {
    document.getElementById(strFormName).submit()
}

function WriteFlashMX(strID,
                      strMovie,
                      intWidth,
                      intHeight) {
    var strFlash='';
    strFlash+='<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,0,0" width="'+intWidth+'" height="'+intHeight+'" id="'+strID+'">';
    strFlash+='<param name="movie" value="'+strMovie+'" />';
    strFlash+='<param name="menu" value="false" />';
    strFlash+='<param name="quality" value="high" />';
    strFlash+='<param name="bgcolor" value="#FFFFFF" />';
    strFlash+='<param name="wmode" value="transparent" />';
    strFlash+='<embed src="'+strMovie+'" quality="high" menu="false" wmode="transparent" bgcolor="#FFFFFF" width="'+intWidth+'" height="'+intHeight+'" name="'+strID+'" type="application/x-shockwave-flash" PLUGINSPAGE="http://www.macromedia.com/go/getflashplayer"></embed>';
    strFlash+='</object>';
    document.write(strFlash);
}

function LeasingPopupClose() { 
    document.getElementById('LeasingPopup').style.visibility='hidden'
}

function ShowTab(strTabId) {
    var strOptionsDsiplay='none';
    var strEquipmentDsiplay='none';
    var strOptionsTabBG='url(/images/leasing_options_tab.gif)';
    var strEquipmentTabBG='url(/images/leasing_options_tab.gif)';
    var objOptions=document.getElementById(CAPTab.OptionsId);
    var objOptionsTab=document.getElementById(CAPTab.OptionsTabId);
    var objEquipment=document.getElementById(CAPTab.EquipmentId);
    var objEquipmentTab=document.getElementById(CAPTab.EquipmentTabId);
    if (strTabId==CAPTab.OptionsId) { 
        strOptionsDsiplay='block';
        strOptionsTabBG='url(/images/leasing_options_tab_active.gif)';
    }
    else if (strTabId==CAPTab.EquipmentId) { 
        strEquipmentDsiplay='block';
        strEquipmentTabBG='url(/images/leasing_options_tab_active.gif)';
    }
    objOptions.style.display=strOptionsDsiplay;
    objOptionsTab.style.backgroundImage=strOptionsTabBG;
    objEquipment.style.display=strEquipmentDsiplay;
    objEquipmentTab.style.backgroundImage=strEquipmentTabBG;
}

function ShowOptionsTab() {
    ShowTab(CAPTab.OptionsId)
}

function ShowEquipmentTab() {
    ShowTab(CAPTab.EquipmentId)
}

function Tab() {
    this.OptionsId='Options';
    this.EquipmentId='Equipment';
    this.OptionsTabId='OptionsTab';
    this.EquipmentTabId='EquipmentTab';
    this.ShowOptions=ShowOptionsTab;
    this.ShowEquipment=ShowEquipmentTab
}
var CAPTab = new Tab();

/* End */

