﻿
/*
* jqModal - Minimalist Modaling with jQuery
*   (http://dev.iceburg.net/jquery/jqModal/)
*
* Copyright (c) 2007,2008 Brice Burgess <bhb@iceburg.net>
* Dual licensed under the MIT and GPL licenses:
*   http://www.opensource.org/licenses/mit-license.php
*   http://www.gnu.org/licenses/gpl.html
* 
* $Version: 03/01/2009 +r14
*/
(function($) {
	$.fn.jqm = function(o) {
		var p = {
			overlay: 50,
			overlayClass: 'jqmOverlay',
			closeClass: 'jqmClose',
			trigger: '.jqModal',
			ajax: F,
			ajaxText: '',
			target: F,
			modal: F,
			toTop: F,
			onShow: F,
			onHide: F,
			onLoad: F
		};
		return this.each(function() {
			if (this._jqm) return H[this._jqm].c = $.extend({}, H[this._jqm].c, o); s++; this._jqm = s;
			H[s] = { c: $.extend(p, $.jqm.params, o), a: F, w: $(this).addClass('jqmID' + s), s: s };
			if (p.trigger) $(this).jqmAddTrigger(p.trigger);
		});
	};

	$.fn.jqmAddClose = function(e) { return hs(this, e, 'jqmHide'); };
	$.fn.jqmAddTrigger = function(e) { return hs(this, e, 'jqmShow'); };
	$.fn.jqmShow = function(t) { return this.each(function() { t = t || window.event; $.jqm.open(this._jqm, t); }); };
	$.fn.jqmHide = function(t) { return this.each(function() { t = t || window.event; $.jqm.close(this._jqm, t) }); };

	$.jqm = {
		hash: {},
		open: function(s, t) {
			var h = H[s], c = h.c, cc = '.' + c.closeClass, z = (parseInt(h.w.css('z-index'))), z = (z > 0) ? z : 3000, o = $('<div></div>').css({ height: '100%', width: '100%', position: 'fixed', left: 0, top: 0, 'z-index': z - 1, opacity: c.overlay / 100 }); if (h.a) return F; h.t = t; h.a = true; h.w.css('z-index', z);
			if (c.modal) { if (!A[0]) L('bind'); A.push(s); }
			else if (c.overlay > 0) h.w.jqmAddClose(o);
			else o = F;

			h.o = (o) ? o.addClass(c.overlayClass).prependTo('body') : F;
			if (ie6) { $('html,body').css({ height: '100%', width: '100%' }); if (o) { o = o.css({ position: 'absolute' })[0]; for (var y in { Top: 1, Left: 1 }) o.style.setExpression(y.toLowerCase(), "(_=(document.documentElement.scroll" + y + " || document.body.scroll" + y + "))+'px'"); } }

			if (c.ajax) {
				var r = c.target || h.w, u = c.ajax, r = (typeof r == 'string') ? $(r, h.w) : $(r), u = (u.substr(0, 1) == '@') ? $(t).attr(u.substring(1)) : u;
				r.html(c.ajaxText).load(u, function() { if (c.onLoad) c.onLoad.call(this, h); if (cc) h.w.jqmAddClose($(cc, h.w)); e(h); });
			}
			else if (cc) h.w.jqmAddClose($(cc, h.w));

			if (c.toTop && h.o) h.w.before('<span id="jqmP' + h.w[0]._jqm + '"></span>').insertAfter(h.o);
			(c.onShow) ? c.onShow(h) : h.w.show(); e(h); return F;
		},
		close: function(s) {
			var h = H[s]; if (!h.a) return F; h.a = F;
			if (A[0]) { A.pop(); if (!A[0]) L('unbind'); }
			if (h.c.toTop && h.o) $('#jqmP' + h.w[0]._jqm).after(h.w).remove();
			if (h.c.onHide) h.c.onHide(h); else { h.w.hide(); if (h.o) h.o.remove(); } return F;
		},
		params: {}
	};
	var s = 0, H = $.jqm.hash, A = [], ie6 = $.browser.msie && ($.browser.version == "6.0"), F = false,
i = $('<iframe src="javascript:false;document.write(\'\');" class="jqm"></iframe>').css({ opacity: 0 }),
e = function(h) { if (ie6) if (h.o) h.o.html('<p style="width:100%;height:100%"/>').prepend(i); else if (!$('iframe.jqm', h.w)[0]) h.w.prepend(i); f(h); },
f = function(h) { try { $(':input:visible', h.w)[0].focus(); } catch (_) { } },
L = function(t) { $()[t]("keypress", m)[t]("keydown", m)[t]("mousedown", m); },
m = function(e) { var h = H[A[A.length - 1]], r = (!$(e.target).parents('.jqmID' + h.s)[0]); if (r) f(h); return !r; },
hs = function(w, t, c) {
	return w.each(function() {
		var s = this._jqm; $(t).each(function() {
			if (!this[c]) { this[c] = []; $(this).click(function() { for (var i in { jqmShow: 1, jqmHide: 1 }) for (var s in this[i]) if (H[this[i][s]]) H[this[i][s]].w[i](this); return F; }); } this[c].push(s);
		});
	});
};
})(jQuery);


(function($){
	$.superfish = {};
	$.superfish.o = [];
	$.superfish.op = {};
	$.superfish.defaults = {
		hoverClass	: 'sfHover',
		pathClass	: 'overideThisToUse',
		delay		: 800,
		animation	: {opacity:'show'},
		speed		: 'normal',
		oldJquery	: false, /* set to true if using jQuery version below 1.2 */
		disableHI	: false, /* set to true to disable hoverIntent usage */
		// callback functions:
		onInit		: function(){},
		onBeforeShow: function(){},
		onShow		: function(){}, /* note this name changed ('onshow' to 'onShow') from version 1.4 onward */
		onHide		: function(){}
	}
	$.fn.superfish = function(op){
		var bcClass = 'sfbreadcrumb',
			over = function(){
				var $$ = $(this);
				$.superfish.op = getOpts($$);
				clearTimeout(this.sfTimer);
				$$.showSuperfishUl()
				.siblings()
					.hideSuperfishUl();
			},
			out = function(){
				var $$ = $(this);
				var o = $.superfish.op = getOpts($$);
				if ( !$$.is('.'+bcClass) ) {
					this.sfTimer=setTimeout(function(){
						$$.hideSuperfishUl();
						if (!$('.'+o.hoverClass,getMenu($$)).length) {
							if (o.$currents.length)
							over.call(o.$currents.hideSuperfishUl());
						}
					},o.delay);
				}		
			},
			getMenu = function($el){ return $el.parents('ul.superfish:first')[0]; },
			getOpts = function($el){ return $.superfish.o[getMenu($el).serial]; },
			hasUl = function(){ return $.superfish.op.oldJquery ? 'li[ul]' : 'li:has(ul)'; };

		return this.each(function() {
			var s = this.serial = $.superfish.o.length;
			var o = $.extend({},$.superfish.defaults,op);
			o.$currents = $('li.'+o.pathClass,this).each(function(){
				$(this)
				.addClass(o.hoverClass+' '+bcClass)
				.filter(hasUl())
					.removeClass(o.pathClass);
			});
			$.superfish.o[s] = $.superfish.op = o;
			
			$(hasUl(),this)[($.fn.hoverIntent && !o.disableHI) ? 'hoverIntent' : 'hover'](over,out)
			.not('.'+bcClass)
				.hideSuperfishUl();

			$('a',this).each(function(){
				var $a = $(this), $li = $a.parents('li');
				$a.focus(function(){
					over.call($li);
					return false; /*is this needed?*/
				}).blur(function(){
					$li.removeClass(o.hoverClass);
				});
			});
			
			o.onInit.call(this);
			
		}).addClass('superfish');
	};
	
	$.fn.extend({
		hideSuperfishUl : function(){
			var o = $.superfish.op,
			$ul = $('li.'+o.hoverClass,this).andSelf()
			.removeClass(o.hoverClass)
			.find('>ul')
				.hide()
				.css('visibility','hidden');
			o.onHide.call($ul);
			return this;
		},
		showSuperfishUl : function(){
			var o = $.superfish.op,
			$ul = this.addClass(o.hoverClass)
			.find('>ul:hidden')
				.css('visibility','visible');
			o.onBeforeShow.call($ul);
			$ul.animate(o.animation,o.speed,function(){
				o.onShow.call(this);
			});
			return this;
		}
	});
	
	$(window).unload(function(){
		$('ul.superfish').each(function(){
			$('li',this).unbind('mouseover').unbind('mouseout');
		});
	});
})(jQuery);

/*
 * jQuery Cycle Plugin
 * Copyright (c) 2007 M. Alsup
 * Version 2.09
 * Dual licensed under the MIT and GPL licenses
 */
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}('(4($){7 n=\'2.2m\';7 q=$.20.1U&&/2G 6.0/.2g(28.24);$.C.F=4(m){x r.K(4(){m=m||{};3(m.1J==1H){2i(m){1k\'2e\':3(r.D)1g(r.D);r.D=0;x;1k\'1e\':r.N=1;x;1k\'2W\':r.N=0;x;2V:m={V:m}}}7 c=$(r);7 d=m.1o?$(m.1o,r):c.2K();7 e=d.2D();3(e.u<2)x;7 f=$.2v({},$.C.F.1X,m||{},$.1I?c.1I():$.2o?c.2l():{});3(f.1l)f.1E=f.2h||e.u;f.G=f.G?[f.G]:[];f.J=f.J?[f.J]:[];f.J.2d(4(){f.1j=0});3(q&&f.1i&&!f.26)1B(d);7 g=r.23;7 w=11((g.14(/w:(\\d+)/)||[])[1])||f.13;7 h=11((g.14(/h:(\\d+)/)||[])[1])||f.R;f.y=11((g.14(/t:(\\d+)/)||[])[1])||f.y;3(c.B(\'1w\')==\'2S\')c.B(\'1w\',\'2O\');3(w)c.13(w);3(h&&h!=\'1t\')c.R(h);3(f.W){f.O=[];1Q(7 i=0;i<e.u;i++)f.O.1O(i);f.O.2H(4(a,b){x 2C.W()-0.5});f.L=0;f.H=f.O[0]}P 3(f.H>=e.u)f.H=0;7 j=f.H||0;d.B(\'1w\',\'2u\').2t().K(4(i){7 z=j?i>=j?e.u-(i-j):j-i:e.u-i;$(r).B(\'z-2q\',z)});$(e[j]).1V();3(f.X&&w)d.13(w);3(f.X&&h&&h!=\'1t\')d.R(h);3(f.1e)c.2n(4(){r.N=1},4(){r.N=0});7 k=$.C.F.1G[f.V];3($.1F(k))k(c,d,f);d.K(4(){7 a=$(r);r.2k=(f.X&&h)?h:a.R();r.2j=(f.X&&w)?w:a.13()});f.U=f.U||{};f.T=f.T||{};f.S=f.S||{};d.1D(\':18(\'+j+\')\').B(f.U);3(f.1C)$(d[j]).B(f.1C);3(f.y){3(f.E.1J==1H)f.E={2f:2c,2b:2a}[f.E]||29;3(!f.17)f.E=f.E/2;27((f.y-f.E)<25)f.y+=f.E}3(f.1h)f.1f=f.1s=f.1h;3(!f.15)f.15=f.E;3(!f.1d)f.1d=f.E;f.22=e.u;f.I=j;3(f.W){f.9=f.I;3(++f.L==e.u)f.L=0;f.9=f.O[f.L]}P f.9=f.H>=(e.u-1)?0:f.H+1;7 l=d[j];3(f.G.u)f.G[0].12(l,[l,l,f,1A]);3(f.J.u>1)f.J[1].12(l,[l,l,f,1A]);3(f.Q&&!f.A)f.A=f.Q;3(f.A)$(f.A).1z(\'Q\',4(){x 1y(e,f,f.Y?-1:1)});3(f.1x)$(f.1x).1z(\'Q\',4(){x 1y(e,f,f.Y?1:-1)});3(f.10)1Z(e,f);3(f.y)r.D=1Y(4(){Z(e,f,0,!f.Y)},f.y+(f.1W||0))})};4 Z(a,b,c,d){3(b.1j)x;7 p=a[0].1c,M=a[b.I],A=a[b.9];3(p.D===0&&!c)x;3(!c&&!p.N&&b.1l&&(--b.1E<=0))x;3(c||!p.N){3(b.G.u)$.K(b.G,4(i,o){o.12(A,[M,A,b,d])});7 e=4(){3($.20.1U&&b.1i)r.2T.2P(\'1v\');$.K(b.J,4(i,o){o.12(A,[M,A,b,d])})};3(b.9!=b.I){b.1j=1;3(b.1m)b.1m(M,A,b,e,d);P 3($.1F($.C.F[b.V]))$.C.F[b.V](M,A,b,e);P $.C.F.1T(M,A,b,e)}3(b.W){b.I=b.9;3(++b.L==a.u)b.L=0;b.9=b.O[b.L]}P{7 f=(b.9+1)==a.u;b.9=f?0:b.9+1;b.I=f?a.u-1:b.9-1}3(b.10)$(b.10).1S(\'a\').2N(\'1r\').1v(\'a:18(\'+b.I+\')\').1R(\'1r\')}3(b.y)p.D=1Y(4(){Z(a,b,0,!b.Y)},b.y)};4 1y(a,b,c){7 p=a[0].1c,y=p.D;3(y){1g(y);p.D=0}b.9=b.I+c;3(b.9<0)b.9=a.u-1;P 3(b.9>=a.u)b.9=0;3(b.19&&1q b.19==\'4\')b.19(c>0,b.9,a[b.9]);Z(a,b,1,c>=0);x 1P};4 1Z(b,c){7 d=$(c.10);$.K(b,4(i,o){7 a=(1q c.1p==\'4\')?$(c.1p(i,o)):$(\'<a 2M="#">\'+(i+1)+\'</a>\');3(a.2L(\'2J\').u==0)a.2I(d);a.1z(\'Q\',4(){c.9=i;7 p=b[0].1c,y=p.D;3(y){1g(y);p.D=0}3(1q c.1n==\'4\')c.1n(c.9,b[c.9]);Z(b,c,1,!c.Y);x 1P})});d.1S(\'a\').1v(\'a:18(\'+c.H+\')\').1R(\'1r\')};4 1B(b){4 1a(s){7 s=11(s).2F(16);x s.u<2?\'0\'+s:s};4 1N(e){1Q(;e&&e.2B.2A()!=\'2E\';e=e.1c){7 v=$.B(e,\'1M-21\');3(v.2z(\'2y\')>=0){7 a=v.14(/\\d+/g);x\'#\'+1a(a[0])+1a(a[1])+1a(a[2])}3(v&&v!=\'2x\')x v}x\'#2w\'};b.K(4(){$(r).B(\'1M-21\',1N(r))})};$.C.F.1T=4(a,b,c,d){7 e=$(a),$n=$(b);$n.B(c.U);7 f=4(){$n.1L(c.T,c.15,c.1f,d)};e.1L(c.S,c.1d,c.1s,4(){3(c.1b)e.B(c.1b);3(!c.17)f()});3(c.17)f()};$.C.F.1G={1K:4(a,b,c){b.1D(\':18(\'+c.H+\')\').B(\'1u\',0);c.G.1O(4(){$(r).1V()});c.T={1u:1};c.S={1u:0};c.1b={2Q:\'2R\'}}};$.C.F.2s=4(){x n};$.C.F.1X={V:\'1K\',y:2r,E:2U,15:8,1d:8,Q:8,A:8,1x:8,19:8,10:8,1n:8,1p:8,G:8,J:8,1h:8,1f:8,1s:8,2p:8,T:8,S:8,U:8,1b:8,1m:8,R:\'1t\',H:0,17:1,W:0,X:0,1e:0,1l:0,1W:0,1o:8,1i:0}})(2X);',62,184,'|||if|function|||var|null|nextSlide||||||||||||||||||this|||length|||return|timeout||next|css|fn|cycleTimeout|speed|cycle|before|startingSlide|currSlide|after|each|randomIndex|curr|cyclePause|randomMap|else|click|height|animOut|animIn|cssBefore|fx|random|fit|rev|go|pager|parseInt|apply|width|match|speedIn||sync|eq|prevNextClick|hex|cssAfter|parentNode|speedOut|pause|easeIn|clearTimeout|easing|cleartype|busy|case|autostop|fxFn|pagerClick|slideExpr|pagerAnchorBuilder|typeof|activeSlide|easeOut|auto|opacity|filter|position|prev|advance|bind|true|clearTypeFix|cssFirst|not|countdown|isFunction|transitions|String|metadata|constructor|fade|animate|background|getBg|push|false|for|addClass|find|custom|msie|show|delay|defaults|setTimeout|buildPager|browser|color|slideCount|className|userAgent|250|cleartypeNoBg|while|navigator|400|200|fast|600|unshift|stop|slow|test|autostopCount|switch|cycleW|cycleH|data|09|hover|meta|shuffle|index|4000|ver|hide|absolute|extend|ffffff|transparent|rgb|indexOf|toLowerCase|nodeName|Math|get|html|toString|MSIE|sort|appendTo|body|children|parents|href|removeClass|relative|removeAttribute|display|none|static|style|1000|default|resume|jQuery'.split('|'),0,{}))


$(document).ready(function(){
	$("ul.nav").superfish();
	// set external links
	$('a.external').click(function(){
		window.open(this.href);
		return false;
	});
});

function WriteEmail(to,txt,cls,sbj,tt,oe){
    if (oe == null) {
        oe = "earlyyears"+"childcare.co.uk";
    }
    
	var a = to+"@"+oe;
	var csscls = "";
	var sub = "";
	var title = "";
	if (txt == null) txt = a;
	if (cls != null) csscls = " class='"+cls+"' ";
	if (sbj != null) sub = "?subject="+sbj;
	if (tt != null) title = " title='"+tt+"'";
	document.write("<a href='mai"+"lto:"+a+sub+"'" + csscls + title + ">"+txt+"<\/a>");
}



/**
* --------------------------------------------------------------------
* jQuery-Plugin "pngFix"
* Version: 1.1, 11.09.2007
* by Andreas Eberhard, andreas.eberhard@gmail.com
*                      http://jquery.andreaseberhard.de/
*
* Copyright (c) 2007 Andreas Eberhard
* Licensed under GPL (http://www.opensource.org/licenses/gpl-license.php)
*/
eval(function(p, a, c, k, e, r) { e = function(c) { return (c < 62 ? '' : e(parseInt(c / 62))) + ((c = c % 62) > 35 ? String.fromCharCode(c + 29) : c.toString(36)) }; if ('0'.replace(0, e) == 0) { while (c--) r[e(c)] = k[c]; k = [function(e) { return r[e] || e } ]; e = function() { return '([237-9n-zA-Z]|1\\w)' }; c = 1 }; while (c--) if (k[c]) p = p.replace(new RegExp('\\b' + e(c) + '\\b', 'g'), k[c]); return p } ('(s(m){3.fn.pngFix=s(c){c=3.extend({P:\'/img/blank.gif\'},c);8 e=(o.Q=="t R S"&&T(o.u)==4&&o.u.A("U 5.5")!=-1);8 f=(o.Q=="t R S"&&T(o.u)==4&&o.u.A("U 6.0")!=-1);p(3.browser.msie&&(e||f)){3(2).B("img[n$=.C]").D(s(){3(2).7(\'q\',3(2).q());3(2).7(\'r\',3(2).r());8 a=\'\';8 b=\'\';8 g=(3(2).7(\'E\'))?\'E="\'+3(2).7(\'E\')+\'" \':\'\';8 h=(3(2).7(\'F\'))?\'F="\'+3(2).7(\'F\')+\'" \':\'\';8 i=(3(2).7(\'G\'))?\'G="\'+3(2).7(\'G\')+\'" \':\'\';8 j=(3(2).7(\'H\'))?\'H="\'+3(2).7(\'H\')+\'" \':\'\';8 k=(3(2).7(\'V\'))?\'float:\'+3(2).7(\'V\')+\';\':\'\';8 d=(3(2).parent().7(\'href\'))?\'cursor:hand;\':\'\';p(2.9.v){a+=\'v:\'+2.9.v+\';\';2.9.v=\'\'}p(2.9.w){a+=\'w:\'+2.9.w+\';\';2.9.w=\'\'}p(2.9.x){a+=\'x:\'+2.9.x+\';\';2.9.x=\'\'}8 l=(2.9.cssText);b+=\'<y \'+g+h+i+j;b+=\'9="W:X;white-space:pre-line;Y:Z-10;I:transparent;\'+k+d;b+=\'q:\'+3(2).q()+\'z;r:\'+3(2).r()+\'z;\';b+=\'J:K:L.t.M(n=\\\'\'+3(2).7(\'n\')+\'\\\', N=\\\'O\\\');\';b+=l+\'"></y>\';p(a!=\'\'){b=\'<y 9="W:X;Y:Z-10;\'+a+d+\'q:\'+3(2).q()+\'z;r:\'+3(2).r()+\'z;">\'+b+\'</y>\'}3(2).hide();3(2).after(b)});3(2).B("*").D(s(){8 a=3(2).11(\'I-12\');p(a.A(".C")!=-1){8 b=a.13(\'url("\')[1].13(\'")\')[0];3(2).11(\'I-12\',\'none\');3(2).14(0).15.J="K:L.t.M(n=\'"+b+"\',N=\'O\')"}});3(2).B("input[n$=.C]").D(s(){8 a=3(2).7(\'n\');3(2).14(0).15.J=\'K:L.t.M(n=\\\'\'+a+\'\\\', N=\\\'O\\\');\';3(2).7(\'n\',c.P)})}return 3}})(3);', [], 68, '||this|jQuery||||attr|var|style||||||||||||||src|navigator|if|width|height|function|Microsoft|appVersion|border|padding|margin|span|px|indexOf|find|png|each|id|class|title|alt|background|filter|progid|DXImageTransform|AlphaImageLoader|sizingMethod|scale|blankgif|appName|Internet|Explorer|parseInt|MSIE|align|position|relative|display|inline|block|css|image|split|get|runtimeStyle'.split('|'), 0, {}))
