$(function() {
    	// set the visibility before calling the carousel code (to make sure the correct elements are enabled)
	setjsvisibility();

	// ensure that an image is showing by default - check for "noimg" text in image src
	var imageSource = document.getElementById('imagetag');
	if (imageSource.src.search('noimg')!=-1)
	{
		scrollImage('next');		
	}
});

// get the image to align the buttons to, then call off to the "moveNavButtons" function
function alignNavButtons() {
	var imageSource = document.getElementById('imagetag');
	moveNavButtons(imageSource);
}

