function ge(a)
{
	return document.getElementById(a);	
}

function clearField(a)
{
	if(ge(a).innerHTML)
	{
		ge(a).innerHTML='';
	}
	if(ge(a).value)
	{
		ge(a).value='';
	}
}

function dim()
{

    $(".bodydim").fadeIn();

}
function brighten()
{

    $(".bodydim").fadeOut();
    $("#imageContainer").html('');
    $("#photo-container").remove();

}
function displayImages(a)
{
    $.post('/section-images/', {'sectionid': a}, function(data){
        if(data==0)
        {
            alert("No images Available");
        }else{
            dim();
            $("#imageContainer").html(data);
            $("#photo-container").coinslider();
            
            
        }
                       
    });
}

function displayVideos(a)
{
    $.post('/section-videos/', {'sectionid': a}, function(data){
        if(data==0)
        {
            alert("No images Available");
        }else{
            dim();
            $("#imageContainer").html(data);
            
            //$("#photo-container").coinslider();
        }

    });
}



function displayMapImages()
{
    $.post('/section-images/specific/map', function(data){
            //$("#imageContainer").html(data);
            dim();
            //$(".right").prepend(data);
            $("#imageContainer").html(data);
            $("#photo-container").coinslider();
            

        

    });
}

