Cufon.replace('#ViewBasket strong', { 
	fontFamily: 'CenturyGothic' ,
	hover: true
});
Cufon.replace('#WigFinder h2', { 
	fontFamily: 'CenturyGothic'
});
Cufon.replace('#LeftColumn h2', { 
	fontFamily: 'CenturyGothic'
});
Cufon.replace('#ShopNav strong a', { 
	fontFamily: 'CenturyGothic' ,
	hover: true
});
Cufon.replace('#PageTitle', { 
	fontFamily: 'CenturyGothic'
});
Cufon.replace('.AddToBasket', { 
	fontFamily: 'CenturyGothic' ,
	hover: true
});
Cufon.replace('.SoldOut', { 
	fontFamily: 'CenturyGothic'
});
Cufon.replace('.PageCopyOutput h1', { 
	fontFamily: 'CenturyGothic'
});
Cufon.replace('.PageCopyOutput h2', { 
	fontFamily: 'CenturyGothic'
});
Cufon.replace('#HomeWigDetails h2', { 
	fontFamily: 'CenturyGothic' ,
	hover: true
});
Cufon.replace('p.BigPrice', { 
	fontFamily: 'CenturyGothic'
});
Cufon.replace('#HomeBottom h1', { 
	fontFamily: 'CenturyGothic' ,
	hover: true
});
Cufon.replace('.SimilarWigs', { 
	fontFamily: 'CenturyGothic' ,
	hover: true
});
function strstr( haystack, needle, bool ) {
	var pos = 0;
	haystack += '';
	pos = haystack.indexOf( needle );
	if (pos == -1)
	{
		return false;
	}
	else
	{
		if( bool )
		{
			return haystack.substr( 0, pos );
		}
		else
		{
			return haystack.slice( pos );
		}
	}
}	

$(function()
{
	$('.ImageHolder a').lightBox();
	$('.GalleryRow dt a').lightBox();
	$('.WigExtraImages a').lightBox();
	$('.LightBox').lightBox();
});

$(function()
{
	$('#SlideShow').cycle({ 
		fx: 'scrollHorz'
		//delay:  -6000
	});
	$('.BrowseSlideShow').cycle({ 
		fx: 'fade'
		//delay:  -6000
	});
});

$(function()
{
	$('#Form textarea').autogrow();				
});

jQuery.fn.fadeToggle = function(speed, easing, callback) {
   return this.animate({opacity: 'toggle'}, speed, easing, callback);

}; 
