/*****************************************************************************
* asyncronous functions
*/
var requests = new Array(); // We hold an *array* of requests and destinations.
var heights = new Array(); // placeholder heights.
function httpRequest(reqType, url, parameter, asynch, destination, placeHolderHeight)
{
if(!destination)
destination = document.getElementById("ajaxInformant").alt;
if(placeHolderHeight)
heights[destination] = placeHolderHeight;
//Mozilla-based browsers
if(window.XMLHttpRequest)
{
requests[destination] = new XMLHttpRequest();
}
else if (window.ActiveXObject)
{
requests[destination] = new ActiveXObject("Msxml2.XMLHTTP");
if (!requests[destination])
{
requests[destination] = new ActiveXObject("Microsoft.XMLHTTP");
}
}
//the request could still be null if neither ActiveXObject
//initialization succeeded
if(requests[destination])
{
initReq(reqType,url,parameter,asynch, destination);
}
else
{
alert("Your browser does not permit the use of all of this application's features!");
}
}
function initReq(reqType,url,parameter,bool, destination)
{
if (reqType == "GET")
{
parameter = null;
}
requests[destination].onreadystatechange=handleResponse;
requests[destination].open(reqType,url,bool);
if (reqType == "POST")
{
requests[destination].setRequestHeader("Content-type", "application/x-www-form-urlencoded");
requests[destination].setRequestHeader("Content-length", parameter.length);
requests[destination].setRequestHeader("Connection", "close");
}
requests[destination].send(parameter);
}
//event handler for XMLHttpRequest
function handleResponse( )
{
j = 0;
for ( destination in requests )
{
if (requests[destination].readyState < 4)
{
var heightString = '';
if(heights[destination] != 'undefined')
heightString = ' style="height: ' + heights[destination] + 'px" ';
document.getElementById(destination).innerHTML= '
';
}//if
else if (requests[destination].readyState == 4)
{
if(requests[destination].status == 200)
{
/* Grab the result as a string */
var returnedResult = requests[destination].responseText;
if (returnedResult)
{
document.getElementById(destination).style.display = 'block';
document.getElementById(destination).innerHTML = returnedResult;
}//if
else
{
if (document.getElementById(destination).type != 'select-multiple')
document.getElementById(destination).style.display = 'none';
}//else
//document.getElementById('dump').innerHTML += "
Deleting request object for " + destination + " at location " + j + "";
requests[destination] = 0;
} //if
else
{
document.getElementById(destination).innerHTML= 'A problem occurred with communicating between the XMLHttpRequest object and the server program.';
}//else
}//else if
j++;
}//for
}//handleResponse
// get gallery info
function getGalleryInfo(url, dest)
{
httpRequest("GET",url,null,true,dest);
handleResponse( );
}// end get gallery info
/***********************************************
* Flexi Slideshow- © Dynamic Drive (www.dynamicdrive.com)
* This notice must stay intact for use
* Visit http://www.dynamicdrive.com/ for full source code
***********************************************/
var variableslide=new Array()
//variableslide[x]=["path to image", "OPTIONAL link for image", "OPTIONAL text description (supports HTML tags)"]
variableslide[0]=['http://ashlandgalleries.com/uploadfiles/14/600_DSC_3131.jpg', '/contentfiles/galleries.html?Id=14&monthlyInfo=true', 'Gallerie Karon'];
variableslide[1]=['http://ashlandgalleries.com/uploadfiles/14/600_DSC_3147-1.jpg', '/contentfiles/galleries.html?Id=14&monthlyInfo=true', 'Gallerie Karon'];
variableslide[2]=['http://ashlandgalleries.com/uploadfiles/20/Breast Wishes 1.JPG', '/contentfiles/galleries.html?Id=20&monthlyInfo=true', 'JEGA Gallery & Sculpture Garden, Inc.'];
variableslide[3]=['http://ashlandgalleries.com/uploadfiles/20/Breast Wishes Lily.JPG', '/contentfiles/galleries.html?Id=20&monthlyInfo=true', 'JEGA Gallery & Sculpture Garden, Inc.'];
variableslide[4]=['http://ashlandgalleries.com/uploadfiles/53/_1010585.jpg', '/contentfiles/galleries.html?Id=53&monthlyInfo=true', '***SPECIAL*** Student Art!'];
variableslide[5]=['http://ashlandgalleries.com/uploadfiles/53/_1010573.jpg', '/contentfiles/galleries.html?Id=53&monthlyInfo=true', '***SPECIAL*** Student Art!'];
variableslide[6]=['http://ashlandgalleries.com/uploadfiles/54/Choco-Fest-2006(2).jpg', '/contentfiles/galleries.html?Id=54&monthlyInfo=true', '*** SPECIAL *** Chocolate Festival 2010'];
//configure the below 3 variables to set the dimension/background color of the slideshow
var slidebgcolor='/images/aga-banner_02.jpg'
//configure the below variable to determine the delay between image rotations (in miliseconds)
var slidedelay=3000
////Do not edit pass this line////////////////