
// 'stacks' is the Stacks global object.
// All of the other Stacks related Javascript will 
// be attatched to it.
var stacks = {};


// this call to jQuery gives us access to the globaal
// jQuery object. 
// 'noConflict' removes the '$' variable.
// 'true' removes the 'jQuery' variable.
// removing these globals reduces conflicts with other 
// jQuery versions that might be running on this page.
stacks.jQuery = jQuery.noConflict(true);

// Javascript for stacks_in_1_page7
// ---------------------------------------------------------------------

// Each stack has its own object with its own namespace.  The name of
// that object is the same as the stack's id.
stacks.stacks_in_1_page7 = {};

// A closure is defined and assigned to the stack's object.  The object
// is also passed in as 'stack' which gives you a shorthand for referring
// to this object from elsewhere.
stacks.stacks_in_1_page7 = (function(stack) {

	// When jQuery is used it will be available as $ and jQuery but only
	// inside the closure.
	var jQuery = stacks.jQuery;
	var $ = jQuery;
	
jQuery(document).ready(function(){
	jQuery('body').prepend(jQuery('#pageFlipStackstacks_in_1_page7'));
	var theMSGImageURL=jQuery('.msg_block img').attr('src');
	var theMSGImageHeight=jQuery('.msg_block img').attr('height');
	var theMSGImageWidth=jQuery('.msg_block img').attr('width');
	jQuery('.msg_block').empty().css('backgroundImage', 'url('+theMSGImageURL+')');
	var thePos='right';
	if (thePos=='right') {
		jQuery('#pageFlipStackstacks_in_1_page7 img.flipImage').attr('src','files/pageFlip_right.png');
		jQuery('#pageFlipStackstacks_in_1_page7 img.flipImage , .msg_block').css({
			right: 0
		});
		jQuery('.msg_block').css('backgroundPosition', 'top right');
	}
	else {
		jQuery('#pageFlipStackstacks_in_1_page7 img.flipImage').attr('src','files/pageFlip_left.png');
		jQuery('#pageFlipStackstacks_in_1_page7 img.flipImage , .msg_block').css({
			left: 0
		});
		jQuery('.msg_block').css('backgroundPosition', 'top left');
	}
	jQuery("#pageFlipStackstacks_in_1_page7").hover(function() {
	 //On hover...
	jQuery("#pageFlipStackstacks_in_1_page7 img.flipImage").stop()
		.animate({ //Animate and expand the image and the msg_block (Width + height)
			width: theMSGImageWidth,
			height: theMSGImageHeight
		}, 500);
	jQuery(".msg_block").stop()
		.animate({ //Animate and expand the image and the msg_block (Width + height)
			width: theMSGImageWidth,
			height: theMSGImageHeight*0.96
		}, 500);
	} , function() {
	jQuery("#pageFlipStackstacks_in_1_page7 img.flipImage").stop() //On hover out, go back to original size 50x52
		.animate({
			width: '50px',
			height: '52px'
		}, 220);
	jQuery(".msg_block").stop() //On hover out, go back to original size 50x50
		.animate({
			width: '50px',
			height: '50px'
		}, 200); //Note this one retracts a bit faster (to prevent glitching in IE)
});

});
	return stack;
})(stacks.stacks_in_1_page7);


// Javascript for stacks_in_7_page7
// ---------------------------------------------------------------------

// Each stack has its own object with its own namespace.  The name of
// that object is the same as the stack's id.
stacks.stacks_in_7_page7 = {};

// A closure is defined and assigned to the stack's object.  The object
// is also passed in as 'stack' which gives you a shorthand for referring
// to this object from elsewhere.
stacks.stacks_in_7_page7 = (function(stack) {

	// When jQuery is used it will be available as $ and jQuery but only
	// inside the closure.
	var jQuery = stacks.jQuery;
	var $ = jQuery;
	
// Doo Daily Stack by http://www.doobox.co.uk
// Copyright@2010 Mr JG Simpson, trading as Doobox.
// all rights reserved.
$(document).ready(function() {

var dayname = ['Sunday', 'Monday', 'Tuesday', 'Wednesday', 'Thursday','Friday', 'Saturday'];
	var now = new Date;
    var dow = now.getDay();
    var dooDay = dayname[dow];
    
if (dooDay == 'Saturday'){
$("#stacks_in_7_page7 .dooSat").css('display', 'block');
} 
else if (dooDay == 'Sunday'){
$("#stacks_in_7_page7 .dooSun").css('display', 'block');
} 
else if (dooDay == 'Monday'){
$("#stacks_in_7_page7 .dooMon").css('display', 'block');
} 
else if (dooDay == 'Tuesday'){
$("#stacks_in_7_page7 .dooTue").css('display', 'block'); 
}
else if (dooDay == 'Wednesday'){
$("#stacks_in_7_page7 .dooWed").css('display', 'block');
} 
else if (dooDay == 'Thursday'){
$("#stacks_in_7_page7 .dooThu").css('display', 'block'); 
}
else {
$("#stacks_in_7_page7 .dooFri").css('display', 'block');
}
          
});

// End Doo Daily Stack by http://www.doobox.co.uk



	return stack;
})(stacks.stacks_in_7_page7);


// Javascript for stacks_in_192_page7
// ---------------------------------------------------------------------

// Each stack has its own object with its own namespace.  The name of
// that object is the same as the stack's id.
stacks.stacks_in_192_page7 = {};

// A closure is defined and assigned to the stack's object.  The object
// is also passed in as 'stack' which gives you a shorthand for referring
// to this object from elsewhere.
stacks.stacks_in_192_page7 = (function(stack) {

	// When jQuery is used it will be available as $ and jQuery but only
	// inside the closure.
	var jQuery = stacks.jQuery;
	var $ = jQuery;
	

//-- Popup Caption Stack v2.2.0 by Joe Workman --//
$(document).ready(function() {
	var box_height = $('#stacks_in_192_page7 .boxgrid img').height();
	var box_width = $('#stacks_in_192_page7 .boxgrid img').width();
	$('#stacks_in_192_page7 .boxgrid').height(box_height);
	$('#stacks_in_192_page7 .boxgrid').width(box_width);
	
	var caption_height = box_height * (31/100);
	var caption_reveal = box_height * (0/100);
	var init_caption = box_height - caption_reveal;
	$('#stacks_in_192_page7 .boxcaption').height(box_height);
	$('#stacks_in_192_page7 .caption_back').height(box_height);
	$('#stacks_in_192_page7 .captionfull .boxcaption').css({top: box_height});
	$('#stacks_in_192_page7 .caption .boxcaption').css({top: init_caption});
	$('#stacks_in_192_page7 .captionfulltop .boxcaption').css({bottom: box_height});
	$('#stacks_in_192_page7 .captiontop .boxcaption').css({bottom: init_caption});
	
	var speed = speed;
	//Caption Sliding (Partially Hidden to Visible)
	$('#stacks_in_192_page7 .boxgrid.caption').hover(function(){
		$(".cover", this).stop().animate({top:(box_height - caption_height)},{queue:false,duration:speed});
	}, function() {
		$(".cover", this).stop().animate({top: init_caption},{queue:false,duration:speed});
	});
	//Caption Sliding Down (Hidden to Visible)
	$('#stacks_in_192_page7 .boxgrid.captiontop').hover(function(){
		$(".cover", this).stop().animate({bottom:(box_height - caption_height)},{queue:false,duration:speed});
	}, function() {
		$(".cover", this).stop().animate({bottom:init_caption},{queue:false,duration:speed});
	});
	
});
//-- End Popup Caption Stack --//

	return stack;
})(stacks.stacks_in_192_page7);


// Javascript for stacks_in_199_page7
// ---------------------------------------------------------------------

// Each stack has its own object with its own namespace.  The name of
// that object is the same as the stack's id.
stacks.stacks_in_199_page7 = {};

// A closure is defined and assigned to the stack's object.  The object
// is also passed in as 'stack' which gives you a shorthand for referring
// to this object from elsewhere.
stacks.stacks_in_199_page7 = (function(stack) {

	// When jQuery is used it will be available as $ and jQuery but only
	// inside the closure.
	var jQuery = stacks.jQuery;
	var $ = jQuery;
	

//-- Popup Caption Stack v2.2.0 by Joe Workman --//
$(document).ready(function() {
	var box_height = $('#stacks_in_199_page7 .boxgrid img').height();
	var box_width = $('#stacks_in_199_page7 .boxgrid img').width();
	$('#stacks_in_199_page7 .boxgrid').height(box_height);
	$('#stacks_in_199_page7 .boxgrid').width(box_width);
	
	var caption_height = box_height * (36/100);
	var caption_reveal = box_height * (0/100);
	var init_caption = box_height - caption_reveal;
	$('#stacks_in_199_page7 .boxcaption').height(box_height);
	$('#stacks_in_199_page7 .caption_back').height(box_height);
	$('#stacks_in_199_page7 .captionfull .boxcaption').css({top: box_height});
	$('#stacks_in_199_page7 .caption .boxcaption').css({top: init_caption});
	$('#stacks_in_199_page7 .captionfulltop .boxcaption').css({bottom: box_height});
	$('#stacks_in_199_page7 .captiontop .boxcaption').css({bottom: init_caption});
	
	var speed = speed;
	//Caption Sliding (Partially Hidden to Visible)
	$('#stacks_in_199_page7 .boxgrid.caption').hover(function(){
		$(".cover", this).stop().animate({top:(box_height - caption_height)},{queue:false,duration:speed});
	}, function() {
		$(".cover", this).stop().animate({top: init_caption},{queue:false,duration:speed});
	});
	//Caption Sliding Down (Hidden to Visible)
	$('#stacks_in_199_page7 .boxgrid.captiontop').hover(function(){
		$(".cover", this).stop().animate({bottom:(box_height - caption_height)},{queue:false,duration:speed});
	}, function() {
		$(".cover", this).stop().animate({bottom:init_caption},{queue:false,duration:speed});
	});
	
});
//-- End Popup Caption Stack --//

	return stack;
})(stacks.stacks_in_199_page7);


// Javascript for stacks_in_205_page7
// ---------------------------------------------------------------------

// Each stack has its own object with its own namespace.  The name of
// that object is the same as the stack's id.
stacks.stacks_in_205_page7 = {};

// A closure is defined and assigned to the stack's object.  The object
// is also passed in as 'stack' which gives you a shorthand for referring
// to this object from elsewhere.
stacks.stacks_in_205_page7 = (function(stack) {

	// When jQuery is used it will be available as $ and jQuery but only
	// inside the closure.
	var jQuery = stacks.jQuery;
	var $ = jQuery;
	

//-- Popup Caption Stack v2.2.0 by Joe Workman --//
$(document).ready(function() {
	var box_height = $('#stacks_in_205_page7 .boxgrid img').height();
	var box_width = $('#stacks_in_205_page7 .boxgrid img').width();
	$('#stacks_in_205_page7 .boxgrid').height(box_height);
	$('#stacks_in_205_page7 .boxgrid').width(box_width);
	
	var caption_height = box_height * (36/100);
	var caption_reveal = box_height * (0/100);
	var init_caption = box_height - caption_reveal;
	$('#stacks_in_205_page7 .boxcaption').height(box_height);
	$('#stacks_in_205_page7 .caption_back').height(box_height);
	$('#stacks_in_205_page7 .captionfull .boxcaption').css({top: box_height});
	$('#stacks_in_205_page7 .caption .boxcaption').css({top: init_caption});
	$('#stacks_in_205_page7 .captionfulltop .boxcaption').css({bottom: box_height});
	$('#stacks_in_205_page7 .captiontop .boxcaption').css({bottom: init_caption});
	
	var speed = speed;
	//Caption Sliding (Partially Hidden to Visible)
	$('#stacks_in_205_page7 .boxgrid.caption').hover(function(){
		$(".cover", this).stop().animate({top:(box_height - caption_height)},{queue:false,duration:speed});
	}, function() {
		$(".cover", this).stop().animate({top: init_caption},{queue:false,duration:speed});
	});
	//Caption Sliding Down (Hidden to Visible)
	$('#stacks_in_205_page7 .boxgrid.captiontop').hover(function(){
		$(".cover", this).stop().animate({bottom:(box_height - caption_height)},{queue:false,duration:speed});
	}, function() {
		$(".cover", this).stop().animate({bottom:init_caption},{queue:false,duration:speed});
	});
	
});
//-- End Popup Caption Stack --//

	return stack;
})(stacks.stacks_in_205_page7);


// Javascript for stacks_in_202_page7
// ---------------------------------------------------------------------

// Each stack has its own object with its own namespace.  The name of
// that object is the same as the stack's id.
stacks.stacks_in_202_page7 = {};

// A closure is defined and assigned to the stack's object.  The object
// is also passed in as 'stack' which gives you a shorthand for referring
// to this object from elsewhere.
stacks.stacks_in_202_page7 = (function(stack) {

	// When jQuery is used it will be available as $ and jQuery but only
	// inside the closure.
	var jQuery = stacks.jQuery;
	var $ = jQuery;
	

//-- Popup Caption Stack v2.2.0 by Joe Workman --//
$(document).ready(function() {
	var box_height = $('#stacks_in_202_page7 .boxgrid img').height();
	var box_width = $('#stacks_in_202_page7 .boxgrid img').width();
	$('#stacks_in_202_page7 .boxgrid').height(box_height);
	$('#stacks_in_202_page7 .boxgrid').width(box_width);
	
	var caption_height = box_height * (36/100);
	var caption_reveal = box_height * (0/100);
	var init_caption = box_height - caption_reveal;
	$('#stacks_in_202_page7 .boxcaption').height(box_height);
	$('#stacks_in_202_page7 .caption_back').height(box_height);
	$('#stacks_in_202_page7 .captionfull .boxcaption').css({top: box_height});
	$('#stacks_in_202_page7 .caption .boxcaption').css({top: init_caption});
	$('#stacks_in_202_page7 .captionfulltop .boxcaption').css({bottom: box_height});
	$('#stacks_in_202_page7 .captiontop .boxcaption').css({bottom: init_caption});
	
	var speed = speed;
	//Caption Sliding (Partially Hidden to Visible)
	$('#stacks_in_202_page7 .boxgrid.caption').hover(function(){
		$(".cover", this).stop().animate({top:(box_height - caption_height)},{queue:false,duration:speed});
	}, function() {
		$(".cover", this).stop().animate({top: init_caption},{queue:false,duration:speed});
	});
	//Caption Sliding Down (Hidden to Visible)
	$('#stacks_in_202_page7 .boxgrid.captiontop').hover(function(){
		$(".cover", this).stop().animate({bottom:(box_height - caption_height)},{queue:false,duration:speed});
	}, function() {
		$(".cover", this).stop().animate({bottom:init_caption},{queue:false,duration:speed});
	});
	
});
//-- End Popup Caption Stack --//

	return stack;
})(stacks.stacks_in_202_page7);


// Javascript for stacks_in_49_page7
// ---------------------------------------------------------------------

// Each stack has its own object with its own namespace.  The name of
// that object is the same as the stack's id.
stacks.stacks_in_49_page7 = {};

// A closure is defined and assigned to the stack's object.  The object
// is also passed in as 'stack' which gives you a shorthand for referring
// to this object from elsewhere.
stacks.stacks_in_49_page7 = (function(stack) {

	// When jQuery is used it will be available as $ and jQuery but only
	// inside the closure.
	var jQuery = stacks.jQuery;
	var $ = jQuery;
	
/**
 * SymfoniP SimpleBox /sympleBox /symBox Core Helper Scripts for RapidWeaver Stacks
 * SimpleBox /sympleBox is copyright (c) 2010 by Ronan Cashell and Kevin Burns - SymfoniP.com
 * Version 1.1
 * Also with with integrated Cookie jQuery plugin Copyright (c) 2006 Klaus Hartl (stilbuero.de)
 * jQuery Cookie Plugin Dual licensed under the MIT and GPL licenses:
 */
jQuery.cookie=function(name,value,options){if(typeof value!="undefined"){options=options||{};if(value===null){value="";options.expires=-1}var expires="";if(options.expires&&(typeof options.expires=="number"||options.expires.toUTCString)){var date;if(typeof options.expires=="number"){date=new Date();date.setTime(date.getTime()+(options.expires*24*60*60*1000))}else{date=options.expires}expires="; expires="+date.toUTCString()}var path=options.path?"; path="+(options.path):"";var domain=options.domain?"; domain="+(options.domain):"";var secure=options.secure?"; secure":"";document.cookie=[name,"=",encodeURIComponent(value),expires,path,domain,secure].join("")}else{var cookieValue=null;if(document.cookie&&document.cookie!=""){var cookies=document.cookie.split(";");for(var i=0;i<cookies.length;i++){var cookie=jQuery.trim(cookies[i]);if(cookie.substring(0,name.length+1)==(name+"=")){cookieValue=decodeURIComponent(cookie.substring(name.length+1));break}}}return cookieValue}};(function($){$.fn.extend({sympleBox:function(options){var defaults={width:"",height:"",auto:null,opacity:0.8,cookie:null};var currentPop;var autoPop=false;if(typeof options=="object"){$.extend(defaults,options)}$("a.close, #symboxfade").live("click",function(){$("#symboxfade , .popup_block").fadeOut(function(){$("#symboxfade, a.close, #symClone").remove()});return false});$(document).keydown(function(e){if(e.which==27){$("a.close").click()}});return this.each(function(){var defaultOpts=new Object();$.extend(defaultOpts,defaults);var popID=$(this).attr("rel");var popHref=$(this).attr("href");var query="";if(popHref.length>2&&popHref.substr(1,1)=="?"){query=popHref.split("?")}var $this=$(this);$("#"+popID).addClass("sympleBoxPopup");if(query.length>1){var popOpts=query[1].split("&");for(key in popOpts){var opt=popOpts[key].split("=");switch(opt[0]){case"w":defaultOpts.width=opt[1];break;case"h":defaultOpts.height=opt[1];break;case"a":if($.cookie("symBoxPop")!="1"){if(!isNaN(opt[1])){defaultOpts.auto=Number(opt[1])}}break;case"c":if(!isNaN(opt[1])){defaultOpts.cookie=Number(opt[1]);if(defaultOpts.cookie<0){$.cookie("symBoxPop",null,{path:"/"})}}else{defaultOpts.cookie=1}break;case"o":if(!isNaN(opt[1])){defaultOpts.opacity=Number(opt[1])}}}}var popMargTop;var popMargLeft;var refObj=$("#"+$(this).attr("rel"));$("img",refObj).each(function(){$(this).load(function(){if(isNaN(defaultOpts.width)&&isNaN(defaultOpts.height)){if(defaultOpts.width==""||isNaN(defaultOpts.width)){defaultOpts.width=$(this).attr("width")}if(defaultOpts.height==""||isNaN(defaultOpts.height)){defaultOpts.height=refObj.height()}if(typeof defaultOpts.height=="undefined"||defaultOpts.height==""){popMargTop=(refObj.height()+80)/2}else{popMargTop=(parseInt(defaultOpts.height)+80)/2}if(typeof defaultOpts.width=="undefined"||defaultOpts.width==""){popMargLeft=(refObj.width()+80)/2}else{popMargLeft=(parseInt(defaultOpts.width)+80)/2}$(this).click(function(){var clone=$("#"+popID).clone(true);clone.attr("id","symClone");$("body").append(clone);if(typeof defaultOpts.height!="undefined"&&defaultOpts.height!=""){clone.css("height",defaultOpts.height)}clone.fadeIn().css({width:defaultOpts.width,"margin-top":-popMargTop,"margin-left":-popMargLeft}).prepend('<a href="#" class="close"><img src="files/symboximg/close_pop-2.png" class="btn_close" title="Close Window" alt="Close Window" /></a>');$("body").append('<div id="symboxfade"></div>');$("#symboxfade").css({filter:"alpha(opacity="+(defaultOpts.opacity*100)+")",opacity:defaultOpts.opacity}).fadeIn();return false})}})});if(defaultOpts.width==""||isNaN(defaultOpts.width)){if($.browser.msie&&parseInt($.browser.version)<=7){$("img, iframe, object, embed, video",refObj).each(function(){if($(this)[0].nodeName=="IMG"){var htmlText=$(this).parent().html();htmlText=htmlText.toLowerCase();var widthLoc=htmlText.indexOf("width");if(widthLoc<0){defaultOpts.width=""}else{defaultOpts.width=parseInt(htmlText.substr(widthLoc+6))}}else{defaultOpts.width=$(this).attr("width")}})}else{defaultOpts.width=refObj.width()}}if(defaultOpts.height==""||isNaN(defaultOpts.height)){if($.browser.msie&&parseInt($.browser.version)<=7){$("img, iframe, object, embed, video",refObj).each(function(){if($(this)[0].nodeName=="IMG"){var htmlText=$(this).parent().html();htmlText=htmlText.toLowerCase();var heightLoc=htmlText.indexOf("height");if(heightLoc<0){defaultOpts.height=""}else{defaultOpts.height=parseInt(htmlText.substr(heightLoc+7))}}else{defaultOpts.height=$(this).attr("height")}})}else{defaultOpts.height=refObj.height()}}if(typeof defaultOpts.height=="undefined"||defaultOpts.height==""){popMargTop=(refObj.height()+80)/2}else{popMargTop=(parseInt(defaultOpts.height)+80)/2}if(typeof defaultOpts.width=="undefined"||defaultOpts.width==""){popMargLeft=(refObj.width()+80)/2}else{popMargLeft=(parseInt(defaultOpts.width)+80)/2}$(this).click(function(){var clone=$("#"+popID).clone(true);clone.attr("id","symClone");$("body").append(clone);if(typeof defaultOpts.height!="undefined"&&defaultOpts.height!=""){clone.css("height",defaultOpts.height+"px")}clone.fadeIn();if(defaultOpts.width==""){defaultOpts.width=$("#"+popID).width()}clone.css({width:defaultOpts.width+"px","margin-top":-popMargTop+"px","margin-left":-popMargLeft+"px"});clone.prepend('<a href="#" class="close"><img src="files/symboximg/close_pop-2.png" class="btn_close" title="Close Window" alt="Close Window" /></a>');$("body").append('<div id="symboxfade"></div>');$("#symboxfade").css({filter:"alpha(opacity="+(defaultOpts.opacity*100)+")",opacity:defaultOpts.opacity}).fadeIn();return false});if(!autoPop&&typeof defaultOpts.auto!="undefined"&&defaultOpts.auto!=null){setTimeout(function(){$this.click()},parseInt(defaultOpts.auto)*1000);autoPop=true;if(!isNaN(defaultOpts.cookie)&&defaultOpts.cookie>0){$.cookie("symBoxPop","1",{expires:defaultOpts.cookie,path:"/"})}}})}})})(jQuery);$(document).ready(function(){$("a[rel^=symbox]").sympleBox({opacity:0.88})});
	return stack;
})(stacks.stacks_in_49_page7);



