//loader 1
function loadPage( productId )
{
	currentGallery = productId;
	
	// make javascript request
	var myAjax = new Ajax.Request( productId + '.html', { method: 'get', onComplete: onGalleryLoaded } );
}

function onGalleryLoaded( ajaxResponse )
{
	// load the ajax request into the right div
	$( currentGallery + "_gallery" ).innerHTML = ajaxResponse.responseText;
	// grab list of gallery images
	var imageList = $( currentGallery + '_images' ).innerHTML;
	
	// create new array of images and reset gallery index
	galleryIndexes[ currentGallery ] = 0;
	galleryData[ currentGallery ] = new Array();
	galleryData[ currentGallery ] = imageList.split( ',' );
}

function cleardiv( productId ){
	$( productId + '_gallery').innerHTML = "";
}


//Dom layer on/off

function showDiv(){
document.location = '#';
$("faqWrapper").show()
}

function hideDiv(){
$("faqWrapper").hide()
}