﻿// JScript File
function DisplayResidentExtraBanner(category)
{    
    var divContent
    var justFlowersBannerHtml 
    var starbucksStoreBannerHtml 
    var oneEightHundredContactsHtml 
	var businesstHtml
    var defaultHtml
    var sectionTitleHtmlBeginning
    var sectionTitleHtmlEnding
    var restaurantHtml
	var spaHtml

    restaurantHtml = "<div id=\"restaurantDiv\"><table cellpadding=\"5\"><tr><td valign=\"top\" align=\"left\"><a href=\"http://www.danahotelandspa.com/restaurant/index.cfm\" target=\"_blank\"><img src=\"images/logo_aja.gif\"/></a></td></tr></table></div><br>";
		nightlifeHtml = "<div id=\"restaurantDiv\"><table cellpadding=\"5\"><tr><td valign=\"top\" align=\"left\"><a href=\"http://www.danahotelandspa.com/rooftop-lounge/index.cfm\" target=\"_blank\"><img src=\"images/logo_vertigo.jpg\" style=\"width:100px;height:155px;\"  /></a></td></tr></table></div><br>";
    justFlowersBannerHtml = "<div id=\"bannerDiv\"><p><a href=\"http://www.kqzyfj.com/click-3339871-10375470\" target=\"_blank\"><img src=\"http://www.ftjcfx.com/image-3339871-10375470\" width=\"180\" height=\"150\" alt=\"Buy flowers online\" border=\"0\"/></a></p></div>";
    starbucksStoreBannerHtml = "<div id=\"bannerDiv\"><p><a href=\"http://www.jdoqocy.com/click-3339871-10393284\" target=\"_blank\"><img src=\"http://www.lduhtrp.net/image-3339871-10393284\" width=\"125\" height=\"125\" alt=\"StarbucksStore.com\" border=\"0\"/></a></p></div>";
    oneEightHundredContactsHtml = "<div id=\"bannerDiv\"><p><a href=\"http://www.anrdoezrs.net/click-3339871-10378030\" target=\"_blank\"><img src=\"http://www.tqlkg.com/image-3339871-10378030\" width=\"125\" height=\"125\" alt=\"1800CONTACTS.com - 100% Satisfaction Guarantee!\" border=\"0\"/></a></p></div>"; 
	spaHtml = "<div id=\"bannerDiv\"><p><a href=\"http://www.danahotelandspa.com/spa/index.cfm\" target=\"_blank\"/><img src=\"images/DanaLogo.gif\"></a>";
	businesstHtml = "<div id=\"bannerDiv\"><p>Jet Limousine Service<br>Airport Service to Midway/O'Hare<br>Arthur Williams<br>773-726-3725<br>Major Credit Cards Accepted</p></div>";
    defaultHtml = "<div id=\"bannerDiv\"><p>New stores are being added everyday,<br>please check back soon.<p></div>";
    
    sectionTitleHtmlBeginning = "<img id=\"residentHeading\" border=\"0\" src=\"images/";
    sectionTitleHtmlEnding = "\"><br>";
    
    switch(category)
    {
        case "spa":
            sectionTitleHtml = sectionTitleHtmlBeginning + "spa_beauty.gif" + sectionTitleHtmlEnding;
            divContent = sectionTitleHtml + spaHtml;
            break;
        case "restaurants":            
            sectionTitleHtml = sectionTitleHtmlBeginning + "restaurants.gif" + sectionTitleHtmlEnding;
            divContent = sectionTitleHtml + restaurantHtml;
            break;
         case "business":
            sectionTitleHtml = sectionTitleHtmlBeginning + "business_services.gif" + sectionTitleHtmlEnding;            
            divContent = sectionTitleHtml + businesstHtml;
            break;
        case "house":
            sectionTitleHtml = sectionTitleHtmlBeginning + "house_home.gif" + sectionTitleHtmlEnding;     
            divContent = sectionTitleHtml + defaultHtml;
            break;
        case "clothing":            
            sectionTitleHtml = sectionTitleHtmlBeginning + "clothing_accessories.gif" + sectionTitleHtmlEnding;
            divContent = sectionTitleHtml + defaultHtml;
            break;        
        case "health":            
            sectionTitleHtml = sectionTitleHtmlBeginning + "health_fitness.gif" + sectionTitleHtmlEnding;           
            divContent = sectionTitleHtml + oneEightHundredContactsHtml;
            break;
        case "baby":            
            sectionTitleHtml = sectionTitleHtmlBeginning + "baby_kids.gif" + sectionTitleHtmlEnding;
            divContent = sectionTitleHtml + defaultHtml;
            break; 
        case "specialty":            
            sectionTitleHtml = sectionTitleHtmlBeginning + "specialty.gif" + sectionTitleHtmlEnding;
            divContent = sectionTitleHtml + defaultHtml;
            break; 
        case "cafes":            
            sectionTitleHtml = sectionTitleHtmlBeginning + "cafes.gif" + sectionTitleHtmlEnding;
            divContent = sectionTitleHtml + starbucksStoreBannerHtml;
            break;
        case "gifts":            
            sectionTitleHtml = sectionTitleHtmlBeginning + "gifts.gif" + sectionTitleHtmlEnding;
            divContent = sectionTitleHtml + justFlowersBannerHtml;
            break;
        case "grocery":            
            sectionTitleHtml = sectionTitleHtmlBeginning + "grocery.gif" + sectionTitleHtmlEnding;
            divContent = sectionTitleHtml + defaultHtml;
            break;
				case "nightlife":            
            sectionTitleHtml = sectionTitleHtmlBeginning + "nightlife.gif" + sectionTitleHtmlEnding;
            divContent = sectionTitleHtml + nightlifeHtml;
            break;
        default:
            divContent = defaultHtml;
            break;
    
    
    
    }
    document.getElementById("divExtrasAdDisplay").innerHTML = divContent;
    document.getElementById("divExtrasAdDisplay").style.display = 'block';
    document.getElementById("divExtrasDisplay").style.display = 'none'; 
    document.getElementById("divExtrasLinks").style.display = 'none';     
    document.getElementById("hrefBackToExtras").style.display = 'block'; 
    document.getElementById("imageMakesDKLiving").style.display = 'none';
    document.getElementById("right").style.display = 'none';
    
}

function BackToExtras()
{
    document.getElementById("divExtrasAdDisplay").style.display = 'none';
    document.getElementById("divExtrasDisplay").style.display = 'block'; 
    document.getElementById("divExtrasLinks").style.display = 'block'; 
    document.getElementById("hrefBackToExtras").style.display = 'none'; 
    document.getElementById("imageMakesDKLiving").style.display = 'block';
    document.getElementById("right").style.display = 'block';

}