//--- ############### start of slide show code ###################### --//
//-- the calendar user id --//
var theUserId = 453;
//-- set the size of the layer --//
var lwidth = 220; // width of the layer
var lheight = 325; // height of the layer
//-- set the default image and text if there are no auctions --//
var defaultText = 'There are currently no auctions to display.
Please check back later!';
var defaultImage = 'images/default.gif';
var defaultAuctionLink = 'auction_list.php';
// -- this is for when there is a current auction which does not have a image --//
// display this one instead
var defaultAuctionWithNoImage = 'images/default2.gif';
var defaultAuctionNoImageWidth = 100;
var defaultAuctionNoImageHeight = 56;
//-- do not play with this content --//
var currentIndex = 0;
var imageLink = 'http://www.blueridgedigital.net';
var titleA = new Array();
var placeA = new Array();
var picA = new Array();
var dateA = new Array();
var auctionA = new Array();
var imgHeightA = new Array();
var imgWidthA = new Array();
var infoLinkA = new Array();
titleA[0] = '3850 Incredible home in the most desirable neighborhood in Rankin County - PALISADES!';
placeA[0] = 'Brandon, MS';
infoLinkA[0] = '';
picA[0] = 'http://www.blueridgedigital.net/applications/auction_calendar/files/389262/images/thumbs/186998.jpg';
//preload this image
image0 = new Image();
image0.src = 'http://www.blueridgedigital.net/applications/auction_calendar/files/389262/images/thumbs/186998.jpg';
imgHeightA[0] = image0.height;
imgWidthA[0] = image0.width;
dateA[0] = 'Thursday, September 11th, 2008';
auctionA[0] = '389262';
//-- configure positioning of the layer --//
var tWidth = parseInt(screen.width);
var xPos = 0;
var yPos = 0;
//-- get browser type --//
var ie4=document.all&&!document.getElementById;
var ns4=document.layers;
var DOM2=document.getElementById;
//-- set the timer information --//
var timerID = null;
var haveSlideShow = true;
//-- start of the functions --//
function getPrev() {
// turn off the slide
if(haveSlideShow) {
clearTimeout(timerID);
}
if ( titleA.length > 1 ) {
if(currentIndex == 0) {
currentIndex = titleA.length - 1;
} else {
currentIndex--;
}
getContent();
}
}
function nextSlide() {
// very rare case, prevents flicker when there's only one auction
if ( titleA.length > 1 ) {
if(currentIndex == (titleA.length - 1)) {
currentIndex = 0;
} else {
currentIndex++;
}
getContent();
}
}
function getNext() {
// turn off the slide
if(haveSlideShow) {
clearTimeout(timerID);
}
// prevents a constant flicker when there's only one auction
if ( titleA.length > 1 ) {
if(currentIndex == (titleA.length - 1)) {
currentIndex = 0;
} else {
currentIndex++;
}
getContent();
}
}
function getContent() {
//-- check to make sure that we have data --//
if(titleA.length == 0) {
var theImage = defaultImage;
var theTitle = defaultText;
var theDate = '';
var thePlace = '';
var theImageLink = '
';
var theAuctionDetailLink = defaultAuctionLink;
} else {
var theImage = picA[currentIndex];
var theTitle = titleA[currentIndex];
var theDate = dateA[currentIndex];
var thePlace = placeA[currentIndex];
var tImgW = imgWidthA[currentIndex];
var tImgH = imgHeightA[currentIndex];
if(tImgW >100) {
tImgWDiff = (tImgW - 120) / 120;
tImgW = 120;
tImgH = tImgH - (tImgH * tImgWDiff);
// take care of decimals
tH = new String(tImgH);
var tHeight = tH.split('.');
tImgH = tHeight[0];
}
if (tImgH >100) {
tImgHDiff = (tImgH - 90) / 90;
tImgH = 90;
tImgW = tImgW - (tImgW * tImgHDiff);
// take care of decimals
tW = new String(tImgW);
var tWidth = tW.split('.');
tImgW = tWidth[0];
}
var theImageLink = '';
var theAuctionId = auctionA[currentIndex];
var theAuctionDetailLink = 'auction_detail.php?ID='+theAuctionId;
var theExternalLink = infoLinkA[currentIndex];
}
//-- adjust this to configure the layout of the content --//
var theContent = '