
// Test for browser 
function getElement(id){
    if(document.getElementById){
        getElement = function(id){ return document.getElementById(id); }
    }else if(document.all){
        getElement = function(id){ return document.all[id]; };
    }else if(document.layers){
        getElement = function(id){ return document.layers[id]; };
    }else{
        getElement = function() { return null; }
    }

    return getElement(id);
}


function galleryLoaded(selGallery, selAlbum) {
    
    var strCurrLoc = window.location.toString();
    var temp = new Array();
    temp = strCurrLoc.split('gallery');
    
    if(selAlbum) {
        
            var strUrl = temp[0].toString();
            var strLoc = strUrl+"gallery/"+selGallery+".aspx";
                
            tmp= window.location.href;
            window.location.href = strLoc;
       
    } 
    

}
function loadGallery(val) {
    alert(val);
    var tmp=thisMovie("slideshowflash").loadGallery(val);
}

function thisMovie(movieName) {
    if (navigator.appName.indexOf("Microsoft") != -1) {
      
        var path = document;
        path = path.forms[0];
        window[movieName]=path[movieName];
        return window[movieName]
    }
    else {
        return document[movieName]
    }
}
