/*
random images swapper for the header section.
*/

function swapHeader() {
    var cssValues = new Array()
    cssValues[0] = "headerBeach";
    cssValues[1] = "headerFlower";
    cssValues[2] = "headerSandals";
    cssValues[3] = "headerSunflower";
    cssValues[4] = "headerSpring";
    
    var p = cssValues.length;
    var whichImage = Math.round(Math.random()*(p-1));

    document.getElementById("header").className = cssValues[whichImage]; 
}


function displayExt(initpath)
{

    //debugger;
                
    document.getElementById("modone").style.backgroundImage = "url('" + initpath + "templates/YAW/images/Newswebtab1.jpg')";
    document.getElementById("modules").style.backgroundImage = "url('" + initpath + "templates/YAW/images/hp-box-footer.gif')";
    
    var tmpULList = document.getElementsByTagName("UL");
    
    for(i=0;i<tmpULList.length;i++)
    {
        var tmpIndvUL = tmpULList[i];
        
        if(tmpIndvUL.parentElement.parentElement.id == 'modone')
        {
            for(j=0;j<tmpIndvUL.childNodes.length;j++)
            {
                tmpIndvUL.childNodes[j].style.backgroundImage = "url('" + initpath + "templates/YAW/images/arrowr-new.gif')";
            }
        }
        
    }
            
}

function displayInt(initpath)
{
            
    document.getElementById("modone").style.backgroundImage = "url('" + initpath + "templates/YAW/images/Newswebtab2.jpg')";
    document.getElementById("modules").style.backgroundImage = "url('" + initpath + "templates/YAW/images/hp-box-footer-new.gif')";
            
}