jQuery(document).ready(function(){if(jQuery('#contact-us-form').length!=0){jQuery('input[type=checkbox]').change(function(){jQuery('#email-recipient0').val('');if(jQuery(this).attr('id')=='em-check'){jQuery('#email-recipient1').val('john.baird@ruffalocody.com');if(!jQuery(this).attr('checked')){jQuery('#email-recipient1').val('');}}
if(jQuery(this).attr('id')=='fund-check'){jQuery('#email-recipient2').val('rich.vanantwerp@ruffalocody.com');jQuery('#email-recipient8').val('sarah.kleeberger@ruffalocody.com');if(!jQuery(this).attr('checked')){jQuery('#email-recipient2').val('');jQuery('#email-recipient8').val('');}}
if(jQuery(this).attr('id')=='on-site-check'){jQuery('#email-recipient3').val('stan.campbell@ruffalocody.com');jQuery('#email-recipient9').val('sarah.kleeberger@ruffalocody.com');if(!jQuery(this).attr('checked')){jQuery('#email-recipient3').val('');jQuery('#email-recipient9').val('');}}
if(jQuery(this).attr('id')=='giving-check'){jQuery('#email-recipient4').val('timothy.logan@ruffalocody.com');if(!jQuery(this).attr('checked')){jQuery('#email-recipient4').val('');}}
if(jQuery(this).attr('id')=='software-check'){jQuery('#email-recipient5').val('bart.showalter@ruffalocody.com');if(!jQuery(this).attr('checked')){jQuery('#email-recipient5').val('');}}
if(jQuery(this).attr('id')=='consulting-check'){jQuery('#email-recipient6').val('jason.fisher@ruffalocody.com');if(!jQuery(this).attr('checked')){jQuery('#email-recipient6').val('');}}
if(jQuery(this).attr('id')=='newsletter-check'){jQuery('#email-recipient7').val('laura.ballard@ruffalocody.com');if(!jQuery(this).attr('checked')){jQuery('#email-recipient7').val('');}}});}
if(jQuery('#home #featured .nav').length!=0){jQuery('#home #featured .nav').tabs('#home #featured .cycle > .item',{rotate:true,event:'mouseover'}).slideshow({autoplay:true,autopause:true,interval:3000});var api=jQuery('#home #featured .nav').tabs('#home #featured .cycle > .item',{api:true});jQuery('#enrollment-management-area').hover(function(){api.click(0);},function(){});jQuery('#fundraising-area').hover(function(){api.click(1);},function(){});jQuery('#on-campus-phonathon-management-area').hover(function(){api.click(2);},function(){});jQuery('#planned-giving-area').hover(function(){api.click(3);},function(){});jQuery('#phonathon-software-area').hover(function(){api.click(4);},function(){});}
if(jQuery('#home #whats-new .scroller').length!=0){jQuery('#home #whats-new .scroller').scrollable({vertical:true,size:1,speed:1200,easing:'easeOutQuad',clickable:false}).circular().autoscroll({autoplay:true,steps:-1,interval:5000});}
if(jQuery('.alert').length!=0){jQuery('.alert').hide().fadeIn('slow');}
jQuery('input[type=text]:not(".un-placeholder"),textarea:not(".un-placeholder")').addClass('placeholder');jQuery('input[type=text],textarea').focus(function(){if(jQuery(this).hasClass('placeholder')&&jQuery(this).val()==jQuery(this).attr('defaultValue'))
{jQuery(this).val('');}});jQuery('input[type=text],textarea').focus(function(){jQuery(this).removeClass('placeholder');});jQuery('input[type=text],textarea').blur(function(){if(jQuery(this).val()=='')
{jQuery(this).val(jQuery(this).attr('defaultValue'));jQuery(this).addClass('placeholder');}});if(jQuery.browser.msie){}else{jQuery('.lightbox,.post a[href*="jpg"]').fancybox({'hideOnContentClick':false,'speedIn':700,'speedOut':500,'easingIn':'easeInOutCubic','easingOut':'easeInBack','transitionIn':'elastic','transitionOut':'elastic'});jQuery('.popup').fancybox({'width':'80%','height':'85%','autoScale':false,'transitionIn':'fade','transitionOut':'fade','type':'iframe','centerOnScroll':'true'});}
jQuery('form:not(.wpcf7-form)').validationEngine({inlineValidation:true,success:function(){form_submit();submit();},failure:function(){peekaboo_popups();}});function form_submit(){var loaderIMG='/wp-content/themes/ruffalocody/images/ajax-loader.gif';jQuery('form * *').children('input[type=submit]').replaceWith('<div class="processing"><img src="'+loaderIMG+'" width="16" height="16" alt="Uploading..." title="Uploading..." style="border:none;" /><p>Please wait while your submission is being processed.</p></div>');}
jQuery('#invoice').change(function(){jQuery('#registration-form,#registration-form-multiple').attr('action','http://www.hrb-ideas.com/forms/process.php');});jQuery('#creditcard').change(function(){jQuery('#registration-form,#registration-form-multiple').attr('action','https://payflowlink.paypal.com');});function peekaboo_popups(){jQuery('.formError').hover(function(){jQuery(this).stop().fadeTo('fast',0.1);},function(){jQuery(this).stop().fadeTo('slow',1);});jQuery('.formError').click(function(){jQuery(this).remove();});}
if(jQuery('body#events-registration').length==0&&jQuery('body.post-30').length==0){jQuery('#side-nav li:has(ul) > a').addClass('folded');jQuery('#side-nav .current_page_ancestor > ul,#side-nav .current_page_item > ul').slideDown('slow');jQuery('#side-nav .current_page_ancestor:has(ul) > a,#side-nav .current_page_item:has(ul) > a').removeClass('folded').addClass('expanded');jQuery('#side-nav li ul .current_page_item a,#side-nav li ul .current_page_ancestor a').removeClass('expanded');jQuery('#side-nav > li a.expanded').not('#side-nav li ul a').toggle(function(){jQuery(this).removeClass('expanded').addClass('folded');jQuery(this).next().stop(true,true).slideUp('slow','easeInOutCubic');return false;},function(){jQuery(this).removeClass('folded').addClass('expanded');jQuery(this).next().stop(true,true).slideDown('slow','easeInOutCubic');return false;});jQuery('#side-nav > li a.folded').not('#side-nav li ul a').toggle(function(){jQuery(this).removeClass('folded').addClass('expanded');jQuery(this).next().stop(true,true).slideDown('slow','easeInOutCubic');return false;},function(){jQuery(this).removeClass('expanded').addClass('folded');jQuery(this).next().stop(true,true).slideUp('slow','easeInOutCubic');return false;});}
jQuery('.read-more-link').click(function(){jQuery(this).parent().next().slideDown('slow','easeInOutCubic');jQuery(this).parent().slideUp('slow','easeInOutCubic');return false;});});