
// '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_page18
// ---------------------------------------------------------------------

// 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_page18 = {};

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

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

//-- InfoBar Stack v1.0.4 by Joe Workman --//
/*
 * Activebar2 is free software
 * The latest version of ActiveBar can be obtained from: http://www.westhoffswelt.de/
 * @license http://www.gnu.org/licenses/gpl-3.0.txt GPL
 */
eval(function(p,a,c,k,e,r){e=function(c){return(c<a?'':e(parseInt(c/a)))+((c=c%a)>35?String.fromCharCode(c+29):c.toString(36))};if(!''.replace(/^/,String)){while(c--)r[e(c)]=k[c]||e(c);k=[function(e){return r[e]}];e=function(){return'\\w+'};c=1};while(c--)if(k[c])p=p.replace(new RegExp('\\b'+e(c)+'\\b','g'),k[c]);return p}('(d($){$.7.4=d(a){p a=$.7.1b({},$.7.4.G,a);i($.7.4.8==q){$.7.4.8=H(a)}I($.7.4.8,a);$.7.4.y();$(\'.r\',$.7.4.8).1c();$(m).1d(d(){$(\'.r\',$.7.4.8).s(m)});$.7.4.8.J(\'z\');i(a.n!=q){$.7.4.8.z(d(){j.1e.1f=a.n})}$.7.4.8.9(\'e\',\'-\'+$.7.4.8.k()+\'o\');$.7.4.K()};$.7.4.G={\'l\':\'1g\',\'L\':\'#1h\',\'M\':\'1i\',\'N\':\'1j 1k 1l,1m,1n-1o\',\'O\':\'1p\',\'A\':\'1q\',\'t\':\'P/4-1r.Q\',\'R\':\'P/4-1s.Q\',\'n\':q};$.7.4.g=0;$.7.4.8=q;$.7.4.K=d(){i($.7.4.g>1){B}$.7.4.g=2;$.7.4.8.9(\'C\',\'1t\');p a=$.7.4.8.k();$.7.4.8.S({\'e\':\'+=\'+a+\'o\'},a*T,\'U\',d(){$.7.4.g=3})};$.7.4.y=d(){i($.7.4.g<2){B}$.7.4.g=1;p a=$.7.4.8.k();$.7.4.8.S({\'e\':\'-=\'+a+\'o\'},a*T,\'U\',d(){$.7.4.8.9(\'C\',\'V\');$.7.4.1u=1v})};d H(b){p c=$(\'<f></f>\').u(\'1w\',\'4-8\');c.9({\'C\':\'V\',\'W\':\'1x\',\'1y\':\'1z\',\'e\':\'X\',\'v\':\'X\',\'1A\':\'1B\'});$(j).1C(\'Y\',d(){c.w($(m).w())});$(j).1D(\'Y\');i($.D.1E&&($.D.Z.10(0,1)==\'5\'||$.D.Z.10(0,1)==\'6\')){c.9(\'W\',\'1F\');$(j).1G(d(){c.1H(11,11);i($.7.4.g==3){c.9(\'e\',$(j).12()+\'o\')}1I{c.9(\'e\',($(j).12()-c.k())+\'o\')}})}c.s($(\'<f></f>\').u(\'E\',\'t\').9({\'13\':\'v\',\'w\':\'x\',\'k\':\'x\',\'F\':\'14 h h h\'}));c.s($(\'<f></f>\').u(\'E\',\'15\').9({\'13\':\'1J\',\'F\':\'14 h h h\',\'w\':\'x\',\'k\':\'x\'}).z(d(a){$.7.4.y();a.1K()}));c.s($(\'<f></f>\').u(\'E\',\'r\').9({\'F\':\'1L 16 h 16\'}));$(\'1M\').1N(c);B c};d I(a,b){a.9({\'l\':b.l,\'1O\':\'1P 1Q \'+b.L});a.J(\'1R 1S\');a.1T(d(){$(m).9(\'17\',b.M)},d(){$(m).9(\'17\',b.l)});$(\'.t\',a).9(\'l\',\'18 n( \\\'\'+b.t+\'\\\' ) e v 19-1a\');$(\'.15\',a).9(\'l\',\'18 n( \\\'\'+b.R+\'\\\' ) e v 19-1a\');$(\'.r\',a).9({\'1U\':b.O,\'1V\':b.N,\'A\':b.A})}})(1W);',62,121,'||||activebar|||fn|container|css||||function|top|div|state|4px|if|window|height|background|this|url|px|var|null|content|append|icon|attr|left|width|16px|hide|click|fontSize|return|display|browser|class|margin|defaults|initializeActivebar|setOptionsOnContainer|unbind|show|border|highlight|font|fontColor|images|png|button|animate|20|linear|none|position|0px|resize|version|substring|true|scrollTop|float|6px|close|28px|backgroundColor|transparent|no|repeat|extend|empty|each|location|href|InfoBackground|c8c8c8|Highlight|Bitstream|Vera|Sans|verdana|sans|serif|InfoText|12px|information|closebtn|block|visible|false|id|fixed|zIndex|9999|cursor|pointer|bind|trigger|msie|absolute|scroll|stop|else|right|stopPropagation|8px|body|prepend|borderBottom|1px|solid|mouseenter|mouseleave|hover|color|fontFamily|jQuery'.split('|'),0,{}))

$(document).ready(function() {
    $('#infobar-stacks_in_1_page18').activebar({  button:'index_files/infobar-close.png',
                                    icon:'index_files/infobar-close.png',
                                    url:null,
                                    background:'#CC0000',
                                    highlight:'#E50000',
                                    font:'sans-serif, verdana',
                                    fontColor:'#FFFFFF',
                                    fontSize:'10pt'
    });
    if ('http://american.redcross.org/site/PageServer?pagename=ntld_main&s_src=RSG000000000&s_subsrc=RCO_FrontPagePanel' != '#') {
        $('#activebar-container').live('click',function(e) {
            (true == true) ? window.open('http://american.redcross.org/site/PageServer?pagename=ntld_main&s_src=RSG000000000&s_subsrc=RCO_FrontPagePanel') : window.location.href = 'http://american.redcross.org/site/PageServer?pagename=ntld_main&s_src=RSG000000000&s_subsrc=RCO_FrontPagePanel';
        });
        $('#activebar-container').live('mouseover',function(e) {
            $('#activebar-container').addClass('activebar-link');
        });
    }
});
//-- End InfoBar Stack --//

	return stack;
})(stacks.stacks_in_1_page18);


// Javascript for stacks_in_9_page18
// ---------------------------------------------------------------------

// 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_9_page18 = {};

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

	// When jQuery is used it will be available as $ and jQuery but only
	// inside the closure.
	var jQuery = stacks.jQuery;
	var $ = jQuery;
	
//-- Like It Stack v1.1.0 by Joe Workman --//

/*  Tallest jQuery Plugin
 *	@author	nickf
 *	@date	2009-08-19
 *	@version 1.0 $Id: jquery.tallest.js 100 2009-08-19 00:40:09Z spadgos $
 */
jQuery(function($) {
	$.fn.tallest = function()       { return this._extremities({ 'aspect' : 'height', 'max' : true  })[0] };
	$.fn.tallestSize = function()   { return this._extremities({ 'aspect' : 'height', 'max' : true  })[1] };
	$.fn.shortest = function()      { return this._extremities({ 'aspect' : 'height', 'max' : false })[0] };
	$.fn.shortestSize = function()  { return this._extremities({ 'aspect' : 'height', 'max' : false })[1] };
	$.fn.widest = function()        { return this._extremities({ 'aspect' : 'width',  'max' : true  })[0] };
	$.fn.widestSize = function()    { return this._extremities({ 'aspect' : 'width',  'max' : true  })[1] };
	$.fn.thinnest = function()      { return this._extremities({ 'aspect' : 'width',  'max' : false })[0] };
	$.fn.thinnestSize = function()  { return this._extremities({ 'aspect' : 'width',  'max' : false })[1] };
	$.fn._extremities = function(options) {
		var defaults = {
			aspect : 'height', // or 'width'
			max : true	// or false to find the min
		};
		options = $.extend(defaults, options);
		if (this.length < 2) {
			return [this, this[options.aspect]()];
		}
		var bestIndex = 0,
			bestSize = this.eq(0)[options.aspect](),
			thisSize
		;
		for (var i = 1; i < this.length; ++i) {
			thisSize = this.eq(i)[options.aspect]();
			if ((options.max && thisSize > bestSize) || (!options.max && thisSize < bestSize)) {
				bestSize = thisSize;
				bestIndex = i;
			}
		}
		return [ this.eq(bestIndex), bestSize ];
	};
});
(function($){ 
    $.getScript = function(url, callback, cache){
    	$.ajax({
    			type: "GET",
    			url: url,
    			success: callback,
    			dataType: "script",
    			cache: true
    	});
    };
})(jQuery)

$(document).ready(function() {	
    
// Twitter Buttons
switch ( 3 ) {
case 1:
	$('#like_twitter1 a').attr('data-count', 'vertical');
    $.getScript('http://platform.twitter.com/widgets.js');
    break;
case 2:
    $('#like_twitter2 a').attr('data-count', 'horizontal');
    $.getScript('http://platform.twitter.com/widgets.js');
    break;
case 3:
    $('#like_twitter3 a').attr('data-count', 'none');
    $.getScript('http://platform.twitter.com/widgets.js');
    break;
default:
    // Do Nothing
}
// Google Buttons
switch ( 3 ) {
case 1:
	$('#like_google1 .like_google').html('<g:plusone size="small" count="false"></g:plusone>');
    $.getScript('https://apis.google.com/js/plusone.js');
    break;
case 2:
	$('#like_google2 .like_google').html('<g:plusone size="small" count="true"></g:plusone>');
    $.getScript('https://apis.google.com/js/plusone.js');
    break;
case 3:
	$('#like_google3 .like_google').html('<g:plusone size="medium" count="false"></g:plusone>');
    $.getScript('https://apis.google.com/js/plusone.js');
    break;
case 4:
	$('#like_google4 .like_google').html('<g:plusone size="medium" count="true"></g:plusone>');
    $.getScript('https://apis.google.com/js/plusone.js');
    break;
case 5:
	$('#like_google5 .like_google').html('<g:plusone size="standard" count="false"></g:plusone>');
    $.getScript('https://apis.google.com/js/plusone.js');
    break;
case 6:
	$('#like_google6 .like_google').html('<g:plusone size="standard" count="true"></g:plusone>');
    $.getScript('https://apis.google.com/js/plusone.js');
    break;
case 7:
	$('#like_google7 .like_google').html('<g:plusone size="tall" count="true"></g:plusone>');
    $.getScript('https://apis.google.com/js/plusone.js');
    break;
default:
    // Do Nothing
}

// Facebook Buttons
switch ( 2 ) {
case 1:
    $('#like_facebook1 .like_facebook').html('<fb:like show_faces="false" width="280"></fb:like>');
    break;
case 2:
    $('#like_facebook2 .like_facebook').html('<fb:like layout="button_count" show_faces="false" width="50"></fb:like>');
    break;
case 3:
    $('#like_facebook3 .like_facebook').html('<fb:like layout="box_count" show_faces="false" width="50"></fb:like>');
    break;
case 4:
    $('#like_facebook4 .like_facebook').html('<fb:like show_faces="false" width="450" action="recommend"></fb:like>');
    break;
case 5:
    $('#like_facebook5 .like_facebook').html('<fb:like layout="button_count" show_faces="false" width="50" action="recommend"></fb:like>');
    break;
case 6:
    $('#like_facebook6 .like_facebook').html('<fb:like layout="box_count" show_faces="false" width="50" action="recommend"></fb:like>');
    break;
default:
    // Do Nothing
}
// Digg Buttons
switch ( 0 ) {
case 1:
    $('#like_digg1 a').addClass('DiggWide');
    $.getScript('http://widgets.digg.com/buttons.js');
    break;
case 2:
    $('#like_digg2 a').addClass('DiggMedium');
    $.getScript('http://widgets.digg.com/buttons.js');
    break;
case 3:
    $('#like_digg3 a').addClass('DiggCompact');
    $.getScript('http://widgets.digg.com/buttons.js');
    break;
case 4:
    $('#like_digg4 a').addClass('DiggIcon');
    $.getScript('http://widgets.digg.com/buttons.js');
    break;
default:
    // Do Nothing
}
// LinkedIn Buttons
switch ( 3 ) {
case 1:
    $('#like_linkedin1').html('<script type="in/share" data-counter="top"></script>');
    $.getScript('http://platform.linkedin.com/in.js');
    break;
case 2:
	$('#like_linkedin2').html('<script type="in/share" data-counter="right"></script>');
	$.getScript('http://platform.linkedin.com/in.js');
	break;
case 3:
	$('#like_linkedin3').html('<script type="in/share"></script>');
	$.getScript('http://platform.linkedin.com/in.js');
	break;
default:
    // Do Nothing
}
// Evernote Button
if (3 != 0) {
    $.getScript('http://static.evernote.com/noteit.js');
}
//Email Button
$('.like_email a').attr('href','mailto:?subject=Check out this webpage&body='+location.href);
// Make all buttons have the same height and display it
// $('.like_button_wrapper').height( $('.like_button').tallest().height() );
});

//-- End Like It Stack --//
	return stack;
})(stacks.stacks_in_9_page18);



