Showing posts with label Mootools. Show all posts
Showing posts with label Mootools. Show all posts

August 13, 2011

How To Add MooTools Tooltip to Blogger

How To Add MooTools Tooltip to Blogger 

1.Login to your blogger dashboard--> Design- -> Edit HTML

2.Scroll down to where you see </head> tag .

3.Copy below code and paste it just before the </head> tag .


<script type='text/javascript'>
//<![CDATA[

// mootools.js: moo javascript tools
// by Valerio Proietti (http://mad4milk.net) MIT-style license.

// CREDITS:

// Class is slightly based on Base.js : http://dean.edwards.name/weblog/2006/03/base/
// (c) 2006 Dean Edwards, License: http://creativecommons.org/licenses/LGPL/2.1/

// Some functions are based on those found in prototype.js : http://prototype.conio.net/
// (c) 2005 Sam Stephenson <sam@conio.net>, MIT-style license


//moo.js : My Object Oriented javascript - has no dependancies

var Class = function(properties){
var klass = function(){
for (p in this) this[p]._proto_ = this;
if (arguments[0] != 'noinit' && this.initialize) return this.initialize.apply(this, arguments);
};
klass.extend = this.extend;
klass.implement = this.implement;
klass.prototype = properties;
return klass;
};

Class.empty = function(){};

Class.create = function(properties){
return new Class(properties);
};

Class.prototype = {
extend: function(properties){
var prototype = new this('noinit');
for (property in properties){
var previous = prototype[property];
var current = properties[property];
if (previous && previous != current) current = previous.parentize(current) || current;
prototype[property] = current;
}
return new Class(prototype);
},

implement: function(properties){
for (property in properties) this.prototype[property] = properties[property];
}
}

Object.extend = function(){
var args = arguments;
if (args[1]) args = [args[0], args[1]];
else args = [this, args[0]];
for (property in args[1]) args[0][property] = args[1][property];
return args[0];
};

Object.Native = function(){
for (var i = 0; i < arguments.length; i++) arguments[i].extend = Class.prototype.implement;
};

new Object.Native(Function, Array, String);

Function.extend({
parentize: function(current){
var previous = this;
return function(){
this.parent = previous;
return current.apply(this, arguments);
};
}
});

//Function.js : Function extension - Depends on Moo.js

Function.extend({

pass: function(args, bind){
var fn = this;
if ($type(args) != 'array') args = [args];
return function(){
fn.apply(bind || fn._proto_ || fn, args);
};
},

bind: function(bind){
var fn = this;
return function(){
return fn.apply(bind, arguments);
};
},

bindAsEventListener: function(bind){
var fn = this;
return function(event){
fn.call(bind, event || window.event);
return false;
};
},

delay: function(ms, bind){
return setTimeout(this.bind(bind || this._proto_ || this), ms);
},

periodical: function(ms, bind){
return setInterval(this.bind(bind || this._proto_ || this), ms);
}

});

function $clear(timer){
clearTimeout(timer);
clearInterval(timer);
return null;
};

function $type(obj, types){
if (!obj) return false;
var type = false;
if (obj instanceof Function) type = 'function';
else if (obj.nodeName){
if (obj.nodeType == 3 && !/S/.test(obj.nodeValue)) type = 'textnode';
else if (obj.nodeType == 1) type = 'element';
}
else if (obj instanceof Array) type = 'array';
else if (typeof obj == 'object') type = 'object';
else if (typeof obj == 'string') type = 'string';
else if (typeof obj == 'number' && isFinite(obj)) type = 'number';
return type;
};

function $check(obj, objTrue, objFalse){
if (obj) {
if (objTrue && $type(objTrue) == 'function') return objTrue();
else return objTrue || obj;
} else {
if (objFalse && $type(objFalse) == 'function') return objFalse();
return objFalse || false;
}
};

var Chain = new Class({

chain: function(fn){
this.chains = this.chains || [];
this.chains.push(fn);
return this;
},

callChain: function(){
if (this.chains && this.chains.length) this.chains.splice(0, 1)[0].delay(10, this);
}

});

//Array.js : Array extension - depends on Moo.js

if (!Array.prototype.forEach){
Array.prototype.forEach = function(fn, bind){
for(var i = 0; i < this.length ; i++) fn.call(bind, this[i], i);
};
}

Array.extend({

each: Array.prototype.forEach,

copy: function(){
var nArray = [];
for (var i = 0; i < this.length; i++) nArray.push(this[i]);
return nArray;
},

remove: function(item){
for (var i = 0; i < this.length; i++){
if (this[i] == item) this.splice(i, 1);
}
return this;
},

test: function(item){
for (var i = 0; i < this.length; i++){
if (this[i] == item) return true;
};
return false;
},

extend: function(nArray){
for (var i = 0; i < nArray.length; i++) this.push(nArray[i]);
return this;
}

});

function $A(array){
return Array.prototype.copy.call(array);
};

//String.js : String extension - depends on Moo.js

String.extend({

test: function(value, params){
return this.match(new RegExp(value, params));
},

camelCase: function(){
return this.replace(/-D/gi, function(match){
return match.charAt(match.length - 1).toUpperCase();
});
},

capitalize: function(){
return this.toLowerCase().replace(/b[a-z]/g, function(match){
return match.toUpperCase();
});
},

trim: function(){
return this.replace(/^s*|s*$/g,'');
},

clean: function(){
return this.replace(/ss/g, ' ').trim();
},

rgbToHex: function(array){
var rgb = this.test('^[rgba]{3,4}\(([\d]{0,3}),[\s]*([\d]{0,3}),[\s]*([\d]{0,3})\)$');
var hex = [];
for (var i = 1; i < rgb.length; i++) hex.push((rgb[i]-0).toString(16));
var hexText = '#'+hex.join('');
if (array) return hex;
else return hexText;
},

hexToRgb: function(array){
var hex = this.test('^[#]{0,1}([\w]{1,2})([\w]{1,2})([\w]{1,2})$');
var rgb = [];
for (var i = 1; i < hex.length; i++){
if (hex[i].length == 1) hex[i] += hex[i];
rgb.push(parseInt(hex[i], 16));
}
var rgbText = 'rgb('+rgb.join(',')+')';
if (array) return rgb;
else return rgbText;
}

});

//Element.js : Element methods - depends on Moo.js + Native Scripts

var Element = new Class({

//creation

initialize: function(el){
if ($type(el) == 'string') el = document.createElement(el);
return $(el);
},

//injecters

inject: function(el, where){
var el = $check($(el), $(el), new Element(el));
switch(where){
case "before": $(el.parentNode).insertBefore(this, el); break;
case "after": {
if (!el.getNext()) $(el.parentNode).appendChild(this);
else $(el.parentNode).insertBefore(this, el.getNext());
} break;
case "inside": el.appendChild(this); break;
}
return this;
},

injectBefore: function(el){
return this.inject(el, 'before');
},

injectAfter: function(el){
return this.inject(el, 'after');
},

injectInside: function(el){
return this.inject(el, 'inside');
},

adopt: function(el){
var el = $check($(el), $(el), new Element(el));
this.appendChild(el);
return this;
},

//actions

remove: function(){
this.parentNode.removeChild(this);
},

clone: function(){
return $(this.cloneNode(true));
},

replaceWith: function(el){
var el = $check($(el), $(el), new Element(el));
this.parentNode.replaceChild(el, this);
return el;
},

appendText: function(text){
if (this.getTag() == 'style' && window.ActiveXObject) this.styleSheet.cssText = text;
else this.appendChild(document.createTextNode(text));
return this;
},

//classnames

hasClassName: function(className){
return $check(this.className.test("\b"+className+"\b"), true);
},

addClassName: function(className){
if (!this.hasClassName(className)) this.className = (this.className+' '+className.trim()).clean();
return this;
},

removeClassName: function(className){
if (this.hasClassName(className)) this.className = this.className.replace(className.trim(), '').clean();
return this;
},

toggleClassName: function(className){
if (this.hasClassName(className)) return this.removeClassName(className);
else return this.addClassName(className);
},

//styles

setStyle: function(property, value){
if (property == 'opacity') this.setOpacity(value);
else this.style[property.camelCase()] = value;
return this;
},

setStyles: function(source){
if ($type(source) == 'object') {
for (property in source) this.setStyle(property, source[property]);
} else if ($type(source) == 'string') this.setAttribute('style', source);
return this;
},

setOpacity: function(opacity){
if (opacity == 0 && this.style.visibility != "hidden") this.style.visibility = "hidden";
else if (this.style.visibility != "visible") this.style.visibility = "visible";
if (window.ActiveXObject) this.style.filter = "alpha(opacity=" + opacity*100 + ")";
this.style.opacity = opacity;
return this;
},

getStyle: function(property, num){
var proPerty = property.camelCase();
var style = $check(this.style[proPerty]);
if (!style) {
if (document.defaultView) style = document.defaultView.getComputedStyle(this,null).getPropertyValue(property);
else if (this.currentStyle) style = this.currentStyle[proPerty];
}
if (style && ['color', 'backgroundColor', 'borderColor'].test(proPerty) && style.test('rgb')) style = style.rgbToHex();
if (['auto', 'transparent'].test(style)) style = 0;
if (num) return parseInt(style);
else return style;
},

removeStyles: function(){
$A(arguments).each(function(property){
this.style[property.camelCase()] = '';
}, this);
return this;
},

//events

addEvent: function(action, fn){
this[action+fn] = fn.bind(this);
if (this.addEventListener) this.addEventListener(action, fn, false);
else this.attachEvent('on'+action, this[action+fn]);
var el = this;
if (this != window) Unload.functions.push(function(){
el.removeEvent(action, fn);
el[action+fn] = null;
});
return this;
},

removeEvent: function(action, fn){
if (this.removeEventListener) this.removeEventListener(action, fn, false);
else this.detachEvent('on'+action, this[action+fn]);
return this;
},

//get non-text elements

getBrother: function(what){
var el = this[what+'Sibling'];
while ($type(el) == 'textnode') el = el[what+'Sibling'];
return $(el);
},

getPrevious: function(){
return this.getBrother('previous');
},

getNext: function(){
return this.getBrother('next');
},

getFirst: function(){
var el = this.firstChild;
while ($type(el) == 'textnode') el = el.nextSibling;
return $(el);
},

//properties

setProperty: function(property, value){
var el = false;
switch(property){
case 'class': this.className = value; break;
case 'style': this.setStyles(value); break;
case 'name': if (window.ActiveXObject && this.getTag() == 'input'){
el = $(document.createElement('<input name="'+value+'" />'));
$A(this.attributes).each(function(attribute){
if (attribute.name != 'name') el.setProperty(attribute.name, attribute.value);

});
if (this.parentNode) this.replaceWith(el);
};
default: this.setAttribute(property, value);
}
return el || this;
},

setProperties: function(source){
for (property in source) this.setProperty(property, source[property]);
return this;
},

setHTML: function(html){
this.innerHTML = html;
return this;
},

getProperty: function(property){
return this.getAttribute(property);
},

getTag: function(){
return this.tagName.toLowerCase();
},

//position

getOffset: function(what){
what = what.capitalize();
var el = this;
var offset = 0;
do {
offset += el['offset'+what] || 0;
el = el.offsetParent;
} while (el);
return offset;
},

getTop: function(){
return this.getOffset('top');
},

getLeft: function(){
return this.getOffset('left');
}

});

function $Element(el, method, args){
if ($type(args) != 'array') args = [args];
return Element.prototype[method].apply(el, args);
};

new Object.Native(Element);

function $(el){
if ($type(el) == 'string') el = document.getElementById(el);
if ($type(el) == 'element'){
if (!el.extend){
Unload.elements.push(el);
el.extend = Object.extend;
el.extend(Element.prototype);
}
return el;
} else return false;
};

//garbage collector

window.addEvent = Element.prototype.addEvent;
window.removeEvent = Element.prototype.removeEvent;

var Unload = {

elements: [], functions: [], vars: [],

unload: function(){
Unload.functions.each(function(fn){
fn();
});

window.removeEvent('unload', window.removeFunction);

Unload.elements.each(function(el){
for(p in Element.prototype){
window[p] = null;
document[p] = null;
el[p] = null;
}
el.extend = null;
});
}

};
window.removeFunction = Unload.unload;
window.addEvent('unload', window.removeFunction);

//Fx.js - depends on Moo.js + Native Scripts

var Fx = fx = {};

Fx.Base = new Class({

setOptions: function(options){
this.options = Object.extend({
duration: 500,
onComplete: Class.empty,
onStart: Class.empty,
unit: 'px',
wait: true,
transition: Fx.sinoidal,
fps: 30
}, options || {});
},

step: function(){
var currentTime = (new Date).getTime();
if (currentTime >= this.options.duration+this.startTime){
this.clearTimer();
this.now = this.to;
this.options.onComplete.pass(this.el, this).delay(10);
this.callChain();
} else {
this.tPos = (currentTime - this.startTime) / this.options.duration;
this.setNow();
}
this.increase();
},

setNow: function(){
this.now = this.compute(this.from, this.to);
},

compute: function(from, to){
return this.options.transition(this.tPos) * (to-from) + from;
},

custom: function(from, to){
if(!this.options.wait) this.clearTimer();
if (this.timer) return;
this.options.onStart.pass(this.el, this).delay(10);
this.from = from;
this.to = to;
this.startTime = (new Date).getTime();
this.timer = this.step.periodical(Math.round(1000/this.options.fps), this);
return this;
},

set: function(to){
this.now = to;
this.increase();
return this;
},

clearTimer: function(){
this.timer = $clear(this.timer);
return this;
},

setStyle: function(el, property, value){
if (property == 'opacity'){
if (value == 1 && navigator.userAgent.test('Firefox')) value = 0.9999;
el.setOpacity(value);
} else el.setStyle(property, value+this.options.unit);
}

});

Fx.Base.implement(new Chain);

Fx.Style = Fx.Base.extend({

initialize: function(el, property, options){
this.el = $(el);
this.setOptions(options);
this.property = property.camelCase();
},

hide: function(){
return this.set(0);
},

goTo: function(val){
return this.custom(this.now || 0, val);
},

increase: function(){
this.setStyle(this.el, this.property, this.now);
}

});

Fx.Layout = Fx.Style.extend({

initialize: function(el, layout, options){
this.parent(el, layout, options);
this.layout = layout.capitalize();
this.el.setStyle('overflow', 'hidden');
},

toggle: function(){
if (this.el['offset'+this.layout] > 0) return this.custom(this.el['offset'+this.layout], 0);
else return this.custom(0, this.el['scroll'+this.layout]);
},

show: function(){
return this.set(this.el['scroll'+this.layout]);
}

});

Fx.Height = Fx.Layout.extend({

initialize: function(el, options){
this.parent(el, 'height', options);
}

});

Fx.Width = Fx.Layout.extend({

initialize: function(el, options){
this.parent(el, 'width', options);
}

});

Fx.Opacity = Fx.Style.extend({

initialize: function(el, options){
this.parent(el, 'opacity', options);
this.now = 1;
},

toggle: function(){
if (this.now > 0) return this.custom(1, 0);
else return this.custom(0, 1);
},

show: function(){
this.set(1);
}

});

Element.extend({

effect: function(property, options){
return new Fx.Style(this, property, options);
}

});

Fx.sinoidal = function(pos){return ((-Math.cos(pos*Math.PI)/2) + 0.5);}; //this transition is from script.aculo.us

Fx.linear = function(pos){return pos;};

Fx.cubic = function(pos){return Math.pow(pos, 3);};

Fx.circ = function(pos){return Math.sqrt(pos);};

//SuperDom.js - depends on Moo.js + Native Scripts

function $S(){
var els = [];
$A(arguments).each(function(sel){
if ($type(sel) == 'string') els.extend(document.getElementsBySelector(sel));
else if ($type(sel) == 'element') els.push($(sel));
});
return $$(els);
};

function $E(selector, filter){
return ($(filter) || document).getElement(selector);
};

function $$(elements){
return Object.extend(elements, new Elements);
};

Element.extend({

getElements: function(selector){
var filters = [];
selector.clean().split(' ').each(function(sel, i){
var bits = [];
var param = [];
var attr = [];
if (bits = sel.test('^([\w]*)')) param['tag'] = bits[1] || '*';
if (bits = sel.test('([.#]{1})([\w-]*)$')){
if (bits[1] == '.') param['class'] = bits[2];
else param['id'] = bits[2];
}
if (bits = sel.test('\[["'\s]{0,1}([\w-]*)["'\s]{0,1}([\W]{0,1}=){0,2}["'\s]{0,1}([\w-]*)["'\s]{0,1}\]$')){
attr['name'] = bits[1];
attr['operator'] = bits[2];
attr['value'] = bits[3];
}
if (i == 0){
if (param['id']){
var el = this.getElementById(param['id']);
if (el && (param['tag'] == '*' || $(el).getTag() == param['tag'])) filters = [el];
else return false;
} else {
filters = $A(this.getElementsByTagName(param['tag']));
}
} else {
filters = $$(filters).filterByTagName(param['tag']);
if (param['id']) filters = $$(filters).filterById(param['id']);
}
if (param['class']) filters = $$(filters).filterByClassName(param['class']);
if (attr['name']) filters = $$(filters).filterByAttribute(attr['name'], attr['value'], attr['operator']);

}, this);
filters.each(function(el){
$(el);
});
return $$(filters);
},

getElement: function(selector){
return this.getElementsBySelector(selector)[0];
},

getElementsBySelector: function(selector){
var els = [];
selector.split(',').each(function(sel){
els.extend(this.getElements(sel));
}, this);
return $$(els);
}

});

document.extend = Object.extend;

document.extend({

getElementsByClassName: function(className){
return document.getElements('.'+className);
},
getElement: Element.prototype.getElement,
getElements: Element.prototype.getElements,
getElementsBySelector: Element.prototype.getElementsBySelector

});

var Elements = new Class({

action: function(actions){
this.each(function(el){
el = $(el);
if (actions.initialize) actions.initialize.apply(el);
for(action in actions){
var evt = false;
if (action.test('^on[\w]{1,}')) el[action] = actions[action];
else if (evt = action.test('([\w-]{1,})event$')) el.addEvent(evt[1], actions[action]);
}
});
},

filterById: function(id){
var found = [];
this.each(function(el){
if (el.id == id) found.push(el);
});
return found;
},

filterByClassName: function(className){
var found = [];
this.each(function(el){
if ($Element(el, 'hasClassName', className)) found.push(el);
});
return found;
},

filterByTagName: function(tagName){
var found = [];
this.each(function(el){
found.extend($A(el.getElementsByTagName(tagName)));
});
return found;
},

filterByAttribute: function(name, value, operator){
var found = [];
this.each(function(el){
var att = el.getAttribute(name);
if(!att) return;
if (!operator) return found.push(el);

switch(operator){
case '*=': if (att.test(value)) found.push(el); break;
case '=': if (att == value) found.push(el); break;
case '^=': if (att.test('^'+value)) found.push(el); break;
case '$=': if (att.test(value+'$')) found.push(el);
}

});
return found;
}

});

new Object.Native(Elements);

//Ajax.js - depends on Moo.js + Native Scripts

var Ajax = ajax = new Class({

setOptions: function(options){
this.options = {
method: 'post',
postBody: '',
async: true,
onComplete: Class.empty,
update: null,
evalScripts: false
};
Object.extend(this.options, options || {});
},

initialize: function(url, options){
this.setOptions(options);
this.url = url;
this.transport = this.getTransport();
},

request: function(){
this.transport.open(this.options.method, this.url, this.options.async);
this.transport.onreadystatechange = this.onStateChange.bind(this);
if (this.options.method == 'post'){
this.transport.setRequestHeader('Content-type', 'application/x-www-form-urlencoded');
if (this.transport.overrideMimeType) this.transport.setRequestHeader('Connection', 'close');
}
switch($type(this.options.postBody)){
case 'element': this.options.postBody = $(this.options.postBody).toQueryString(); break;
case 'object': this.options.postBody = Object.toQueryString(this.options.postBody);
}
if($type(this.options.postBody) == 'string') this.transport.send(this.options.postBody);
else this.transport.send();
return this;
},

onStateChange: function(){
if (this.transport.readyState == 4 && this.transport.status == 200){
if (this.options.update) $(this.options.update).setHTML(this.transport.responseText);
this.options.onComplete.pass([this.transport.responseText, this.transport.responseXML], this).delay(20);
if (this.options.evalScripts) this.evalScripts.delay(30, this);
this.transport.onreadystatechange = Class.empty;
this.callChain();
}
},

evalScripts: function(){
if(scripts = this.transport.responseText.match(/<script[^>]*?>.*?</script>/g)){
scripts.each(function(script){
eval(script.replace(/^<script[^>]*?>/, '').replace(/</script>$/, ''));
});
}
},

getTransport: function(){
if (window.XMLHttpRequest) return new XMLHttpRequest();
else if (window.ActiveXObject) return new ActiveXObject('Microsoft.XMLHTTP');
}

});

Ajax.implement(new Chain);

Object.toQueryString = function(source){
var queryString = [];
for (property in source) queryString.push(encodeURIComponent(property)+'='+encodeURIComponent(source[property]));
return queryString.join('&');
};

Element.extend({

send: function(options){
options = Object.extend(options, {postBody: this.toQueryString(), method: 'post'});
return new Ajax(this.getProperty('action'), options).request();
},

toQueryString: function(){
var queryString = [];
$A(this.getElementsByTagName('*')).each(function(el){
$(el);
var name = $check(el.name);
if (!name) return;
var value = false;
switch(el.getTag()){
case 'select': value = el.getElementsByTagName('option')[el.selectedIndex].value; break;
case 'input': if ( (el.checked && ['checkbox', 'radio'].test(el.type)) || (['hidden', 'text', 'password'].test(el.type)) )
value = el.value; break;
case 'textarea': value = el.value;
}
if (value) queryString.push(encodeURIComponent(name)+'='+encodeURIComponent(value));
});
return queryString.join('&');
}

});

//DragDrop.js - depends on Moo.js + Native Scripts

var Drag = {};

Drag.Base = new Class({

setOptions: function(options){
this.options = Object.extend({
handle: false,
unit: 'px',
onStart: Class.empty,
onComplete: Class.empty,
onDrag: Class.empty
}, options || {});
},

initialize: function(el, xModifier, yModifier, options){
this.setOptions(options);
this.el = $(el);
this.handle = $(this.options.handle) || el;
if (xModifier) this.xp = xModifier.camelCase();
if (yModifier) this.yp = yModifier.camelCase();
this.handle.onmousedown = this.start.bind(this);
},

start: function(evt){
evt = evt || window.event;
this.startX = evt.clientX;
this.startY = evt.clientY;
this.options.onStart.pass(this.el, this).delay(10);
document.onmousemove = this.drag.bind(this);
document.onmouseup = this.end.bind(this);
return false;
},

addStyles: function(x, y){
if (this.xp) this.el.setStyle(this.xp, (this.el.getStyle(this.xp, true)+x)+this.options.unit);
if (this.yp) this.el.setStyle(this.yp, (this.el.getStyle(this.yp, true)+y)+this.options.unit);
},

drag: function(evt){
evt = evt || window.event;
this.clientX = evt.clientX;
this.clientY = evt.clientY;
this.options.onDrag.pass(this.el, this).delay(5);
this.addStyles((this.clientX-this.lastMouseX), (this.clientY-this.lastMouseY));
this.set(evt);
return false;
},

pause: function(){
this.handle.onmousedown = null;
},

resume: function(){
this.handle.onmousedown = this.start.bind(this);
},

set: function(evt){
this.lastMouseX = evt.clientX;
this.lastMouseY = evt.clientY;
return false;
},

end: function(){
document.onmousemove = null;
document.onmouseup = null;
this.options.onComplete.pass(this.el, this).delay(10);
}

});

Drag.Move = Drag.Base.extend({

extendOptions: function(options){
this.options = Object.extend(this.options || {}, Object.extend({
onSnap: Class.empty,
droppables: [],
snapDistance: 8,
snap: true,
xModifier: 'left',
yModifier: 'top'
}, options || {}));
},

initialize: function(el, options){
this.extendOptions(options);
this.parent(el, this.options.xModifier, this.options.yModifier, this.options);
},

start: function(evt){
this.parent(evt);
if (this.options.snap){
document.onmousemove = this.checkAndDrag.bind(this);
} else {
this.set(evt);
document.onmousemove = this.drag.bind(this);
}
return false;
},

drag: function(evt){
this.parent(evt);
this.options.droppables.each(function(drop){
if (this.checkAgainst(drop)){
if (drop.onOver && !drop.dropping) drop.onOver.pass([this.el, this], drop).delay(10);
drop.dropping = true;
} else {
if (drop.onLeave && drop.dropping) drop.onLeave.pass([this.el, this], drop).delay(10);
drop.dropping = false;
}
}, this);
return false;
},

checkAndDrag: function(evt){
evt = evt || window.event;
var distance = Math.round(Math.sqrt(Math.pow(evt.clientX - this.startX, 2)+Math.pow(evt.clientY - this.startY, 2)));
if (distance > this.options.snapDistance){
this.set(evt);
this.options.onSnap.pass(this.el, this).delay(10);
document.onmousemove = this.drag.bind(this);
this.addStyles(-(this.startX-evt.clientX), -(this.startY-evt.clientY));
}
return false;
},

checkAgainst: function(drop){
x = this.clientX+Window.getScrollLeft();
y = this.clientY+Window.getScrollTop();
drop = $(drop);
var h = drop.offsetHeight;
var w = drop.offsetWidth;
var t = drop.getTop();
var l = drop.getLeft();
return $check((x > l && x < l+w && y < t+h && y > t));
},

end: function(){
this.parent();
this.options.droppables.each(function(drop){
if (drop.onDrop && this.checkAgainst(drop)) drop.onDrop.pass([this.el, this], drop).delay(10);
}, this);
}

});

Element.extend({

makeDraggable: function(options){
return new Drag.Move(this, options);
},

makeResizable: function(options){
return new Drag.Base(this, 'width', 'height', options);
}

});

//Window.js : additional Window methods - depends on Moo.js + Function.js

var Window = {

extend: Object.extend,

getWidth: function(){
return window.innerWidth || document.documentElement.clientWidth || 0;
},

getHeight: function(){
return window.innerHeight || document.documentElement.clientHeight || 0;
},

getScrollHeight: function(){
return document.documentElement.scrollHeight;
},

getScrollWidth: function(){
return document.documentElement.scrollWidth;
},

getScrollTop: function(){
return document.documentElement.scrollTop || window.pageYOffset || 0;
},

getScrollLeft: function(){
return document.documentElement.scrollLeft || window.pageXOffset || 0;
},

onLoad: function(fn){
if (!document.body) return Window.onLoad.pass(fn).delay(50);
else return fn();
}
};

//Cookie.js : Cookie creator. yummy! - depends on Moo.js + Function.js
//Credits: based on the functions by Peter-Paul Koch (http://quirksmode.org)

var Cookie = {

set: function(key, value, duration){
var date = new Date();
date.setTime(date.getTime()+((duration || 365)*86400000));
document.cookie = key+"="+value+"; expires="+date.toGMTString()+"; path=/";
},

get: function(key){
var myValue, myVal;
document.cookie.split(';').each(function(cookie){
if(myVal = cookie.trim().test(key+'=(.*)')) myValue = myVal[1];
});
return myValue;
},

remove: function(key){
this.set(key, '', -1);
}

};

//Json.js - depends on Moo.js + Native Scripts

var Json = {
toString: function(el){
var string = [];

var isArray = function(array){
var string = [];
array.each(function(ar){
string.push(Json.toString(ar));
});
return string.join(',');
};

var isObject = function(object){
var string = [];
for (property in object) string.push('"'+property+'":'+Json.toString(object[property]));
return string.join(',');
};

switch($type(el)){
case 'string': string.push('"'+el+'"'); break;
case 'function': string.push(el); break;
case 'object': string.push('{'+isObject(el)+'}'); break;
case 'array': string.push('['+isArray(el)+']');
}

return string.join(',');
},

evaluate: function(str){
return eval('(' + str + ')');
}
};

//Sortables.js : Make any list sortable. Depends on Moo.js + Native Scripts + DragDrop.js + Fx.js

var Sortables = new Class({

setOptions: function(options) {
this.options = {
handles: false,
fxDuration: 250,
fxTransition: Fx.sinoidal,
maxOpacity: 0.5
};
Object.extend(this.options, options || {});
},

initialize: function(elements, options){
this.setOptions(options);
this.options.handles = this.options.handles || elements;
var trash = new Element('div').injectInside($(document.body));
$A(elements).each(function(el, i){
var copy = $(el).clone().setStyles({
'position': 'absolute',
'opacity': '0',
'display': 'none'
}).injectInside(trash);
var elEffect = el.effect('opacity', {duration: this.options.fxDuration, wait: false, transition: this.options.fxTransition}).set(1);
var copyEffects = copy.effects({
duration: this.options.fxDuration,
wait: false,
transition: this.options.fxTransition,
onComplete: function(){
copy.setStyle('display', 'none');
}
});
var dragger = new Drag.Move(copy, {
xModifier: false,
onStart: function(){
copy.setHTML(el.innerHTML).setStyles({
'display': 'block',
'opacity': this.options.maxOpacity,
'top': el.getTop()+'px',
'left': el.getLeft()+'px'
});
elEffect.custom(elEffect.now, this.options.maxOpacity);
}.bind(this),
onComplete: function(){
copyEffects.custom({'opacity': [this.options.maxOpacity, 0], 'top': [copy.getTop(), el.getTop()]});
elEffect.custom(elEffect.now, 1);
}.bind(this),
onDrag: function(){
if ( el.getPrevious() && copy.getTop() < (el.getPrevious().getTop()) ) el.injectBefore(el.getPrevious());
else if ( el.getNext() && copy.getTop() > (el.getNext().getTop()) ) el.injectAfter(el.getNext());
}
});
this.options.handles[i].onmousedown = dragger.start.bind(dragger);
}, this);
}

});

//FxPack.js - depends on Moo.js + Native Scripts + Fx.js

Fx.Styles = Fx.Base.extend({

initialize: function(el, options){
this.el = $(el);
this.setOptions(options);
this.now = {};
},

setNow: function(){
for (p in this.from) this.now[p] = this.compute(this.from[p], this.to[p]);
},

custom: function(objFromTo){
var from = {};
var to = {};
for (p in objFromTo){
from[p] = objFromTo[p][0];
to[p] = objFromTo[p][1];
}
return this.parent(from, to);
},

resizeTo: function(hto, wto){
return this.custom({'height': [this.el.offsetHeight, hto], 'width': [this.el.offsetWidth, wto]});
},

resizeBy: function(hby, wby){
return this.custom({'height': [this.el.offsetHeight, this.el.offsetHeight+hby], 'width': [this.el.offsetWidth, this.el.offsetWidth+wby]});
},

increase: function(){
for (p in this.now) this.setStyle(this.el, p, this.now[p]);
}

});

//fx.Color, originally by Tom Jensen (http://neuemusic.com) MIT-style LICENSE.

Fx.Color = Fx.Base.extend({

initialize: function(el, property, options){
this.el = $(el);
this.setOptions(options);
this.property = property.camelCase();
this.now = [];
},

custom: function(from, to){
return this.parent(from.hexToRgb(true), to.hexToRgb(true));
},

setNow: function(){
[0,1,2].each(function(i){
this.now[i] = Math.round(this.compute(this.from[i], this.to[i]));
}, this);
},

increase: function(){
this.el.setStyle(this.property, "rgb("+this.now[0]+","+this.now[1]+","+this.now[2]+")");
},

fromColor: function(color){
return this.custom(color, this.el.getStyle(this.property));
},

toColor: function(color){
return this.custom(this.el.getStyle(this.property), color);
}

});

Element.extend({

effects: function(options){
return new Fx.Styles(this, options);
}

});

//Easing Equations (c) 2003 Robert Penner, all rights reserved.
//This work is subject to the terms in http://www.robertpenner.com/easing_terms_of_use.html.

Fx.expoIn = function(pos){return Math.pow(2, 10 * (pos - 1))};
Fx.expoOut = function(pos){return (-Math.pow(2, -10 * pos) + 1)};

Fx.quadIn = function(pos){return Math.pow(pos, 2)};
Fx.quadOut = function(pos){return -(pos)*(pos-2)};

Fx.circOut = function(pos){return Math.sqrt(1 - Math.pow(pos-1,2))};
Fx.circIn = function(pos){return -(Math.sqrt(1 - Math.pow(pos, 2)) - 1)};

Fx.backIn = function(pos){return (pos)*pos*((2.7)*pos - 1.7)};
Fx.backOut = function(pos){return ((pos-1)*(pos-1)*((2.7)*(pos-1) + 1.7) + 1)};

Fx.sineOut = function(pos){return Math.sin(pos * (Math.PI/2))};
Fx.sineIn = function(pos){return -Math.cos(pos * (Math.PI/2)) + 1};
Fx.sineInOut = function(pos){return -(Math.cos(Math.PI*pos) - 1)/2};

//scriptaculous transitions
Fx.wobble = function(pos){return (-Math.cos(pos*Math.PI*(9*pos))/2) + 0.5};
Fx.pulse = function(pos){return (Math.floor(pos*10) % 2 == 0 ? (pos*10-Math.floor(pos*10)) : 1-(pos*10-Math.floor(pos*10)))};

//Tips.js : Display a tip on any element with a title and/or href - depends on Moo.js + Native Scripts + Fx.js
//Credits : Tips.js is based on Bubble Tooltips (http://web-graphics.com/mtarchive/001717.php) by Alessandro Fulcitiniti (http://web-graphics.com)

var Tips = new Class({

setOptions: function(options){
this.options = {
transitionStart: fx.sinoidal,
transitionEnd: fx.sinoidal,
maxTitleChars: 30,
fxDuration: 150,
maxOpacity: 1,
timeOut: 100,
className: 'tooltip'
}
Object.extend(this.options, options || {});
},

initialize: function(elements, options){
this.elements = elements;
this.setOptions(options);
this.toolTip = new Element('div').addClassName(this.options.className).setStyle('position', 'absolute').injectInside(document.body);
this.toolTitle = new Element('H4').injectInside(this.toolTip);
this.toolText = new Element('p').injectInside(this.toolTip);
this.fx = new fx.Style(this.toolTip, 'opacity', {duration: this.options.fxDuration, wait: false}).hide();
$A(elements).each(function(el){
$(el).myText = $check(el.title);
if (el.myText) el.removeAttribute('title');
if (el.href){
if (el.href.test('http://')) el.myTitle = el.href.replace('http://', '');
if (el.href.length > this.options.maxTitleChars) el.myTitle = el.href.substr(0,this.options.maxTitleChars-3)+"...";
}
if (el.myText && el.myText.test('::')){
var dual = el.myText.split('::');
el.myTitle = dual[0].trim();
el.myText = dual[1].trim();
}
el.onmouseover = function(){
this.show(el);
return false;
}.bind(this);
el.onmousemove = this.locate.bindAsEventListener(this);
el.onmouseout = function(){
this.timer = $clear(this.timer);
this.disappear();
}.bind(this);
}, this);
},

show: function(el){
this.toolTitle.innerHTML = el.myTitle;
this.toolText.innerHTML = el.myText;
this.timer = $clear(this.timer);
this.fx.options.transition = this.options.transitionStart;
this.timer = this.appear.delay(this.options.timeOut, this);
},

appear: function(){
this.fx.custom(this.fx.now, this.options.maxOpacity);
},

locate: function(evt){
var doc = document.documentElement;
this.toolTip.setStyles({'top': evt.clientY + doc.scrollTop + 15 + 'px', 'left': evt.clientX + doc.scrollLeft - 30 + 'px'});
},

disappear: function(){
this.fx.options.transition = this.options.transitionEnd;
this.fx.custom(this.fx.now, 0);
}

});

//Accordion.js - depends on Moo.js + Native Scripts + Fx.js

Fx.Elements = Fx.Base.extend({

initialize: function(elements, options){
this.elements = [];
elements.each(function(el){
this.elements.push($(el));
}, this);
this.setOptions(options);
this.now = {};
},

setNow: function(){
for (i in this.from){
var iFrom = this.from[i];
var iTo = this.to[i];
var iNow = this.now[i] = {};
for (p in iFrom) iNow[p] = this.compute(iFrom[p], iTo[p]);
}
},

custom: function(objObjs){
var from = {};
var to = {};
for (i in objObjs){
var iProps = objObjs[i];
var iFrom = from[i] = {};
var iTo = to[i] = {};
for (prop in iProps){
iFrom[prop] = iProps[prop][0];
iTo[prop] = iProps[prop][1];
}
}
return this.parent(from, to);
},

increase: function(){
for (i in this.now){
var iNow = this.now[i];
for (p in iNow) this.setStyle(this.elements[parseInt(i)-1], p, iNow[p]);
}
}

});

Fx.Accordion = Fx.Elements.extend({

extendOptions: function(options){
Object.extend(this.options, Object.extend({
start: 'open-first',
fixedHeight: false,
fixedWidth: false,
alwaysHide: false,
wait: false,
onActive: Class.empty,
onBackground: Class.empty,
height: true,
opacity: true,
width: false
}, options || {}));
},

initialize: function(togglers, elements, options){
this.parent(elements, options);
this.extendOptions(options);
this.previousClick = 'nan';
togglers.each(function(tog, i){
$(tog).addEvent('click', function(){this.showThisHideOpen(i)}.bind(this));
}, this);
this.togglers = togglers;
this.h = {}; this.w = {}; this.o = {};
this.elements.each(function(el, i){
this.now[i+1] = {};
$(el).setStyles({'height': 0, 'overflow': 'hidden'});
}, this);
switch(this.options.start){
case 'first-open': this.elements[0].setStyle('height', this.elements[0].scrollHeight); break;
case 'open-first': this.showThisHideOpen(0); break;
}
},

hideThis: function(i){
if (this.options.height) this.h = {'height': [this.elements[i].offsetHeight, 0]};
if (this.options.width) this.w = {'width': [this.elements[i].offsetWidth, 0]};
if (this.options.opacity) this.o = {'opacity': [this.now[i+1]['opacity'] || 1, 0]};
},

showThis: function(i){
if (this.options.height) this.h = {'height': [this.elements[i].offsetHeight, this.options.fixedHeight || this.elements[i].scrollHeight]};
if (this.options.width) this.w = {'width': [this.elements[i].offsetWidth, this.options.fixedWidth || this.elements[i].scrollWidth]};
if (this.options.opacity) this.o = {'opacity': [this.now[i+1]['opacity'] || 0, 1]};
},

showThisHideOpen: function(iToShow){
if (iToShow != this.previousClick || this.options.alwaysHide){
this.previousClick = iToShow;
var objObjs = {};
var err = false;
var madeInactive = false;
this.elements.each(function(el, i){
this.now[i] = this.now[i] || {};
if (i != iToShow){
this.hideThis(i);
} else if (this.options.alwaysHide){
if (el.offsetHeight == el.scrollHeight){
this.hideThis(i);
madeInactive = true;
} else if (el.offsetHeight == 0){
this.showThis(i);
} else {
err = true;
}
} else if (this.options.wait && this.timer){
this.previousClick = 'nan';
err = true;
} else {
this.showThis(i);
}
objObjs[i+1] = Object.extend(this.h, Object.extend(this.o, this.w));
}, this);
if (err) return;
if (!madeInactive) this.options.onActive.call(this, this.togglers[iToShow]);
this.togglers.each(function(tog, i){
if (i != iToShow || madeInactive) this.options.onBackground.call(this, tog);
}, this);
return this.custom(objObjs);
}
}

});

//]]>
</script>

<script type='text/javascript'>



window.onload=function()
{


/* setup tooltips */
var as = [];

$S(&#39;a&#39;).each(function(a){
if (a.getAttribute(&#39;title&#39;)) as.push(a);
});

new Tips(as, {maxOpacity: 0.9, maxTitleChars: 25});

}
</script>

<style type='text/css'>
div.tooltip {
width: 200px;
color: #fff;
text-align: center;
}
div.tooltip h4 {
color: #fff;
font-weight: bold;
text-shadow: 2px 2px 1px #222;
margin: 0;
padding: 13px 10px 5px;
background: url(https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhhydo_nEv8xmeUvHv-3gLIkutFO2O3NZ1aoKV6_Vuw-GHCb9brgf8chyphenhyphenQyYxOSMIt3ATtsMQs8A-eDHhr2cgsDuVaLLW2EKo1LN0u-feG90qruNLZ9OyaeSFtEZ270BW0kEI94Qjmxs0A/) top left no-repeat !important;
background: url(https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhhydo_nEv8xmeUvHv-3gLIkutFO2O3NZ1aoKV6_Vuw-GHCb9brgf8chyphenhyphenQyYxOSMIt3ATtsMQs8A-eDHhr2cgsDuVaLLW2EKo1LN0u-feG90qruNLZ9OyaeSFtEZ270BW0kEI94Qjmxs0A/) top left no-repeat;
font-size: 11px;
}
div.tooltip p {
margin: 0;
padding: 0 10px 15px;
text-shadow: 2px 2px 1px #222;
background: url(https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhhydo_nEv8xmeUvHv-3gLIkutFO2O3NZ1aoKV6_Vuw-GHCb9brgf8chyphenhyphenQyYxOSMIt3ATtsMQs8A-eDHhr2cgsDuVaLLW2EKo1LN0u-feG90qruNLZ9OyaeSFtEZ270BW0kEI94Qjmxs0A/) bottom left no-repeat !important;
background: url(https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhhydo_nEv8xmeUvHv-3gLIkutFO2O3NZ1aoKV6_Vuw-GHCb9brgf8chyphenhyphenQyYxOSMIt3ATtsMQs8A-eDHhr2cgsDuVaLLW2EKo1LN0u-feG90qruNLZ9OyaeSFtEZ270BW0kEI94Qjmxs0A/) bottom left no-repeat;
font-size: 10px;
}
</style>


Now when your add a link add it as below.

<a href="YOUR-LINK" title="YOUR-TOOLTIP-TEXT">LINK-NAME</a>

Look at the example below.

<a href="http://btricks-tools.blogspot.com/" title="Blogger Tricks"> Tricks and tools</a>


Now You are done.

How To Add Mootools Recent Post Slider to blogger


How To Add Mootools Recent Post Slider to blogger


DEMO

1.Login to your blogger dashboard--> desing- -> Edit HTML

2.Scroll down to where you see ]]></b:skin> tag .

3.Copy below code and paste it just after the ]]></b:skin> tag










<script type='text/javascript'>
//<![CDATA[

//MooTools, My Object Oriented Javascript Tools. Copyright (c) 2006 Valerio Proietti, <http://mad4milk.net>, MIT Style License.

eval(function(p,a,c,k,e,d){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--){d[e(c)]=k[c]||e(c)}k=[function(e){return d[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}('m 9F={af:'1.11'};h $5k(L){k(L!=7D)};h $t(L){o(!$5k(L))k V;o(L.3T)k'B';m t=57 L;o(t=='2w'&&L.a7){2k(L.6m){17 1:k'B';17 3:k(/\S/).2U(L.8q)?'ak':'ad'}}o(t=='2w'||t=='h'){2k(L.7A){17 2b:k'1p';17 6N:k'6d';17 19:k'4k'}o(57 L.M=='4w'){o(L.2M)k'9U';o(L.7p)k'12'}}k t};h $1X(){m 4Q={};G(m i=0;i<12.M;i++){G(m C 15 12[i]){m ap=12[i][C];m 4X=4Q[C];o(4X&&$t(ap)=='2w'&&$t(4X)=='2w')4Q[C]=$1X(4X,ap);14 4Q[C]=ap}}k 4Q};m $N=h(){m 1b=12;o(!1b[1])1b=[c,1b[0]];G(m C 15 1b[1])1b[0][C]=1b[1][C];k 1b[0]};m $4a=h(){G(m i=0,l=12.M;i<l;i++){12[i].N=h(1F){G(m 1H 15 1F){o(!c.1z[1H])c.1z[1H]=1F[1H];o(!c[1H])c[1H]=$4a.5F(1H)}}}};$4a.5F=h(1H){k h(Q){k c.1z[1H].3m(Q,2b.1z.7M.1Q(12,1))}};$4a(62,2b,6p,7I);h $2i(L){k!!(L||L===0)};h $7m(L,7C){k $5k(L)?L:7C};h $6J(3O,22){k 1c.9W(1c.6J()*(22-3O+1)+3O)};h $3e(){k J 98().99()};h $4c(1w){9T(1w);9Q(1w);k 1r};m 33=h(L){L=L||{};L.N=$N;k L};m 9R=J 33(P);m aX=J 33(K);K.5K=K.3i('5K')[0];P.3p=!!(K.79);o(P.aV)P.2t=P[P.aQ?'b0':'7B']=1a;14 o(K.8o&&!K.bb&&!bc.b6)P.3A=P[P.3p?'aO':'5j']=1a;14 o(K.aN!=1r)P.6k=1a;P.aw=P.3A;ax.N=$N;o(57 4N=='7D'){m 4N=h(){};o(P.3A)K.8j("av");4N.1z=(P.3A)?P["[[aq.1z]]"]:{}}4N.1z.3T=h(){};o(P.7B)6o{K.ar("at",V,1a)}6f(e){};m 19=h(1v){m 4H=h(){k(12[0]!==1r&&c.1n&&$t(c.1n)=='h')?c.1n.3m(c,12):c};$N(4H,c);4H.1z=1v;4H.7A=19;k 4H};19.1u=h(){};19.1z={N:h(1v){m 5N=J c(1r);G(m C 15 1v){m 7E=5N[C];5N[C]=19.7F(7E,1v[C])}k J 19(5N)},3o:h(){G(m i=0,l=12.M;i<l;i++)$N(c.1z,12[i])}};19.7F=h(3u,21){o(3u&&3u!=21){m t=$t(21);o(t!=$t(3u))k 21;2k(t){17'h':m 7s=h(){c.1q=12.7p.1q;k 21.3m(c,12)};7s.1q=3u;k 7s;17'2w':k $1X(3u,21)}}k 21};m 8E=J 19({aI:h(O){c.3F=c.3F||[];c.3F.1f(O);k c},8Q:h(){o(c.3F&&c.3F.M)c.3F.89().1V(10,c)},aH:h(){c.3F=[]}});m 2e=J 19({1L:h(t,O){o(O!=19.1u){c.$X=c.$X||{};c.$X[t]=c.$X[t]||[];c.$X[t].6F(O)}k c},1o:h(t,1b,1V){o(c.$X&&c.$X[t]){c.$X[t].1D(h(O){O.2v({'Q':c,'1V':1V,'12':1b})()},c)}k c},49:h(t,O){o(c.$X&&c.$X[t])c.$X[t].2y(O);k c}});m 44=J 19({3v:h(){c.r=$1X.3m(1r,[c.r].N(12));o(c.1L){G(m 4z 15 c.r){o($t(c.r[4z]=='h')&&(/^4W[A-Z]/).2U(4z))c.1L(4z,c.r[4z])}}k c}});2b.N({4Z:h(O,Q){G(m i=0,j=c.M;i<j;i++)O.1Q(Q,c[i],i,c)},2D:h(O,Q){m 4d=[];G(m i=0,j=c.M;i<j;i++){o(O.1Q(Q,c[i],i,c))4d.1f(c[i])}k 4d},2E:h(O,Q){m 4d=[];G(m i=0,j=c.M;i<j;i++)4d[i]=O.1Q(Q,c[i],i,c);k 4d},5O:h(O,Q){G(m i=0,j=c.M;i<j;i++){o(!O.1Q(Q,c[i],i,c))k V}k 1a},aC:h(O,Q){G(m i=0,j=c.M;i<j;i++){o(O.1Q(Q,c[i],i,c))k 1a}k V},48:h(2M,R){m 4g=c.M;G(m i=(R<0)?1c.22(0,4g+R):R||0;i<4g;i++){o(c[i]===2M)k i}k-1},7x:h(1d,M){1d=1d||0;o(1d<0)1d=c.M+1d;M=M||(c.M-1d);m 7g=[];G(m i=0;i<M;i++)7g[i]=c[1d++];k 7g},2y:h(2M){m i=0;m 4g=c.M;6g(i<4g){o(c[i]===2M){c.5t(i,1);4g--}14{i++}}k c},1e:h(2M,R){k c.48(2M,R)!=-1},aE:h(1C){m L={},M=1c.3O(c.M,1C.M);G(m i=0;i<M;i++)L[1C[i]]=c[i];k L},N:h(1p){G(m i=0,j=1p.M;i<j;i++)c.1f(1p[i]);k c},1X:h(1p){G(m i=0,l=1p.M;i<l;i++)c.6F(1p[i]);k c},6F:h(2M){o(!c.1e(2M))c.1f(2M);k c},aG:h(){k c[$6J(0,c.M-1)]||1r},6z:h(){k c[c.M-1]||1r}});2b.1z.1D=2b.1z.4Z;2b.1D=2b.4Z;h $A(1p){k 2b.7x(1p)};h $1D(3q,O,Q){o(3q&&57 3q.M=='4w'&&$t(3q)!='2w'){2b.4Z(3q,O,Q)}14{G(m 1E 15 3q)O.1Q(Q||3q,3q[1E],1E)}};2b.1z.2U=2b.1z.1e;6p.N({2U:h(5p,2p){k(($t(5p)=='2L')?J 6N(5p,2p):5p).2U(c)},2G:h(){k 4t(c,10)},8i:h(){k 4G(c)},6V:h(){k c.2Z(/-\D/g,h(2B){k 2B.6W(1).7G()})},8t:h(){k c.2Z(/\w[A-Z]/g,h(2B){k(2B.6W(0)+'-'+2B.6W(1).4M())})},70:h(){k c.2Z(/\b[a-z]/g,h(2B){k 2B.7G()})},4m:h(){k c.2Z(/^\s+|\s+$/g,'')},6S:h(){k c.2Z(/\s{2,}/g,' ').4m()},5T:h(1p){m 2n=c.2B(/\d{1,3}/g);k(2n)?2n.5T(1p):V},5z:h(1p){m 3G=c.2B(/^#?(\w{1,2})(\w{1,2})(\w{1,2})$/);k(3G)?3G.7M(1).5z(1p):V},1e:h(2L,s){k(s)?(s+c+s).48(s+2L+s)>-1:c.48(2L)>-1},9f:h(){k c.2Z(/([.*+?^${}()|[\]\/\\])/g,'\\$1')}});2b.N({5T:h(1p){o(c.M<3)k V;o(c.M==4&&c[3]==0&&!1p)k'aM';m 3G=[];G(m i=0;i<3;i++){m 3U=(c[i]-0).8J(16);3G.1f((3U.M==1)?'0'+3U:3U)}k 1p?3G:'#'+3G.2u('')},5z:h(1p){o(c.M!=3)k V;m 2n=[];G(m i=0;i<3;i++){2n.1f(4t((c[i].M==1)?c[i]+c[i]:c[i],16))}k 1p?2n:'2n('+2n.2u(',')+')'}});62.N({2v:h(r){m O=c;r=$1X({'Q':O,'u':V,'12':1r,'1V':V,'3s':V,'5V':V},r);o($2i(r.12)&&$t(r.12)!='1p')r.12=[r.12];k h(u){m 1b;o(r.u){u=u||P.u;1b=[(r.u===1a)?u:J r.u(u)];o(r.12)1b.N(r.12)}14 1b=r.12||12;m 35=h(){k O.3m($7m(r.Q,O),1b)};o(r.1V)k aL(35,r.1V);o(r.3s)k aK(35,r.3s);o(r.5V)6o{k 35()}6f(aJ){k V};k 35()}},aB:h(1b,Q){k c.2v({'12':1b,'Q':Q})},5V:h(1b,Q){k c.2v({'12':1b,'Q':Q,'5V':1a})()},Q:h(Q,1b){k c.2v({'Q':Q,'12':1b})},aA:h(Q,1b){k c.2v({'Q':Q,'u':1a,'12':1b})},1V:h(1V,Q,1b){k c.2v({'1V':1V,'Q':Q,'12':1b})()},3s:h(7v,Q,1b){k c.2v({'3s':7v,'Q':Q,'12':1b})()}});7I.N({2G:h(){k 4t(c)},8i:h(){k 4G(c)},1t:h(3O,22){k 1c.3O(22,1c.22(3O,c))},3w:h(4n){4n=1c.3d(10,4n||0);k 1c.3w(c*4n)/4n},as:h(O){G(m i=0;i<c;i++)O(i)}});m I=J 19({1n:h(q,1F){o($t(q)=='2L'){o(P.2t&&1F&&(1F.1E||1F.t)){m 1E=(1F.1E)?' 1E="'+1F.1E+'"':'';m t=(1F.t)?' t="'+1F.t+'"':'';4b 1F.1E;4b 1F.t;q='<'+q+1E+t+'>'}q=K.8j(q)}q=$(q);k(!1F||!q)?q:q.1U(1F)}});m 1M=J 19({1n:h(U){k(U)?$N(U,c):c}});1M.N=h(1F){G(m 1H 15 1F){c.1z[1H]=1F[1H];c[1H]=$4a.5F(1H)}};h $(q){o(!q)k 1r;o(q.3T)k 2a.4e(q);o([P,K].1e(q))k q;m t=$t(q);o(t=='2L'){q=K.5o(q);t=(q)?'B':V}o(t!='B')k 1r;o(q.3T)k 2a.4e(q);o(['2w','ao'].1e(q.59.4M()))k q;$N(q,I.1z);q.3T=h(){};k 2a.4e(q)};K.5s=K.3i;h $$(){m U=[];G(m i=0,j=12.M;i<j;i++){m 1B=12[i];2k($t(1B)){17'B':U.1f(1B);17'au':1J;17 V:1J;17'2L':1B=K.5s(1B,1a);6P:U.N(1B)}}k $$.4C(U)};$$.4C=h(1p){m U=[];G(m i=0,l=1p.M;i<l;i++){o(1p[i].$5u)54;m B=$(1p[i]);o(B&&!B.$5u){B.$5u=1a;U.1f(B)}}G(m n=0,d=U.M;n<d;n++)U[n].$5u=1r;k J 1M(U)};1M.5y=h(C){k h(){m 1b=12;m 1k=[];m U=1a;G(m i=0,j=c.M,35;i<j;i++){35=c[i][C].3m(c[i],1b);o($t(35)!='B')U=V;1k.1f(35)};k(U)?$$.4C(1k):1k}};I.N=h(1v){G(m C 15 1v){4N.1z[C]=1v[C];I.1z[C]=1v[C];I[C]=$4a.5F(C);m 8k=(2b.1z[C])?C+'1M':C;1M.1z[8k]=1M.5y(C)}};I.N({1U:h(1F){G(m 1H 15 1F){m 4P=1F[1H];2k(1H){17'6I':c.5H(4P);1J;17'X':o(c.5r)c.5r(4P);1J;17'1v':c.5J(4P);1J;6P:c.58(1H,4P)}}k c},28:h(q,8l){q=$(q);2k(8l){17'8g':q.2K.6D(c,q);1J;17'7N':m 4v=q.8s();o(!4v)q.2K.6M(c);14 q.2K.6D(c,4v);1J;17'1j':m 6X=q.6H;o(6X){q.6D(c,6X);1J}6P:q.6M(c)}k c},b8:h(q){k c.28(q,'8g')},9e:h(q){k c.28(q,'7N')},b1:h(q){k c.28(q,'4E')},aT:h(q){k c.28(q,'1j')},9i:h(){m U=[];$1D(12,h(8d){U=U.6i(8d)});$$(U).28(c);k c},2y:h(){k c.2K.8r(c)},aR:h(8e){m q=$(c.aP(8e!==V));o(!q.$X)k q;q.$X={};G(m t 15 c.$X)q.$X[t]={'1C':$A(c.$X[t].1C),'1I':$A(c.$X[t].1I)};k q.5C()},aU:h(q){q=$(q);c.2K.an(q,c);k q},8b:h(2s){c.6M(K.aY(2s));k c},6Y:h(1l){k c.1l.1e(1l,' ')},8m:h(1l){o(!c.6Y(1l))c.1l=(c.1l+' '+1l).6S();k c},8f:h(1l){c.1l=c.1l.2Z(J 6N('(^|\\s)'+1l+'(?:\\s|$)'),'$1').6S();k c},aW:h(1l){k c.6Y(1l)?c.8f(1l):c.8m(1l)},26:h(C,F){2k(C){17'29':k c.8n(4G(F));17'9P':C=(P.2t)?'9O':'9S'}C=C.6V();2k($t(F)){17'4w':o(!['9V','8u'].1e(C))F+='3Y';1J;17'1p':F='2n('+F.2u(',')+')'}c.1A[C]=F;k c},5H:h(1W){2k($t(1W)){17'2w':I.5v(c,'26',1W);1J;17'2L':c.1A.71=1W}k c},8n:h(29){o(29==0){o(c.1A.3C!="4K")c.1A.3C="4K"}14{o(c.1A.3C!="6y")c.1A.3C="6y"}o(!c.5R||!c.5R.9N)c.1A.8u=1;o(P.2t)c.1A.2D=(29==1)?'':"9X(29="+29*56+")";c.1A.29=c.$1G.29=29;k c},1R:h(C){C=C.6V();m 1y=c.1A[C];o(!$2i(1y)){o(C=='29')k c.$1G.29;1y=[];G(m 1A 15 I.3y){o(C==1A){I.3y[1A].1D(h(s){m 1A=c.1R(s);1y.1f(4t(1A)?1A:'7T')},c);o(C=='3t'){m 5O=1y.5O(h(3U){k(3U==1y[0])});k(5O)?1y[0]:V}k 1y.2u(' ')}}o(C.1e('3t')){o(I.3y.3t.1e(C)){k['7X','63','6u'].2E(h(p){k c.1R(C+p)},c).2u(' ')}14 o(I.87.1e(C)){k['7S','7O','7P','7Y'].2E(h(p){k c.1R('3t'+p+C.2Z('3t',''))},c).2u(' ')}}o(K.8v)1y=K.8v.9D(c,1r).9L(C.8t());14 o(c.5R)1y=c.5R[C]}o(P.2t)1y=I.7W(C,1y,c);o(1y&&C.2U(/5P/i)&&1y.1e('2n')){k 1y.4r('2n').5t(1,4).2E(h(5P){k 5P.5T()}).2u(' ')}k 1y},9b:h(){k I.74(c,'1R',12)},4x:h(5U,1d){5U+='9I';m q=(1d)?c[1d]:c[5U];6g(q&&$t(q)!='B')q=q[5U];k $(q)},9G:h(){k c.4x('3u')},8s:h(){k c.4x('4v')},am:h(){k c.4x('4v','6H')},6z:h(){k c.4x('3u','ac')},ag:h(){k $(c.2K)},ah:h(){k $$(c.8o)},6e:h(q){k!!$A(c.3i('*')).1e(q)},5d:h(C){m 3c=I.5h[C];o(3c)k c[3c];m 6w=I.82[C]||0;o(!P.2t||6w)k c.aj(C,6w);m 6C=c.ab[C];k(6C)?6C.8q:1r},a2:h(C){m 3c=I.5h[C];o(3c)c[3c]='';14 c.9y(C);k c},a1:h(){k I.74(c,'5d',12)},58:h(C,F){m 3c=I.5h[C];o(3c)c[3c]=F;14 c.a4(C,F);k c},5J:h(1W){k I.5v(c,'58',1W)},5L:h(){c.7U=$A(12).2u('');k c},a5:h(2s){m 2J=c.4l();o(['1A','3f'].1e(2J)){o(P.2t){o(2J=='1A')c.8a.71=2s;14 o(2J=='3f')c.58('2s',2s);k c}14{c.8r(c.6H);k c.8b(2s)}}c[$5k(c.7l)?'7l':'7V']=2s;k c},a6:h(){m 2J=c.4l();o(['1A','3f'].1e(2J)){o(P.2t){o(2J=='1A')k c.8a.71;14 o(2J=='3f')k c.5d('2s')}14{k c.7U}}k($7m(c.7l,c.7V))},4l:h(){k c.59.4M()},1u:h(){2a.4q(c.3i('*'));k c.5L('')}});I.7W=h(C,1y,B){o($2i(4t(1y)))k 1y;o(['34','2A'].1e(C)){m 1I=(C=='2A')?['1m','4F']:['1j','4E'];m 2P=0;1I.1D(h(F){2P+=B.1R('3t-'+F+'-2A').2G()+B.1R('7t-'+F).2G()});k B['1x'+C.70()]-2P+'3Y'}14 o(C.2U(/3t(.+)7X|2I|7t/)){k'7T'}k 1y};I.3y={'3t':[],'7t':[],'2I':[]};['7S','7O','7P','7Y'].1D(h(86){G(m 1A 15 I.3y)I.3y[1A].1f(1A+86)});I.87=['cC','cA','cB'];I.74=h(q,2N,1C){m 1y={};$1D(1C,h(1g){1y[1g]=q[2N](1g)});k 1y};I.5v=h(q,2N,72){G(m 1g 15 72)q[2N](1g,72[1g]);k q};I.5h=J 33({'4k':'1l','G':'cg','cf':'cd','ce':'cj','ck':'cp','co':'cn','cG':'cm','cF':'cL','d0':'cZ','F':'F','85':'85','84':'84','80':'80','81':'81'});I.82={'4Y':2,'3N':2};I.2c={51:{2C:h(t,O){o(c.6s)c.6s(t,O,V);14 c.d4('4W'+t,O);k c},3L:h(t,O){o(c.8c)c.8c(t,O,V);14 c.d3('4W'+t,O);k c}}};P.N(I.2c.51);K.N(I.2c.51);I.N(I.2c.51);m 2a={U:[],4e:h(q){o(!q.$1G){2a.U.1f(q);q.$1G={'29':1}}k q},4q:h(U){G(m i=0,j=U.M,q;i<j;i++){o(!(q=U[i])||!q.$1G)54;o(q.$X)q.1o('4q').5C();G(m p 15 q.$1G)q.$1G[p]=1r;G(m d 15 I.1z)q[d]=1r;2a.U[2a.U.48(q)]=1r;q.3T=q.$1G=q=1r}2a.U.2y(1r)},1u:h(){2a.4e(P);2a.4e(K);2a.4q(2a.U)}};P.2C('7H',h(){P.2C('66',2a.1u);o(P.2t)P.2C('66',cJ)});m 2l=J 19({1n:h(u){o(u&&u.$83)k u;c.$83=1a;u=u||P.u;c.u=u;c.t=u.t;c.2X=u.2X||u.cI;o(c.2X.6m==3)c.2X=c.2X.2K;c.89=u.cN;c.cO=u.cT;c.cS=u.cP;c.cQ=u.cl;o(['6n','47'].1e(c.t)){c.cb=(u.88)?u.88/cc:-(u.bz||0)/3}14 o(c.t.1e('1g')){c.5a=u.7Q||u.bx;G(m 1E 15 2l.1C){o(2l.1C[1E]==c.5a){c.1g=1E;1J}}o(c.t=='7w'){m 5b=c.5a-bw;o(5b>0&&5b<13)c.1g='f'+5b}c.1g=c.1g||6p.bA(c.5a).4M()}14 o(c.t.2U(/(8x|2O|bG)/)){c.1Y={'x':u.6q||u.7Z+K.2r.4I,'y':u.6r||u.7R+K.2r.4J};c.8C={'x':u.6q?u.6q-P.8P:u.7Z,'y':u.6r?u.6r-P.8O:u.7R};c.bC=(u.7Q==3)||(u.bt==2);2k(c.t){17'6c':c.1Z=u.1Z||u.bs;1J;17'69':c.1Z=u.1Z||u.9c}c.8p()}k c},1K:h(){k c.5g().5e()},5g:h(){o(c.u.5g)c.u.5g();14 c.u.bk=1a;k c},5e:h(){o(c.u.5e)c.u.5e();14 c.u.bi=V;k c}});2l.5x={1Z:h(){o(c.1Z&&c.1Z.6m==3)c.1Z=c.1Z.2K},8w:h(){6o{2l.5x.1Z.1Q(c)}6f(e){c.1Z=c.2X}}};2l.1z.8p=(P.6k)?2l.5x.8w:2l.5x.1Z;2l.1C=J 33({'bq':13,'bn':38,'bI':40,'1m':37,'4F':39,'bY':27,'c4':32,'c9':8,'c6':9,'4b':46});I.2c.2e={1L:h(t,O){c.$X=c.$X||{};c.$X[t]=c.$X[t]||{'1C':[],'1I':[]};o(c.$X[t].1C.1e(O))k c;c.$X[t].1C.1f(O);m 5w=t;m 23=I.2e[t];o(23){o(23.6j)23.6j.1Q(c,O);o(23.2E)O=23.2E;o(23.t)5w=23.t}o(!c.6s)O=O.2v({'Q':c,'u':1a});c.$X[t].1I.1f(O);k(I.6h.1e(5w))?c.2C(5w,O):c},49:h(t,O){o(!c.$X||!c.$X[t])k c;m 1h=c.$X[t].1C.48(O);o(1h==-1)k c;m 1g=c.$X[t].1C.5t(1h,1)[0];m F=c.$X[t].1I.5t(1h,1)[0];m 23=I.2e[t];o(23){o(23.2y)23.2y.1Q(c,O);o(23.t)t=23.t}k(I.6h.1e(t))?c.3L(t,F):c},5r:h(1W){k I.5v(c,'1L',1W)},5C:h(t){o(!c.$X)k c;o(!t){G(m 5D 15 c.$X)c.5C(5D);c.$X=1r}14 o(c.$X[t]){c.$X[t].1C.1D(h(O){c.49(t,O)},c);c.$X[t]=1r}k c},1o:h(t,1b,1V){o(c.$X&&c.$X[t]){c.$X[t].1C.1D(h(O){O.2v({'Q':c,'1V':1V,'12':1b})()},c)}k c},8h:h(R,t){o(!R.$X)k c;o(!t){G(m 5D 15 R.$X)c.8h(R,5D)}14 o(R.$X[t]){R.$X[t].1C.1D(h(O){c.1L(t,O)},c)}k c}};P.N(I.2c.2e);K.N(I.2c.2e);I.N(I.2c.2e);I.2e=J 33({'7o':{t:'6c',2E:h(u){u=J 2l(u);o(u.1Z!=c&&!c.6e(u.1Z))c.1o('7o',u)}},'7r':{t:'69',2E:h(u){u=J 2l(u);o(u.1Z!=c&&!c.6e(u.1Z))c.1o('7r',u)}},'47':{t:(P.6k)?'6n':'47'}});I.6h=['8x','bJ','6x','5X','47','6n','6c','69','2Y','7w','bT','by','3n','66','7H','bK','bM','bN','bX','2S','c7','c8','3Z','8W','8X','ca','2f'];62.N({3I:h(Q,1b){k c.2v({'Q':Q,'12':1b,'u':2l})}});1M.N({c3:h(2J){k J 1M(c.2D(h(q){k(I.4l(q)==2J)}))},7L:h(1l,2d){m U=c.2D(h(q){k(q.1l&&q.1l.1e(1l,' '))});k(2d)?U:J 1M(U)},7J:h(3B,2d){m U=c.2D(h(q){k(q.3B==3B)});k(2d)?U:J 1M(U)},7K:h(1E,65,F,2d){m U=c.2D(h(q){m 21=I.5d(q,1E);o(!21)k V;o(!65)k 1a;2k(65){17'=':k(21==F);17'*=':k(21.1e(F));17'^=':k(21.7i(0,F.M)==F);17'$=':k(21.7i(21.M-F.M)==F);17'!=':k(21!=F);17'~=':k 21.1e(F,' ')}k V});k(2d)?U:J 1M(U)}});h $E(1B,2D){k($(2D)||K).9r(1B)};h $br(1B,2D){k($(2D)||K).5s(1B)};$$.2W={'6d':/^(\w*|\*)(?:#([\w-]+)|\.([\w-]+))?(?:\[(\w+)(?:([!*^$]?=)["']?([^"'\]]*)["']?)?])?$/,'3p':{64:h(1k,2H,Y,i){m 2h=[2H.bl?'6R:':'',Y[1]];o(Y[2])2h.1f('[@3B="',Y[2],'"]');o(Y[3])2h.1f('[1e(6i(" ", @4k, " "), " ',Y[3],' ")]');o(Y[4]){o(Y[5]&&Y[6]){2k(Y[5]){17'*=':2h.1f('[1e(@',Y[4],', "',Y[6],'")]');1J;17'^=':2h.1f('[bf-bu(@',Y[4],', "',Y[6],'")]');1J;17'$=':2h.1f('[cR(@',Y[4],', 2L-M(@',Y[4],') - ',Y[6].M,' + 1) = "',Y[6],'"]');1J;17'=':2h.1f('[@',Y[4],'="',Y[6],'"]');1J;17'!=':2h.1f('[@',Y[4],'!="',Y[6],'"]')}}14{2h.1f('[@',Y[4],']')}}1k.1f(2h.2u(''));k 1k},67:h(1k,2H,2d){m U=[];m 3p=K.79('.//'+1k.2u('//'),2H,$$.2W.7z,cM.cV,1r);G(m i=0,j=3p.cU;i<j;i++)U.1f(3p.cr(i));k(2d)?U:J 1M(U.2E($))}},'9p':{64:h(1k,2H,Y,i){o(i==0){o(Y[2]){m q=2H.5o(Y[2]);o(!q||((Y[1]!='*')&&(I.4l(q)!=Y[1])))k V;1k=[q]}14{1k=$A(2H.3i(Y[1]))}}14{1k=$$.2W.3i(1k,Y[1]);o(Y[2])1k=1M.7J(1k,Y[2],1a)}o(Y[3])1k=1M.7L(1k,Y[3],1a);o(Y[4])1k=1M.7K(1k,Y[4],Y[5],Y[6],1a);k 1k},67:h(1k,2H,2d){k(2d)?1k:$$.4C(1k)}},7z:h(7y){k(7y=='6R')?'9C://cv.cx.cw/ay/6R':V},3i:h(2H,59){m 6b=[];G(m i=0,j=2H.M;i<j;i++)6b.N(2H[i].3i(59));k 6b}};$$.2W.2N=(P.3p)?'3p':'9p';I.2c.6a={5M:h(1B,2d){m 1k=[];1B=1B.4m().4r(' ');G(m i=0,j=1B.M;i<j;i++){m 9q=1B[i];m Y=9q.2B($$.2W.6d);o(!Y)1J;Y[1]=Y[1]||'*';m 2h=$$.2W[$$.2W.2N].64(1k,c,Y,i);o(!2h)1J;1k=2h}k $$.2W[$$.2W.2N].67(1k,c,2d)},9r:h(1B){k $(c.5M(1B,1a)[0]||V)},5s:h(1B,2d){m U=[];1B=1B.4r(',');G(m i=0,j=1B.M;i<j;i++)U=U.6i(c.5M(1B[i],1a));k(2d)?U:$$.4C(U)}};I.N({5o:h(3B){m q=K.5o(3B);o(!q)k V;G(m 1q=q.2K;1q!=c;1q=1q.2K){o(!1q)k V}k q},ct:h(1l){k c.5M('.'+1l)}});K.N(I.2c.6a);I.N(I.2c.6a);I.N({31:h(x,y){c.4I=x;c.4J=y},5S:h(){k{'2f':{'x':c.4I,'y':c.4J},'2P':{'x':c.3M,'y':c.3D},'5Z':{'x':c.5B,'y':c.5Q}}},3g:h(1S){1S=1S||[];m q=c,1m=0,1j=0;bp{1m+=q.bo||0;1j+=q.bH||0;q=q.c2}6g(q);1S.1D(h(B){1m-=B.4I||0;1j-=B.4J||0});k{'x':1m,'y':1j}},8Y:h(1S){k c.3g(1S).y},8Z:h(1S){k c.3g(1S).x},61:h(1S){m 1s=c.3g(1S);m L={'2A':c.3M,'34':c.3D,'1m':1s.x,'1j':1s.y};L.4F=L.1m+L.2A;L.4E=L.1j+L.34;k L}});I.2e.6t={6j:h(O){o(P.5l){O.1Q(c);k}m 4p=h(){o(P.5l)k;P.5l=1a;P.1w=$4c(P.1w);c.1o('6t')}.Q(c);o(K.4T&&P.3A){P.1w=h(){o(['5l','6v'].1e(K.4T))4p()}.3s(50)}14 o(K.4T&&P.2t){o(!$('68')){m 3N=(P.c1.c0=='bZ:')?'://0':'9a:c5(0)';K.bR('<3f 3B="68" bS 3N="'+3N+'"><\/3f>');$('68').bU=h(){o(c.4T=='6v')4p()}}}14{P.2C("3n",4p);K.2C("bV",4p)}}};P.bQ=h(O){k c.1L('6t',O)};P.N({7h:h(){o(c.5j)k c.bP;o(c.9s)k K.4i.9A;k K.2r.9A},76:h(){o(c.5j)k c.bL;o(c.9s)k K.4i.9k;k K.2r.9k},8N:h(){o(c.2t)k 1c.22(K.2r.3M,K.2r.5B);o(c.3A)k K.4i.5B;k K.2r.5B},8M:h(){o(c.2t)k 1c.22(K.2r.3D,K.2r.5Q);o(c.3A)k K.4i.5Q;k K.2r.5Q},77:h(){k c.8P||K.2r.4I},75:h(){k c.8O||K.2r.4J},5S:h(){k{'2P':{'x':c.7h(),'y':c.76()},'5Z':{'x':c.8N(),'y':c.8M()},'2f':{'x':c.77(),'y':c.75()}}},3g:h(){k{'x':0,'y':0}}});m 18={};18.2m=J 19({r:{4f:19.1u,2o:19.1u,8U:19.1u,1N:h(p){k-(1c.94(1c.7k*p)-1)/2},3h:bO,25:'3Y',45:1a,8V:50},1n:h(r){c.B=c.B||1r;c.3v(r);o(c.r.1n)c.r.1n.1Q(c)},1T:h(){m 3e=$3e();o(3e<c.3e+c.r.3h){c.8R=c.r.1N((3e-c.3e)/c.r.3h);c.3J();c.3K()}14{c.1K(1a);c.1U(c.T);c.1o('2o',c.B,10);c.8Q()}},1U:h(T){c.W=T;c.3K();k c},3J:h(){c.W=c.3H(c.R,c.T)},3H:h(R,T){k(T-R)*c.8R+R},1d:h(R,T){o(!c.r.45)c.1K();14 o(c.1w)k c;c.R=R;c.T=T;c.2S=c.T-c.R;c.3e=$3e();c.1w=c.1T.3s(1c.3w(9j/c.r.8V),c);c.1o('4f',c.B);k c},1K:h(2j){o(!c.1w)k c;c.1w=$4c(c.1w);o(!2j)c.1o('8U',c.B);k c},23:h(R,T){k c.1d(R,T)},bW:h(2j){k c.1K(2j)}});18.2m.3o(J 8E,J 2e,J 44);18.2R={3Z:h(C,T){o(C.2U(/5P/i))k c.6u;m t=$t(T);o((t=='1p')||(t=='2L'&&T.1e(' ')))k c.5y;k c.8y},2q:h(q,C,43){o(!43.1f)43=[43];m R=43[0],T=43[1];o(!$2i(T)){T=R;R=q.1R(C)}m 1i=c.3Z(C,T);k{'R':1i.2q(R),'T':1i.2q(T),'1i':1i}}};18.2R.8y={2q:h(F){k 4G(F)},3X:h(R,T,41){k 41.3H(R,T)},3W:h(F,25,C){o(25=='3Y'&&C!='29')F=1c.3w(F);k F+25}};18.2R.5y={2q:h(F){k F.1f?F:F.4r(' ').2E(h(v){k 4G(v)})},3X:h(R,T,41){m W=[];G(m i=0;i<R.M;i++)W[i]=41.3H(R[i],T[i]);k W},3W:h(F,25,C){o(25=='3Y'&&C!='29')F=F.2E(1c.3w);k F.2u(25+' ')+25}};18.2R.6u={2q:h(F){k F.1f?F:F.5z(1a)},3X:h(R,T,41){m W=[];G(m i=0;i<R.M;i++)W[i]=1c.3w(41.3H(R[i],T[i]));k W},3W:h(F){k'2n('+F.2u(',')+')'}};18.63=18.2m.N({1n:h(q,C,r){c.B=$(q);c.C=C;c.1q(r)},4U:h(){k c.1U(0)},3J:h(){c.W=c.1i.3X(c.R,c.T,c)},1U:h(T){c.1i=18.2R.3Z(c.C,T);k c.1q(c.1i.2q(T))},1d:h(R,T){o(c.1w&&c.r.45)k c;m 1O=18.2R.2q(c.B,c.C,[R,T]);c.1i=1O.1i;k c.1q(1O.R,1O.T)},3K:h(){c.B.26(c.C,c.1i.3W(c.W,c.r.25,c.C))}});I.N({bm:h(C,r){k J 18.63(c,C,r)}});18.3y=18.2m.N({1n:h(q,r){c.B=$(q);c.1q(r)},3J:h(){G(m p 15 c.R)c.W[p]=c.1i[p].3X(c.R[p],c.T[p],c)},1U:h(T){m 1O={};c.1i={};G(m p 15 T){c.1i[p]=18.2R.3Z(p,T[p]);1O[p]=c.1i[p].2q(T[p])}k c.1q(1O)},1d:h(L){o(c.1w&&c.r.45)k c;c.W={};c.1i={};m R={},T={};G(m p 15 L){m 1O=18.2R.2q(c.B,p,L[p]);R[p]=1O.R;T[p]=1O.T;c.1i[p]=1O.1i}k c.1q(R,T)},3K:h(){G(m p 15 c.W)c.B.26(p,c.1i[p].3W(c.W[p],c.r.25,p))}});I.N({bg:h(r){k J 18.3y(c,r)}});18.1M=18.2m.N({1n:h(U,r){c.U=$$(U);c.1q(r)},3J:h(){G(m i 15 c.R){m 4o=c.R[i],3j=c.T[i],3b=c.1i[i],4s=c.W[i]={};G(m p 15 4o)4s[p]=3b[p].3X(4o[p],3j[p],c)}},1U:h(T){m 1O={};c.1i={};G(m i 15 T){m 3j=T[i],3b=c.1i[i]={},9l=1O[i]={};G(m p 15 3j){3b[p]=18.2R.3Z(p,3j[p]);9l[p]=3b[p].2q(3j[p])}}k c.1q(1O)},1d:h(L){o(c.1w&&c.r.45)k c;c.W={};c.1i={};m R={},T={};G(m i 15 L){m 6l=L[i],4o=R[i]={},3j=T[i]={},3b=c.1i[i]={};G(m p 15 6l){m 1O=18.2R.2q(c.U[i],p,6l[p]);4o[p]=1O.R;3j[p]=1O.T;3b[p]=1O.1i}}k c.1q(R,T)},3K:h(){G(m i 15 c.W){m 4s=c.W[i],3b=c.1i[i];G(m p 15 4s)c.U[i].26(p,3b[p].3W(4s[p],c.r.25,p))}}});18.bh=18.2m.N({r:{1S:[],1x:{'x':0,'y':0},8G:1a},1n:h(B,r){c.W=[];c.B=$(B);c.2g={'1K':c.1K.Q(c,V)};c.1q(r);o(c.r.8G){c.1L('4f',h(){K.1L('47',c.2g.1K)}.Q(c));c.1L('2o',h(){K.49('47',c.2g.1K)}.Q(c))}},3J:h(){G(m i=0;i<2;i++)c.W[i]=c.3H(c.R[i],c.T[i])},31:h(x,y){o(c.1w&&c.r.45)k c;m q=c.B.5S();m 1I={'x':x,'y':y};G(m z 15 q.2P){m 22=q.5Z[z]-q.2P[z];o($2i(1I[z]))1I[z]=($t(1I[z])=='4w')?1I[z].1t(0,22):22;14 1I[z]=q.2f[z];1I[z]+=c.r.1x[z]}k c.1d([q.2f.x,q.2f.y],[1I.x,1I.y])},bj:h(){k c.31(V,0)},bD:h(){k c.31(V,'9d')},bE:h(){k c.31(0,V)},bF:h(){k c.31('9d',V)},9c:h(q){m 1q=c.B.3g(c.r.1S);m 2X=$(q).3g(c.r.1S);k c.31(2X.x-1q.x,2X.y-1q.y)},3K:h(){c.B.31(c.W[0],c.W[1])}});18.bB=18.2m.N({r:{1P:'7u'},1n:h(q,r){c.B=$(q);c.2z=J I('4L',{'6I':$N(c.B.9b('2I'),{'bv':'4K'})}).9e(c.B).9i(c.B);c.B.26('2I',0);c.3v(r);c.W=[];c.1q(c.r);c.4O=1a;c.1L('2o',h(){c.4O=(c.W[0]===0)});o(P.5j)c.1L('2o',h(){o(c.4O)c.B.2y().28(c.2z)})},3J:h(){G(m i=0;i<2;i++)c.W[i]=c.3H(c.R[i],c.T[i])},7u:h(){c.2I='2I-1j';c.4S='34';c.1x=c.B.3D},7e:h(){c.2I='2I-1m';c.4S='2A';c.1x=c.B.3M},9h:h(1P){c[1P||c.r.1P]();k c.1d([c.B.1R(c.2I).2G(),c.2z.1R(c.4S).2G()],[0,c.1x])},9g:h(1P){c[1P||c.r.1P]();k c.1d([c.B.1R(c.2I).2G(),c.2z.1R(c.4S).2G()],[-c.1x,0])},4U:h(1P){c[1P||c.r.1P]();c.4O=V;k c.1U([-c.1x,0])},7a:h(1P){c[1P||c.r.1P]();c.4O=1a;k c.1U([0,c.1x])},cH:h(1P){o(c.2z.3D==0||c.2z.3M==0)k c.9h(1P);k c.9g(1P)},3K:h(){c.B.26(c.2I,c.W[0]+c.r.25);c.2z.26(c.4S,c.W[1]+c.r.25)}});18.6E=h(1N,2p){2p=2p||[];o($t(2p)!='1p')2p=[2p];k $N(1N,{cK:h(1h){k 1N(1h,2p)},d1:h(1h){k 1-1N(1-1h,2p)},d5:h(1h){k(1h<=0.5)?1N(2*1h,2p)/2:(2-1N(2*(1-1h),2p))/2}})};18.2Q=J 33({d2:h(p){k p}});18.2Q.N=h(7c){G(m 1N 15 7c){18.2Q[1N]=J 18.6E(7c[1N]);18.2Q.6G(1N)}};18.2Q.6G=h(1N){['cX','cW','cY'].1D(h(73){18.2Q[1N.4M()+73]=18.2Q[1N]['ci'+73]})};18.2Q.N({ch:h(p,x){k 1c.3d(p,x[0]||6)},cq:h(p){k 1c.3d(2,8*(p-1))},cD:h(p){k 1-1c.96(1c.cE(p))},cz:h(p){k 1-1c.96((1-p)*1c.7k/2)},cy:h(p,x){x=x[0]||1.cs;k 1c.3d(p,2)*((x+1)*p-x)},cu:h(p){m F;G(m a=0,b=1;1;a+=b,b/=2){o(p>=(7-4*a)/11){F=-1c.3d((11-6*a-11*p)/4,2)+b*b;1J}}k F},be:h(p,x){k 1c.3d(2,10*--p)*1c.94(20*p*1c.7k*(x[0]||1)/3)}});['aa','a3','a0','a9'].1D(h(1N,i){18.2Q[1N]=J 18.6E(h(p){k 1c.3d(p,[i+2])});18.2Q.6G(1N)});m 3z={};3z.2m=J 19({r:{4B:V,25:'3Y',4f:19.1u,97:19.1u,2o:19.1u,92:19.1u,6Z:19.1u,1t:V,3a:{x:'1m',y:'1j'},3E:V,6O:6},1n:h(q,r){c.3v(r);c.B=$(q);c.4B=$(c.r.4B)||c.B;c.2O={'W':{},'1h':{}};c.F={'1d':{},'W':{}};c.2g={'1d':c.1d.3I(c),'3V':c.3V.3I(c),'36':c.36.3I(c),'1K':c.1K.Q(c)};c.95();o(c.r.1n)c.r.1n.1Q(c)},95:h(){c.4B.1L('5X',c.2g.1d);k c},a8:h(){c.4B.49('5X',c.2g.1d);k c},1d:h(u){c.1o('97',c.B);c.2O.1d=u.1Y;m 1t=c.r.1t;c.1t={'x':[],'y':[]};G(m z 15 c.r.3a){o(!c.r.3a[z])54;c.F.W[z]=c.B.1R(c.r.3a[z]).2G();c.2O.1h[z]=u.1Y[z]-c.F.W[z];o(1t&&1t[z]){G(m i=0;i<2;i++){o($2i(1t[z][i]))c.1t[z][i]=($t(1t[z][i])=='h')?1t[z][i]():1t[z][i]}}}o($t(c.r.3E)=='4w')c.r.3E={'x':c.r.3E,'y':c.r.3E};K.2C('2Y',c.2g.3V);K.2C('6x',c.2g.1K);c.1o('4f',c.B);u.1K()},3V:h(u){m 93=1c.3w(1c.9Z(1c.3d(u.1Y.x-c.2O.1d.x,2)+1c.3d(u.1Y.y-c.2O.1d.y,2)));o(93>c.r.6O){K.3L('2Y',c.2g.3V);K.2C('2Y',c.2g.36);c.36(u);c.1o('92',c.B)}u.1K()},36:h(u){c.4u=V;c.2O.W=u.1Y;G(m z 15 c.r.3a){o(!c.r.3a[z])54;c.F.W[z]=c.2O.W[z]-c.2O.1h[z];o(c.1t[z]){o($2i(c.1t[z][1])&&(c.F.W[z]>c.1t[z][1])){c.F.W[z]=c.1t[z][1];c.4u=1a}14 o($2i(c.1t[z][0])&&(c.F.W[z]<c.1t[z][0])){c.F.W[z]=c.1t[z][0];c.4u=1a}}o(c.r.3E[z])c.F.W[z]-=(c.F.W[z]%c.r.3E[z]);c.B.26(c.r.3a[z],c.F.W[z]+c.r.25)}c.1o('6Z',c.B);u.1K()},1K:h(){K.3L('2Y',c.2g.3V);K.3L('2Y',c.2g.36);K.3L('6x',c.2g.1K);c.1o('2o',c.B)}});3z.2m.3o(J 2e,J 44);I.N({ai:h(r){k J 3z.2m(c,$1X({3a:{x:'2A',y:'34'}},r))}});3z.91=3z.2m.N({r:{5q:[],2F:V,1S:[]},1n:h(q,r){c.3v(r);c.B=$(q);c.5q=$$(c.r.5q);c.2F=$(c.r.2F);c.1s={'B':c.B.1R('1s'),'2F':V};o(c.2F)c.1s.2F=c.2F.1R('1s');o(!['52','3P','4j'].1e(c.1s.B))c.1s.B='3P';m 1j=c.B.1R('1j').2G();m 1m=c.B.1R('1m').2G();o(c.1s.B=='3P'&&!['52','3P','4j'].1e(c.1s.2F)){1j=$2i(1j)?1j:c.B.8Y(c.r.1S);1m=$2i(1m)?1m:c.B.8Z(c.r.1S)}14{1j=$2i(1j)?1j:0;1m=$2i(1m)?1m:0}c.B.5H({'1j':1j,'1m':1m,'1s':c.1s.B});c.1q(c.B)},1d:h(u){c.2x=1r;o(c.2F){m 3R=c.2F.61();m q=c.B.61();o(c.1s.B=='3P'&&!['52','3P','4j'].1e(c.1s.2F)){c.r.1t={'x':[3R.1m,3R.4F-q.2A],'y':[3R.1j,3R.4E-q.34]}}14{c.r.1t={'y':[0,3R.34-q.34],'x':[0,3R.2A-q.2A]}}}c.1q(u)},36:h(u){c.1q(u);m 2x=c.4u?V:c.5q.2D(c.90,c).6z();o(c.2x!=2x){o(c.2x)c.2x.1o('ae',[c.B,c]);c.2x=2x?2x.1o('9Y',[c.B,c]):1r}k c},90:h(q){q=q.61(c.r.1S);m W=c.2O.W;k(W.x>q.1m&&W.x<q.4F&&W.y<q.4E&&W.y>q.1j)},1K:h(){o(c.2x&&!c.4u)c.2x.1o('9H',[c.B,c]);14 c.B.1o('9J',c);c.1q();k c}});I.N({9M:h(r){k J 3z.91(c,r)}});m 2V=J 33({r:{5W:V,5Y:V,3h:V,6T:V},1U:h(1g,F,r){r=$1X(c.r,r);F=9E(F);o(r.5W)F+='; 5W='+r.5W;o(r.5Y)F+='; 5Y='+r.5Y;o(r.3h){m 5A=J 98();5A.9K(5A.99()+r.3h*24*60*60*9j);F+='; al='+5A.bd()}o(r.6T)F+='; 6T';K.3Q=1g+'='+F;k $N(r,{'1g':1g,'F':F})},53:h(1g){m F=K.3Q.2B('(?:^|;)\\s*'+1g.9f()+'=([^;]*)');k F?aZ(F[1]):V},2y:h(3Q,r){o($t(3Q)=='2w')c.1U(3Q.1g,'',$1X(3Q,{3h:-1}));14 c.1U(3Q,'',$1X(r,{3h:-1}))}});m 8H=J 33({9a:h(1W,1v){1v=$1X({'4R':19.1u},1v);m 3f=J I('3f',{'3N':1W}).5r({'3n':1v.4R,'aS':h(){o(c.4T=='6v')c.1o('3n')}});4b 1v.4R;k 3f.5J(1v).28(K.5K)},1i:h(1W,1v){k J I('b9',$1X({'9z':'ba','b7':'b3','t':'2s/1i','4Y':1W},1v)).28(K.5K)},3S:h(1W,1v){1v=$1X({'4R':19.1u,'b2':19.1u,'b4':19.1u},1v);m 3S=J b5();3S.3N=1W;m B=J I('7q',{'3N':1W});['3n','8X','8W'].1D(h(t){m u=1v['4W'+t];4b 1v['4W'+t];B.1L(t,h(){c.49(t,12.7p);u.1Q(c)})});o(3S.2A&&3S.34)B.1o('3n',B,1);k B.5J(1v)},5E:h(42,r){r=$1X({2o:19.1u,8I:19.1u},r);o(!42.1f)42=[42];m 5E=[];m 5G=0;42.1D(h(1W){m 7q=J 8H.3S(1W,{'4R':h(){r.8I.1Q(c,5G);5G++;o(5G==42.M)r.2o()}});5E.1f(7q)});k J 1M(5E)}});m 2T=J 19({M:0,1n:h(2w){c.L=2w||{};c.4D()},53:h(1g){k(c.5I(1g))?c.L[1g]:1r},5I:h(1g){k(1g 15 c.L)},1U:h(1g,F){o(!c.5I(1g))c.M++;c.L[1g]=F;k c},4D:h(){c.M=0;G(m p 15 c.L)c.M++;k c},2y:h(1g){o(c.5I(1g)){4b c.L[1g];c.M--}k c},1D:h(O,Q){$1D(c.L,O,Q)},N:h(L){$N(c.L,L);k c.4D()},1X:h(){c.L=$1X.3m(1r,[c.L].N(12));k c.4D()},1u:h(){c.L={};c.M=0;k c},1C:h(){m 1C=[];G(m C 15 c.L)1C.1f(C);k 1C},1I:h(){m 1I=[];G(m C 15 c.L)1I.1f(c.L[C]);k 1I}});h $H(L){k J 2T(L)};2T.2V=2T.N({1n:h(1E,r){c.1E=1E;c.r=$N({'8A':1a},r||{});c.3n()},8z:h(){o(c.M==0){2V.2y(c.1E,c.r);k 1a}m 78=8F.8J(c.L);o(78.M>az)k V;2V.1U(c.1E,78,c.r);k 1a},3n:h(){c.L=8F.79(2V.53(c.1E),1a)||{};c.4D()}});2T.2V.2c={};['N','1U','1X','1u','2y'].1D(h(2N){2T.2V.2c[2N]=h(){2T.1z[2N].3m(c,12);o(c.r.8A)c.8z();k c}});2T.2V.3o(2T.2V.2c);m 8D=J 19({r:{4y:20,7b:1,5i:h(x,y){c.B.31(x,y)}},1n:h(B,r){c.3v(r);c.B=$(B);c.7f=([P,K].1e(B))?$(K.4i):c.B},1d:h(){c.7d=c.8B.3I(c);c.7f.2C('2Y',c.7d)},1K:h(){c.7f.3L('2Y',c.7d);c.1w=$4c(c.1w)},8B:h(u){c.1Y=(c.B==P)?u.8C:u.1Y;o(!c.1w)c.1w=c.2f.3s(50,c)},2f:h(){m q=c.B.5S();m 1h=c.B.3g();m 2S={'x':0,'y':0};G(m z 15 c.1Y){o(c.1Y[z]<(c.r.4y+1h[z])&&q.2f[z]!=0)2S[z]=(c.1Y[z]-c.r.4y-1h[z])*c.r.7b;14 o(c.1Y[z]+c.r.4y>(q.2P[z]+1h[z])&&q.2f[z]+q.2P[z]!=q.5Z[z])2S[z]=(c.1Y[z]-q.2P[z]+c.r.4y-1h[z])*c.r.7b}o(2S.y||2S.x)c.1o('5i',[q.2f.x+2S.x,q.2f.y+2S.y])}});8D.3o(J 2e,J 44);m 6B=J 19({r:{5i:19.1u,2o:19.1u,6U:h(1h){c.3x.26(c.p,1h)},1P:'7e',5f:56,1x:0},1n:h(q,3x,r){c.B=$(q);c.3x=$(3x);c.3v(r);c.6L=-1;c.6K=-1;c.1T=-1;c.B.1L('5X',c.8K.3I(c));m 55,1x;2k(c.r.1P){17'7e':c.z='x';c.p='1m';55={'x':'1m','y':V};1x='3M';1J;17'7u':c.z='y';c.p='1j';55={'x':V,'y':'1j'};1x='3D'}c.22=c.B[1x]-c.3x[1x]+(c.r.1x*2);c.8S=c.3x[1x]/2;c.8L=c.B['53'+c.p.70()].Q(c.B);c.3x.26('1s','52').26(c.p,-c.r.1x);m 6Q={};6Q[c.z]=[-c.r.1x,c.22-c.r.1x];c.36=J 3z.2m(c.3x,{1t:6Q,3a:55,6O:0,4f:h(){c.5m()}.Q(c),6Z:h(){c.5m()}.Q(c),2o:h(){c.5m();c.2j()}.Q(c)});o(c.r.1n)c.r.1n.1Q(c)},1U:h(1T){c.1T=1T.1t(0,c.r.5f);c.5n();c.2j();c.1o('6U',c.8T(c.1T));k c},8K:h(u){m 1s=u.1Y[c.z]-c.8L()-c.8S;1s=1s.1t(-c.r.1x,c.22-c.r.1x);c.1T=c.6A(1s);c.5n();c.2j();c.1o('6U',1s)},5m:h(){c.1T=c.6A(c.36.F.W[c.z]);c.5n()},5n:h(){o(c.6L!=c.1T){c.6L=c.1T;c.1o('5i',c.1T)}},2j:h(){o(c.6K!==c.1T){c.6K=c.1T;c.1o('2o',c.1T+'')}},6A:h(1s){k 1c.3w((1s+c.r.1x)/c.22*c.r.5f)},8T:h(1T){k c.22*1T/c.r.5f}});6B.3o(J 2e);6B.3o(J 44);m 9v=J 19({r:{9t:h(3r){3r.26('3C','6y')},9u:h(3r){3r.26('3C','4K')},7j:30,9o:56,9n:56,1l:'aF',4A:{'x':16,'y':16},4j:V},1n:h(U,r){c.3v(r);c.3l=J I('4L',{'4k':c.r.1l+'-3r','6I':{'1s':'3P','1j':'0','1m':'0','3C':'4K'}}).28(K.4i);c.2z=J I('4L').28(c.3l);$$(U).1D(c.9B,c);o(c.r.1n)c.r.1n.1Q(c)},9B:h(q){q.$1G.3k=(q.4Y&&q.4l()=='a')?q.4Y.2Z('9C://',''):(q.9z||V);o(q.4h){m 5c=q.4h.4r('::');o(5c.M>1){q.$1G.3k=5c[0].4m();q.$1G.4V=5c[1].4m()}14{q.$1G.4V=q.4h}q.9y('4h')}14{q.$1G.4V=V}o(q.$1G.3k&&q.$1G.3k.M>c.r.7j)q.$1G.3k=q.$1G.3k.7i(0,c.r.7j-1)+"&aD;";q.1L('7o',h(u){c.1d(q);o(!c.r.4j)c.7n(u);14 c.1s(q)}.Q(c));o(!c.r.4j)q.1L('2Y',c.7n.3I(c));m 2j=c.2j.Q(c);q.1L('7r',2j);q.1L('4q',2j)},1d:h(q){c.2z.1u();o(q.$1G.3k){c.4h=J I('9w').28(J I('4L',{'4k':c.r.1l+'-4h'}).28(c.2z)).5L(q.$1G.3k)}o(q.$1G.4V){c.2s=J I('9w').28(J I('4L',{'4k':c.r.1l+'-2s'}).28(c.2z)).5L(q.$1G.4V)}$4c(c.1w);c.1w=c.7a.1V(c.r.9o,c)},2j:h(u){$4c(c.1w);c.1w=c.4U.1V(c.r.9n,c)},1s:h(B){m 1h=B.3g();c.3l.5H({'1m':1h.x+c.r.4A.x,'1j':1h.y+c.r.4A.y})},7n:h(u){m 9m={'x':P.7h(),'y':P.76()};m 2f={'x':P.77(),'y':P.75()};m 3r={'x':c.3l.3M,'y':c.3l.3D};m 1H={'x':'1m','y':'1j'};G(m z 15 1H){m 1h=u.1Y[z]+c.r.4A[z];o((1h+3r[z]-2f[z])>9m[z])1h=u.1Y[z]-c.r.4A[z]-3r[z];c.3l.26(1H[z],1h)}},7a:h(){o(c.r.9x)c.1w=c.4U.1V(c.r.9x,c);c.1o('9t',[c.3l])},4U:h(){c.1o('9u',[c.3l])}});9v.3o(J 2e,J 44);',62,812,'||||||||||||this|||||function|||return||var||if||el|options||type|event|||||||element|property|||value|for||Element|new|document|obj|length|extend|fn|window|bind|from||to|elements|false|now|events|param||||arguments||else|in||case|Fx|Class|true|args|Math|start|contains|push|key|pos|css|top|items|className|left|initialize|fireEvent|array|parent|null|position|limit|empty|properties|timer|offset|result|prototype|style|selector|keys|each|name|props|tmp|prop|values|break|stop|addEvent|Elements|transition|parsed|mode|call|getStyle|overflown|step|set|delay|source|merge|page|relatedTarget||current|max|custom||unit|setStyle||inject|opacity|Garbage|Array|Methods|nocash|Events|scroll|bound|temp|chk|end|switch|Event|Base|rgb|onComplete|params|parse|documentElement|text|ie|join|create|object|overed|remove|wrapper|width|match|addListener|filter|map|container|toInt|context|margin|tag|parentNode|string|item|method|mouse|size|Transitions|CSS|change|Hash|test|Cookie|shared|target|mousemove|replace||scrollTo||Abstract|height|returns|drag||||modifiers|iCss|index|pow|time|script|getPosition|duration|getElementsByTagName|iTo|myTitle|toolTip|apply|load|implement|xpath|iterable|tip|periodical|border|previous|setOptions|round|knob|Styles|Drag|webkit|id|visibility|offsetHeight|grid|chains|hex|compute|bindWithEvent|setNow|increase|removeListener|offsetWidth|src|min|absolute|cookie|cont|image|htmlElement|bit|check|getValue|getNow|px|select||fx|sources|fromTo|Options|wait||mousewheel|indexOf|removeEvent|native|delete|clear|results|collect|onStart|len|title|body|fixed|class|getTag|trim|precision|iFrom|domReady|trash|split|iNow|parseInt|out|next|number|walk|area|option|offsets|handle|unique|setLength|bottom|right|parseFloat|klass|scrollLeft|scrollTop|hidden|div|toLowerCase|HTMLElement|open|val|mix|onload|layout|readyState|hide|myText|on|mp|href|forEach||Listeners|relative|get|continue|mod|100|typeof|setProperty|tagName|code|fKey|dual|getProperty|preventDefault|steps|stopPropagation|Properties|onChange|webkit419|defined|loaded|draggedKnob|checkStep|getElementById|regex|droppables|addEvents|getElementsBySelector|splice|included|setMany|realType|fix|Multi|hexToRgb|date|scrollWidth|removeEvents|evType|images|generic|counter|setStyles|hasKey|setProperties|head|setHTML|getElements|proto|every|color|scrollHeight|currentStyle|getSize|rgbToHex|brother|attempt|domain|mousedown|path|scrollSize||getCoordinates|Function|Style|getParam|operator|unload|getItems|ie_ready|mouseout|Dom|found|mouseover|regexp|hasChild|catch|while|NativeEvents|concat|add|gecko|iProps|nodeType|DOMMouseScroll|try|String|pageX|pageY|addEventListener|domready|Color|complete|flag|mouseup|visible|getLast|toStep|Slider|node|insertBefore|Transition|include|compat|firstChild|styles|random|previousEnd|previousChange|appendChild|RegExp|snap|default|lim|xhtml|clean|secure|onTick|camelCase|charAt|first|hasClass|onDrag|capitalize|cssText|pairs|easeType|getMany|getScrollTop|getHeight|getScrollLeft|str|evaluate|show|velocity|transitions|coord|horizontal|mousemover|newArray|getWidth|substr|maxTitleChars|PI|innerText|pick|locate|mouseenter|callee|img|mouseleave|merged|padding|vertical|interval|keydown|copy|prefix|resolver|constructor|ie6|picked|undefined|pp|Merge|toUpperCase|beforeunload|Number|filterById|filterByAttribute|filterByClass|slice|after|Right|Bottom|which|clientY|Top|0px|innerHTML|textContent|fixStyle|Width|Left|clientX|multiple|selected|PropertiesIFlag|extended|checked|disabled|direction|borderShort|wheelDelta|shift|styleSheet|appendText|removeEventListener|argument|contents|removeClass|before|cloneEvents|toFloat|createElement|elementsProperty|where|addClass|setOpacity|childNodes|fixRelatedTarget|nodeValue|removeChild|getNext|hyphenate|zoom|defaultView|relatedTargetGecko|click|Single|save|autoSave|getCoords|client|Scroller|Chain|Json|wheelStops|Asset|onProgress|toString|clickedElement|getPos|getScrollHeight|getScrollWidth|pageYOffset|pageXOffset|callChain|delta|half|toPosition|onCancel|fps|error|abort|getTop|getLeft|checkAgainst|Move|onSnap|distance|cos|attach|sin|onBeforeStart|Date|getTime|javascript|getStyles|toElement|full|injectAfter|escapeRegExp|slideOut|slideIn|adopt|1000|clientHeight|iParsed|win|hideDelay|showDelay|normal|sel|getElement|opera|onShow|onHide|Tips|span|timeout|removeAttribute|rel|clientWidth|build|http|getComputedStyle|encodeURIComponent|MooTools|getPrevious|drop|Sibling|emptydrop|setTime|getPropertyValue|makeDraggable|hasLayout|styleFloat|float|clearInterval|Window|cssFloat|clearTimeout|collection|zIndex|floor|alpha|over|sqrt|Quart|getProperties|removeProperty|Cubic|setAttribute|setText|getText|nodeName|detach|Quint|Quad|attributes|lastChild|whitespace|leave|version|getParent|getChildren|makeResizable|getAttribute|textnode|expires|getFirst|replaceChild|embed||DOMElement|execCommand|times|BackgroundImageCache|boolean|iframe|khtml|Object|1999|4096|bindAsEventListener|pass|some|hellip|associate|tool|getRandom|clearChain|chain|err|setInterval|setTimeout|transparent|getBoxObjectFor|webkit420|cloneNode|XMLHttpRequest|clone|readystatechange|injectTop|replaceWith|ActiveXObject|toggleClass|Document|createTextNode|decodeURIComponent|ie7|injectInside|onabort|screen|onerror|Image|taintEnabled|media|injectBefore|link|stylesheet|all|navigator|toGMTString|Elastic|starts|effects|Scroll|returnValue|toTop|cancelBubble|namespaceURI|effect|up|offsetLeft|do|enter|ES|fromElement|button|with|overflow|111|keyCode|keyup|detail|fromCharCode|Slide|rightClick|toBottom|toLeft|toRight|menu|offsetTop|down|dblclick|resize|innerHeight|move|focus|500|innerWidth|onDomReady|write|defer|keypress|onreadystatechange|DOMContentLoaded|clearTimer|blur|esc|https|protocol|location|offsetParent|filterByTag|space|void|tab|submit|reset|backspace|contextmenu|wheel|120|colSpan|rowspan|colspan|htmlFor|Pow|ease|rowSpan|accesskey|metaKey|maxLength|tabIndex|tabindex|accessKey|Expo|snapshotItem|618|getElementsByClassName|Bounce|www|org|w3|Back|Sine|borderStyle|borderColor|borderWidth|Circ|acos|readonly|maxlength|toggle|srcElement|CollectGarbage|easeIn|readOnly|XPathResult|shiftKey|control|altKey|meta|substring|alt|ctrlKey|snapshotLength|UNORDERED_NODE_SNAPSHOT_TYPE|Out|In|InOut|frameBorder|frameborder|easeOut|linear|detachEvent|attachEvent|easeInOut'.split('|'),0,{}))

//]]>
</script>

<script type='text/javascript'>
//<![CDATA[

/*
This file is part of JonDesign's SmoothGallery v2.0.

JonDesign's SmoothGallery is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 3 of the License, or
(at your option) any later version.

JonDesign's SmoothGallery is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
GNU General Public License for more details.

You should have received a copy of the GNU General Public License
along with JonDesign's SmoothGallery; if not, write to the Free Software
Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA

Main Developer: Jonathan Schemoul (JonDesign: http://www.jondesign.net/)
Contributed code by:
- Christian Ehret (bugfix)
- Nitrix (bugfix)
- Valerio from Mad4Milk for his great help with the carousel scrolling and many other things.
- Archie Cowan for helping me find a bugfix on carousel inner width problem.
- Tomocchino from #mootools for the preloader class
Many thanks to:
- The mootools team for the great mootools lib, and it's help and support throughout the project.
*/

// declaring the class
var gallery = {
initialize: function(element, options) {
this.setOptions({
 showArrows: true,
 showCarousel: true,
 showInfopane: true,
 embedLinks: true,
 fadeDuration: 500,
 timed: false,
 delay: 9000,
 preloader: true,
 preloaderImage: true,
 preloaderErrorImage: true,
 /* Data retrieval */
 manualData: [],
 populateFrom: false,
 populateData: true,
 destroyAfterPopulate: true,
 elementSelector: "div.imageElement",
 titleSelector: "h2",
 subtitleSelector: "p",
 linkSelector: "a.open",
 imageSelector: "img.full",
 thumbnailSelector: "img.thumbnail",
 defaultTransition: "fade",
 /* InfoPane options */
 slideInfoZoneOpacity: 0.7,
 slideInfoZoneSlide: true,
 /* Carousel options */
 carouselMinimizedOpacity: 0.4,
 carouselMinimizedHeight: 20,
 carouselMaximizedOpacity: 0.9,
 thumbHeight: 75,
 thumbWidth: 100,
 thumbSpacing: 10,
 thumbIdleOpacity: 0.2,
 textShowCarousel: 'Featured Content',
 showCarouselLabel: true,
 thumbCloseCarousel: true,
 useThumbGenerator: false,
 thumbGenerator: 'resizer.php',
 useExternalCarousel: false,
 carouselElement: false,
 carouselHorizontal: true,
 activateCarouselScroller: true,
 carouselPreloader: true,
 textPreloadingCarousel: 'Loading...',
 /* CSS Classes */
 baseClass: 'jdGallery',
 withArrowsClass: 'withArrows',
 /* Plugins: HistoryManager */
 useHistoryManager: false,
 customHistoryKey: false
}, options);
this.fireEvent('onInit');
this.currentIter = 0;
this.lastIter = 0;
this.maxIter = 0;
this.galleryElement = element;
this.galleryData = this.options.manualData;
this.galleryInit = 1;
this.galleryElements = Array();
this.thumbnailElements = Array();
this.galleryElement.addClass(this.options.baseClass);

this.populateFrom = element;
if (this.options.populateFrom)
 this.populateFrom = this.options.populateFrom;
if (this.options.populateData)
 this.populateData();
element.style.display="block";

if (this.options.useHistoryManager)
 this.initHistory();

if (this.options.embedLinks)
{
 this.currentLink = new Element('a').addClass('open').setProperties({
  href: '#',
  title: ''
 }).injectInside(element);
 if ((!this.options.showArrows) && (!this.options.showCarousel))
  this.galleryElement = element = this.currentLink;
 else
  this.currentLink.setStyle('display', 'none');
}

this.constructElements();
if ((this.galleryData.length>1)&&(this.options.showArrows))
{
 var leftArrow = new Element('a').addClass('left').addEvent(
  'click',
  this.prevItem.bind(this)
 ).injectInside(element);
 var rightArrow = new Element('a').addClass('right').addEvent(
  'click',
  this.nextItem.bind(this)
 ).injectInside(element);
 this.galleryElement.addClass(this.options.withArrowsClass);
}
this.loadingElement = new Element('div').addClass('loadingElement').injectInside(element);
if (this.options.showInfopane) this.initInfoSlideshow();
if (this.options.showCarousel) this.initCarousel();
this.doSlideShow(1);
},
populateData: function() {
currentArrayPlace = this.galleryData.length;
options = this.options;
var data = $A(this.galleryData);
data.extend(this.populateGallery(this.populateFrom, currentArrayPlace));
this.galleryData = data;
this.fireEvent('onPopulated');
},
populateGallery: function(element, startNumber) {
var data = [];
options = this.options;
currentArrayPlace = startNumber;
element.getElements(options.elementSelector).each(function(el) {
 elementDict = {
  image: el.getElement(options.imageSelector).getProperty('src'),
  number: currentArrayPlace,
  transition: this.options.defaultTransition
 };
 elementDict.extend = $extend;
 if ((options.showInfopane) | (options.showCarousel))
  elementDict.extend({
   title: el.getElement(options.titleSelector).innerHTML,
   description: el.getElement(options.subtitleSelector).innerHTML
  });
 if (options.embedLinks)
  elementDict.extend({
   link: el.getElement(options.linkSelector).href||false,
   linkTitle: el.getElement(options.linkSelector).title||false,
   linkTarget: el.getElement(options.linkSelector).getProperty('target')||false
  });
 if ((!options.useThumbGenerator) && (options.showCarousel))
  elementDict.extend({
   thumbnail: el.getElement(options.thumbnailSelector).getProperty('src')
  });
 else if (options.useThumbGenerator)
  elementDict.extend({
   thumbnail: options.thumbGenerator + '?imgfile=' + elementDict.image + '&max_width=' + options.thumbWidth + '&max_height=' + options.thumbHeight
  });

 data.extend([elementDict]);
 currentArrayPlace++;
 if (this.options.destroyAfterPopulate)
  el.remove();
});
return data;
},
constructElements: function() {
el = this.galleryElement;
this.maxIter = this.galleryData.length;
var currentImg;
for(i=0;i<this.galleryData.length;i++)
{
 var currentImg = new Fx.Styles(
  new Element('div').addClass('slideElement').setStyles({
   'position':'absolute',
   'left':'0px',
   'right':'0px',
   'margin':'0px',
   'padding':'0px',
   'backgroundPosition':"center center",
   'opacity':'0'
  }).injectInside(el),
  'opacity',
  {duration: this.options.fadeDuration}
 );
 if (this.options.preloader)
 {
  currentImg.source = this.galleryData[i].image;
  currentImg.loaded = false;
  currentImg.load = function(imageStyle) {
   if (!imageStyle.loaded) {
    new Asset.image(imageStyle.source, {
                            'onload'  : function(img){
           img.element.setStyle(
           'backgroundImage',
           "url('" + img.source + "')")
           img.loaded = true;
          }.bind(this, imageStyle)
    });
   }
  }.pass(currentImg, this);
 } else {
  currentImg.element.setStyle('backgroundImage',
       "url('" + this.galleryData[i].image + "')");
 }
 this.galleryElements[parseInt(i)] = currentImg;
}
},
destroySlideShow: function(element) {
var myClassName = element.className;
var newElement = new Element('div').addClass('myClassName');
element.parentNode.replaceChild(newElement, element);
},
startSlideShow: function() {
this.fireEvent('onStart');
this.loadingElement.style.display = "none";
this.lastIter = this.maxIter - 1;
this.currentIter = 0;
this.galleryInit = 0;
this.galleryElements[parseInt(this.currentIter)].set({opacity: 1});
if (this.options.showInfopane)
 this.showInfoSlideShow.delay(1000, this);
var textShowCarousel = formatString(this.options.textShowCarousel, this.currentIter+1, this.maxIter);
if (this.options.showCarousel&&(!this.options.carouselPreloader))
 this.carouselBtn.setHTML(textShowCarousel).setProperty('title', textShowCarousel);
this.prepareTimer();
if (this.options.embedLinks)
 this.makeLink(this.currentIter);
},
nextItem: function() {
this.fireEvent('onNextCalled');
this.nextIter = this.currentIter+1;
if (this.nextIter >= this.maxIter)
 this.nextIter = 0;
this.galleryInit = 0;
this.goTo(this.nextIter);
},
prevItem: function() {
this.fireEvent('onPreviousCalled');
this.nextIter = this.currentIter-1;
if (this.nextIter <= -1)
 this.nextIter = this.maxIter - 1;
this.galleryInit = 0;
this.goTo(this.nextIter);
},
goTo: function(num) {
this.clearTimer();
if(this.options.preloader)
{
 this.galleryElements[num].load();
 if (num==0)
  this.galleryElements[this.maxIter - 1].load();
 else
  this.galleryElements[num - 1].load();
 if (num==(this.maxIter - 1))
  this.galleryElements[0].load();
 else
  this.galleryElements[num + 1].load();

}
if (this.options.embedLinks)
 this.clearLink();
if (this.options.showInfopane)
{
 this.slideInfoZone.clearChain();
 this.hideInfoSlideShow().chain(this.changeItem.pass(num, this));
} else
 this.currentChangeDelay = this.changeItem.delay(500, this, num);
if (this.options.embedLinks)
 this.makeLink(num);
this.prepareTimer();
/*if (this.options.showCarousel)
 this.clearThumbnailsHighlights();*/
},
changeItem: function(num) {
this.fireEvent('onStartChanging');
this.galleryInit = 0;
if (this.currentIter != num)
{
 for(i=0;i<this.maxIter;i++)
 {
  if ((i != this.currentIter)) this.galleryElements[i].set({opacity: 0});
 }
 gallery.Transitions[this.galleryData[num].transition].pass([
  this.galleryElements[this.currentIter],
  this.galleryElements[num],
  this.currentIter,
  num], this)();
 this.currentIter = num;
}
var textShowCarousel = formatString(this.options.textShowCarousel, num+1, this.maxIter);
if (this.options.showCarousel)
 this.carouselBtn.setHTML(textShowCarousel).setProperty('title', textShowCarousel);
this.doSlideShow.bind(this)();
this.fireEvent('onChanged');
},
clearTimer: function() {
if (this.options.timed)
 $clear(this.timer);
},
prepareTimer: function() {
if (this.options.timed)
 this.timer = this.nextItem.delay(this.options.delay, this);
},
doSlideShow: function(position) {
if (this.galleryInit == 1)
{
 imgPreloader = new Image();
 imgPreloader.onload=function(){
  this.startSlideShow.delay(10, this);
 }.bind(this);
 imgPreloader.src = this.galleryData[0].image;
 if(this.options.preloader)
  this.galleryElements[0].load();
} else {
 if (this.options.showInfopane)
 {
  if (this.options.showInfopane)
  {
   this.showInfoSlideShow.delay((500 + this.options.fadeDuration), this);
  } else
   if ((this.options.showCarousel)&&(this.options.activateCarouselScroller))
    this.centerCarouselOn(position);
 }
}
},
createCarousel: function() {
var carouselElement;
if (!this.options.useExternalCarousel)
{
 var carouselContainerElement = new Element('div').addClass('carouselContainer').injectInside(this.galleryElement);
 this.carouselContainer = new Fx.Styles(carouselContainerElement, {transition: Fx.Transitions.expoOut});
 this.carouselContainer.normalHeight = carouselContainerElement.offsetHeight;
 this.carouselContainer.set({'opacity': this.options.carouselMinimizedOpacity, 'top': (this.options.carouselMinimizedHeight - this.carouselContainer.normalHeight)});
 this.carouselBtn = new Element('a').addClass('carouselBtn').setProperties({
  title: this.options.textShowCarousel
 }).injectInside(carouselContainerElement);
 if(this.options.carouselPreloader)
  this.carouselBtn.setHTML(this.options.textPreloadingCarousel);
 else
  this.carouselBtn.setHTML(this.options.textShowCarousel);
 this.carouselBtn.addEvent(
  'click',
  function () {
   this.carouselContainer.clearTimer();
   this.toggleCarousel();
  }.bind(this)
 );
 this.carouselActive = false;

 carouselElement = new Element('div').addClass('carousel').injectInside(carouselContainerElement);
 this.carousel = new Fx.Styles(carouselElement);
} else {
 carouselElement = $(this.options.carouselElement).addClass('jdExtCarousel');
}
this.carouselElement = new Fx.Styles(carouselElement, {transition: Fx.Transitions.expoOut});
this.carouselElement.normalHeight = carouselElement.offsetHeight;
if (this.options.showCarouselLabel)
 this.carouselLabel = new Element('p').addClass('label').injectInside(carouselElement);
carouselWrapper = new Element('div').addClass('carouselWrapper').injectInside(carouselElement);
this.carouselWrapper = new Fx.Styles(carouselWrapper, {transition: Fx.Transitions.expoOut});
this.carouselWrapper.normalHeight = carouselWrapper.offsetHeight;
this.carouselInner = new Element('div').addClass('carouselInner').injectInside(carouselWrapper);
if (this.options.activateCarouselScroller)
{
 this.carouselWrapper.scroller = new Scroller(carouselWrapper, {
  area: 100,
  velocity: 0.2
 })

 this.carouselWrapper.elementScroller = new Fx.Scroll(carouselWrapper, {
  duration: 400,
  onStart: this.carouselWrapper.scroller.stop.bind(this.carouselWrapper.scroller),
  onComplete: this.carouselWrapper.scroller.start.bind(this.carouselWrapper.scroller)
 });
}
},
fillCarousel: function() {
this.constructThumbnails();
this.carouselInner.normalWidth = ((this.maxIter * (this.options.thumbWidth + this.options.thumbSpacing + 2))+this.options.thumbSpacing) + "px";
this.carouselInner.style.width = this.carouselInner.normalWidth;
},
initCarousel: function () {
this.createCarousel();
this.fillCarousel();
if (this.options.carouselPreloader)
 this.preloadThumbnails();
},
flushCarousel: function() {
this.thumbnailElements.each(function(myFx) {
 myFx.element.remove();
 myFx = myFx.element = null;
});
this.thumbnailElements = [];
},
toggleCarousel: function() {
if (this.carouselActive)
 this.hideCarousel();
else
 this.showCarousel();
},
showCarousel: function () {
this.fireEvent('onShowCarousel');
this.carouselContainer.start({
 'opacity': this.options.carouselMaximizedOpacity,
 'top': 0
}).chain(function() {
 this.carouselActive = true;
 this.carouselWrapper.scroller.start();
 this.fireEvent('onCarouselShown');
 this.carouselContainer.options.onComplete = null;
}.bind(this));
},
hideCarousel: function () {
this.fireEvent('onHideCarousel');
var targetTop = this.options.carouselMinimizedHeight - this.carouselContainer.normalHeight;
this.carouselContainer.start({
 'opacity': this.options.carouselMinimizedOpacity,
 'top': targetTop
}).chain(function() {
 this.carouselActive = false;
 this.carouselWrapper.scroller.stop();
 this.fireEvent('onCarouselHidden');
 this.carouselContainer.options.onComplete = null;
}.bind(this));
},
constructThumbnails: function () {
element = this.carouselInner;
for(i=0;i<this.galleryData.length;i++)
{
 var currentImg = new Fx.Style(new Element ('div').addClass("thumbnail").setStyles({
   backgroundImage: "url('" + this.galleryData[i].thumbnail + "')",
   backgroundPosition: "center center",
   backgroundRepeat: 'no-repeat',
   marginLeft: this.options.thumbSpacing + "px",
   width: this.options.thumbWidth + "px",
   height: this.options.thumbHeight + "px"
  }).injectInside(element), "opacity", {duration: 200}).set(this.options.thumbIdleOpacity);
 currentImg.element.addEvents({
  'mouseover': function (myself) {
   myself.clearTimer();
   myself.start(0.99);
   if (this.options.showCarouselLabel)
    $(this.carouselLabel).setHTML('<span class="number">' + (myself.relatedImage.number + 1) + "/" + this.maxIter + ":</span> " + myself.relatedImage.title);
  }.pass(currentImg, this),
  'mouseout': function (myself) {
   myself.clearTimer();
   myself.start(this.options.thumbIdleOpacity);
  }.pass(currentImg, this),
  'click': function (myself) {
   this.goTo(myself.relatedImage.number);
   if (this.options.thumbCloseCarousel)
    this.hideCarousel();
  }.pass(currentImg, this)
 });

 currentImg.relatedImage = this.galleryData[i];
 this.thumbnailElements[parseInt(i)] = currentImg;
}
},
log: function(value) {
if(console.log)
 console.log(value);
},
preloadThumbnails: function() {
var thumbnails = [];
for(i=0;i<this.galleryData.length;i++)
{
 thumbnails[parseInt(i)] = this.galleryData[i].thumbnail;
}
this.thumbnailPreloader = new Preloader();
this.thumbnailPreloader.addEvent('onComplete', function() {
 var textShowCarousel = formatString(this.options.textShowCarousel, this.currentIter+1, this.maxIter);
 this.carouselBtn.setHTML(textShowCarousel).setProperty('title', textShowCarousel);
}.bind(this));
this.thumbnailPreloader.load(thumbnails);
},
clearThumbnailsHighlights: function()
{
for(i=0;i<this.galleryData.length;i++)
{
 this.thumbnailElements[i].clearTimer();
 this.thumbnailElements[i].start(0.2);
}
},
changeThumbnailsSize: function(width, height)
{
for(i=0;i<this.galleryData.length;i++)
{
 this.thumbnailElements[i].clearTimer();
 this.thumbnailElements[i].element.setStyles({
  'width': width + "px",
  'height': height + "px"
 });
}
},
centerCarouselOn: function(num) {
if (!this.carouselWallMode)
{
 var carouselElement = this.thumbnailElements[num];
 var position = carouselElement.element.offsetLeft + (carouselElement.element.offsetWidth / 2);
 var carouselWidth = this.carouselWrapper.element.offsetWidth;
 var carouselInnerWidth = this.carouselInner.offsetWidth;
 var diffWidth = carouselWidth / 2;
 var scrollPos = position-diffWidth;
 this.carouselWrapper.elementScroller.scrollTo = (scrollPos,0);
}
},
initInfoSlideshow: function() {
/*if (this.slideInfoZone.element)
 this.slideInfoZone.element.remove();*/
this.slideInfoZone = new Fx.Styles(new Element('div').addClass('slideInfoZone').injectInside($(this.galleryElement))).set({'opacity':0});
var slideInfoZoneTitle = new Element('h2').injectInside(this.slideInfoZone.element);
var slideInfoZoneDescription = new Element('p').injectInside(this.slideInfoZone.element);
this.slideInfoZone.normalHeight = this.slideInfoZone.element.offsetHeight;
this.slideInfoZone.element.setStyle('opacity',0);
},
changeInfoSlideShow: function()
{
this.hideInfoSlideShow.delay(10, this);
this.showInfoSlideShow.delay(500, this);
},
showInfoSlideShow: function() {
this.fireEvent('onShowInfopane');
this.slideInfoZone.clearTimer();
element = this.slideInfoZone.element;
element.getElement('h2').setHTML(this.galleryData[this.currentIter].title);
element.getElement('p').setHTML(this.galleryData[this.currentIter].description);
if(this.options.slideInfoZoneSlide)
 this.slideInfoZone.start({'opacity': [0, this.options.slideInfoZoneOpacity], 'height': [0, this.slideInfoZone.normalHeight]});
else
 this.slideInfoZone.start({'opacity': [0, this.options.slideInfoZoneOpacity]});
if (this.options.showCarousel)
 this.slideInfoZone.chain(this.centerCarouselOn.pass(this.currentIter, this));
return this.slideInfoZone;
},
hideInfoSlideShow: function() {
this.fireEvent('onHideInfopane');
this.slideInfoZone.clearTimer();
if(this.options.slideInfoZoneSlide)
 this.slideInfoZone.start({'opacity': 0, 'height': 0});
else
 this.slideInfoZone.start({'opacity': 0});
return this.slideInfoZone;
},
makeLink: function(num) {
this.currentLink.setProperties({
 href: this.galleryData[num].link,
 title: this.galleryData[num].linkTitle
})
if (!((this.options.embedLinks) && (!this.options.showArrows) && (!this.options.showCarousel)))
 this.currentLink.setStyle('display', 'block');
},
clearLink: function() {
this.currentLink.setProperties({href: '', title: ''});
if (!((this.options.embedLinks) && (!this.options.showArrows) && (!this.options.showCarousel)))
 this.currentLink.setStyle('display', 'none');
},
/* To change the gallery data, those two functions : */
flushGallery: function() {
this.galleryElements.each(function(myFx) {
 myFx.element.remove();
 myFx = myFx.element = null;
});
this.galleryElements = [];
},
changeData: function(data) {
this.galleryData = data;
this.clearTimer();
this.flushGallery();
if (this.options.showCarousel) this.flushCarousel();
this.constructElements();
if (this.options.showCarousel) this.fillCarousel();
if (this.options.showInfopane) this.hideInfoSlideShow();
this.galleryInit=1;
this.lastIter=0;
this.currentIter=0;
this.doSlideShow(1);
},
/* Plugins: HistoryManager */
initHistory: function() {
this.fireEvent('onHistoryInit');
this.historyKey = this.galleryElement.id + '-picture';
if (this.options.customHistoryKey)
 this.historyKey = this.options.customHistoryKey();
this.history = HistoryManager.register(
 this.historyKey,
 [1],
 function(values) {
  if (parseInt(values[0])-1 < this.maxIter)
   this.goTo(parseInt(values[0])-1);
 }.bind(this),
 function(values) {
  return [this.historyKey, '(', values[0], ')'].join('');
 }.bind(this),
 this.historyKey + '\((\d+)\)');
this.addEvent('onChanged', function(){
 this.history.setValue(0, this.currentIter+1);
}.bind(this));
this.fireEvent('onHistoryInited');
}
};
gallery = new Class(gallery);
gallery.implement(new Events);
gallery.implement(new Options);

gallery.Transitions = new Abstract ({
fade: function(oldFx, newFx, oldPos, newPos){
oldFx.options.transition = newFx.options.transition = Fx.Transitions.linear;
oldFx.options.duration = newFx.options.duration = this.options.fadeDuration;
if (newPos > oldPos) newFx.start({opacity: 1});
else
{
 newFx.set({opacity: 1});
 oldFx.start({opacity: 0});
}
},
crossfade: function(oldFx, newFx, oldPos, newPos){
oldFx.options.transition = newFx.options.transition = Fx.Transitions.linear;
oldFx.options.duration = newFx.options.duration = this.options.fadeDuration;
newFx.start({opacity: 1});
oldFx.start({opacity: 0});
},
fadebg: function(oldFx, newFx, oldPos, newPos){
oldFx.options.transition = newFx.options.transition = Fx.Transitions.linear;
oldFx.options.duration = newFx.options.duration = this.options.fadeDuration / 2;
oldFx.start({opacity: 0}).chain(newFx.start.pass([{opacity: 1}], newFx));
}
});

/* All code copyright 2007 Jonathan Schemoul */

/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
* Follows: Preloader (class)
* Simple class for preloading images with support for progress reporting
* Copyright 2007 Tomocchino.
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */

var Preloader = new Class({

Implements: [Events, Options],

options: {
root        : '',
period      : 100
},

initialize: function(options){
this.setOptions(options);
},

load: function(sources) {
this.index = 0;
this.images = [];
this.sources = this.temps = sources;
this.total = this. sources.length;

this.fireEvent('onStart', [this.index, this.total]);
this.timer = this.progress.periodical(this.options.period, this);

this.sources.each(function(source, index){
this.images[index] = new Asset.image(this.options.root + source, {
'onload'  : function(){ this.index++; if(this.images[index]) this.fireEvent('onLoad', [this.images[index], index, source]); }.bind(this),
'onerror' : function(){ this.index++; this.fireEvent('onError', [this.images.splice(index, 1), index, source]); }.bind(this),
'onabort' : function(){ this.index++; this.fireEvent('onError', [this.images.splice(index, 1), index, source]); }.bind(this)
});
}, this);
},

progress: function() {
this.fireEvent('onProgress', [Math.min(this.index, this.total), this.total]);
if(this.index >= this.total) this.complete();
},

complete: function(){
$clear(this.timer);
this.fireEvent('onComplete', [this.images]);
},

cancel: function(){
$clear(this.timer);
}

});

Preloader.implement(new Events, new Options);

/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
* Follows: formatString (function)
* Original name: Yahoo.Tools.printf
* Copyright Yahoo.
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */

function formatString() {
var num = arguments.length;
var oStr = arguments[0];
for (var i = 1; i < num; i++) {
var pattern = "\{" + (i-1) + "\}";
var re = new RegExp(pattern, "g");
oStr = oStr.replace(re, arguments[i]);
}
return oStr;
}

//]]>
</script>

<b:if cond='data:blog.pageType == &quot;item&quot;'>
<style>#featabout, .extra {display:none; margin:0;padding:0;border:0;}</style>
</b:if>
<script type='text/javascript'> var thumbnail_mode = &quot;no-float&quot; ; summary_noimg = 430; summary_img = 340; img_thumb_height = 100; img_thumb_width = 180; </script>
<script type='text/javascript'>
//<![CDATA[
function removeHtmlTag(strx,chop){
if(strx.indexOf("<")!=-1)
{
var s = strx.split("<");
for(var i=0;i<s.length;i++){
if(s[i].indexOf(">")!=-1){
s[i] = s[i].substring(s[i].indexOf(">")+1,s[i].length);
}
}
strx = s.join("");
}
chop = (chop < strx.length-1) ? chop : strx.length-2;
while(strx.charAt(chop-1)!=' ' && strx.indexOf(' ',chop)!=-1) chop++;
strx = strx.substring(0,chop-1);
return strx+'...';
}
function createSummaryAndThumb(pID){
var div = document.getElementById(pID);
var imgtag = "";
var img = div.getElementsByTagName("img");
var summ = summary_noimg;
if(img.length>=1) {
imgtag = '<span style="float:left; padding:0px 10px 5px 0px;"><img src="'+img[0].src+'" width="'+img_thumb_width+'px" height="'+img_thumb_height+'px"/></span>';
summ = summary_img;
}
var summary = imgtag + '<div>' + removeHtmlTag(div.innerHTML,summ) + '</div>';
div.innerHTML = summary;
}
//]]>
</script>

<style type='text/css'>
div#featabout { width: 635px; border-bottom: 1px solid; }
div#featabout-wrapper { margin: 0 auto; padding: 22px 0; width: 635px; height: 235px; }

div#featabout div.featured { float: left; width: 640px; }
div#featabout div.featured div.top { height: 15px; }
div#featabout div.featured div.mid { padding: 0 15px; }
div#featabout div.featured div.mid div#featured { border: 1px solid; }
div#featabout div.featured div.bot { height: 15px; }

div#featabout div.about { float: right; width: 328px; }
div#featabout div.about div.top { height: 15px; }
div#featabout div.about div.mid { padding: 0 15px; height: 224px; }
div#featabout div.about div.bot { height: 15px; }

div#featabout div.ab-box h2 { display: block; margin: 0; padding: 0 0 8px 0;         font-size: 12px;
font-family: Georgia, &#39;Times New Roman&#39;, serif;
text-transform: uppercase;
}
div#featabout div.ab-box div.interior { padding: 8px 0; }
div#featabout div.ab-box div.interior p { display: block; margin: 0; padding: 0; }
div#featabout div.ab-box-author div.interior { padding: 8px 0 16px 0; min-height: 60px; }
div#featabout div.ab-box-author div.interior img { padding: 3px; border: 1px solid; float: left; margin: 0 5px 0 0; }
div#featabout div.ab-box-burner div.interior { padding: 8px 0 8px 65px; }
div#featabout div.ab-box-burner div.interior p { display: block; margin: 0; padding: 0; line-height: 28px; }
div#featabout div.ab-box-burner div.interior span { display: block; height: 21px; margin: 0 0 0 0; padding: 6px 0 0 0; }
div#featabout div.ab-box-burner div.interior span input { width: 191px; padding: 0 5px; border: 0; }
div#featabout {
background: #ffffff url(&#39;&#39;) repeat-x scroll left top;
border-bottom: none;
}
div#featabout div.featured { background: transparent url(&#39;&#39;) repeat-y scroll left top; }
div#featabout div.featured div.top { background: transparent url(&#39;&#39;) no-repeat scroll left top; }
div#featabout div.featured div.mid div#featured { border-color: #000; }
div#featabout div.featured div.bot { background: transparent url(&#39;&#39;) no-repeat scroll left bottom; }
div#featured h2 {
font-family: Georgia, &#39;Times New Roman&#39;, sans-serif; font-size: 24px;
line-height: 30px; font-weight: normal;
}
div#featured p {
font-family: Arial, Helvetica, sans-serif; font-size: 13px;
}

div#featabout div.about { color: #999; background: transparent url(&#39;&#39;) repeat-y scroll left top; }
div#featabout div.about div.top { background: transparent url(&#39;&#39;) no-repeat scroll left top; }
div#featabout div.about div.bot { background: transparent url(&#39;&#39;) no-repeat scroll left bottom; }

div#featabout div.ab-box h2 { color: #e1e1c7; background: transparent url(&#39;&#39;) repeat-x scroll left bottom; }
div#featabout div.ab-box-burner div.interior { color: #999; background: transparent url(&#39;&#39;) no-repeat scroll 0px 8px; }
div#featabout div.ab-box-burner div.interior span { background: transparent url(&#39;&#39;) left top no-repeat; }
div#featabout div.ab-box-burner div.interior span input { background: transparent none; color: #666; }

#flickrGallery
{
width: 500px;
height: 334px;
}
#myGallery img.thumbnail, #myGallerySet img.thumbnail
{
display: none;
}
.jdGallery
{
overflow: hidden;
position: relative;
}
.jdGallery img
{
border: 0;
margin: 0;
}
.jdGallery .slideElement
{
width: 100%;
height: 100%;
background-color: #000;
background-repeat: no-repeat;
background-position: center center;
background-image: url(&#39;&#39;);
}
.jdGallery .loadingElement
{
width: 100%;
height: 100%;
position: absolute;
left: 0;
top: 0;
background-color: #000;
background-repeat: no-repeat;
background-position: center center;
background-image: url(&#39;&#39;);
}
* html .jdGallery .slideInfoZone
{
bottom: -1px;
}
.jdGallery .slideInfoZone h2
{
padding: 0;
font-size: 14px;
margin: 0;
margin: 2px 5px;
font-weight: bold;
color: #FFFFFF;
bacground: transparent;
}
.jdGallery .slideInfoZone ul {
list-style:none;
margin:0 0 0;
padding:0 0 0;
color: #FFFFFF;
}
.jdGallery .slideInfoZone li {
list-style:none;
margin:0 0 0;
padding:0 0 0;
color: #FFFFFF;
}
.jdGallery .slideInfoZone p
{
padding: 0;
font-size: 11px;
margin: 2px 5px;
color: #FFFFFF;
}
.jdGallery div.carouselContainer
{
position: absolute;
height: 135px;
width: 100%;
z-index: 10;
margin: 0px;
left: 0;
top: 0;
}
.jdGallery a.carouselBtn
{
position: absolute;
bottom: 0;
right: 30px;
height: 20px;
/*width: 100px; background: url(&#39;&#39;) no-repeat;*/
text-align: center;
padding: 0 10px;
font-size: 13px;
background: #000;
color: #fff;
cursor: pointer;
}
.jdGallery .carousel
{
position: absolute;
width: 100%;
margin: 0px;
left: 0;
top: 0;
height: 115px;
background: #000;
color: #fff;
text-indent: 0;
overflow: hidden;
}
.jdExtCarousel
{
overflow: hidden;
position: relative;
}
.jdGallery .carousel .carouselWrapper, .jdExtCarousel .carouselWrapper
{
position: absolute;
width: 100%;
height: 78px;
top: 10px;
left: 0;
overflow: hidden;
}
.jdGallery .carousel .carouselInner, .jdExtCarousel .carouselInner
{
position: relative;
}
.jdGallery .carousel .carouselInner .thumbnail, .jdExtCarousel .carouselInner .thumbnail
{
cursor: pointer;
background: #000;
background-position: center center;
float: left;
border: solid 1px #fff;
}
.jdGallery .wall .thumbnail, .jdExtCarousel .wall .thumbnail
{
margin-bottom: 10px;
}
.jdGallery .carousel .label, .jdExtCarousel .label
{
font-size: 13px;
position: absolute;
bottom: 5px;
left: 10px;
padding: 0;
margin: 0;
}
.jdGallery .carousel .wallButton, .jdExtCarousel .wallButton
{
font-size: 10px;
position: absolute;
bottom: 5px;
right: 10px;
padding: 1px 2px;
margin: 0;
background: #222;
border: 1px solid #888;
cursor: pointer;
}
.jdGallery .carousel .label .number, .jdExtCarousel .label .number
{
color: #b5b5b5;
}
.jdGallery a, .jdGallery a:hover
{
font-size: 100%;
text-decoration: none;
color: #fff;
}
.jdGallery a.right, .jdGallery a.left
{
position: absolute;
height: 99%;
width: 25%;
cursor: pointer;
z-index:10;
filter:alpha(opacity=20);
-moz-opacity:0.2;
-khtml-opacity: 0.2;
opacity: 0.2;
}
* html .jdGallery a.right, * html .jdGallery a.left
{
filter:alpha(opacity=50);
}
.jdGallery a.right:hover, .jdGallery a.left:hover
{
filter:alpha(opacity=80);
-moz-opacity:0.8;
-khtml-opacity: 0.8;
opacity: 0.8;
}
.jdGallery a.left
{
left: 0;
top: 0;
background: url(&#39;img/fleche1.png&#39;) no-repeat center left;
}
* html .jdGallery a.left { background: url(&#39;img/fleche1.gif&#39;) no-repeat center left; }
.jdGallery a.right
{
right: 0;
top: 0;
background: url(&#39;&#39;) no-repeat center right;
}
* html .jdGallery a.right { background: url(&#39;&#39;) no-repeat center right; }
.jdGallery a.open
{
left: 0;
top: 0;
width: 100%;
height: 100%;
}
.withArrows a.open
{
position: absolute;
top: 0;
left: 25%;
height: 99%;
width: 50%;
cursor: pointer;
z-index: 10;
background: none;
-moz-opacity:0.8;
-khtml-opacity: 0.8;
opacity: 0.8;
}
.withArrows a.open:hover { background: url(&#39;&#39;) no-repeat center center; }
* html .withArrows a.open:hover { background: url(&#39;&#39;) no-repeat center center;
filter:alpha(opacity=80); }
/* Gallery Sets */
.jdGallery a.gallerySelectorBtn
{
z-index: 15;
position: absolute;
top: 0;
left: 30px;
height: 20px;
/*width: 100px; background: url(&#39;&#39;) no-repeat;*/
text-align: center;
padding: 0 10px;
font-size: 13px;
background: #000;
color: #fff;
cursor: pointer;
opacity: .4;
-moz-opacity: .4;
-khtml-opacity: 0.4;
filter:alpha(opacity=40);
}
.jdGallery .gallerySelector
{
z-index: 20;
width: 100%;
height: 100%;
position: absolute;
top: 0;
left: 0;
background: #000;
}
.jdGallery .gallerySelector h2
{
margin: 0;
padding: 10px 20px 10px 20px;
font-size: 20px;
line-height: 30px;
color: #fff;
}
.jdGallery .gallerySelector .gallerySelectorWrapper
{
overflow: hidden;
}
.jdGallery .gallerySelector .gallerySelectorInner div.galleryButton
{
margin-left: 10px;
margin-top: 10px;
border: 1px solid #888;
padding: 5px;
height: 40px;
color: #fff;
cursor: pointer;
float: left;
}
.jdGallery .gallerySelector .gallerySelectorInner div.hover
{
background: #000;
}
.jdGallery .gallerySelector .gallerySelectorInner div.galleryButton div.preview
{
background: #000;
background-position: center center;
float: left;
border: none;
width: 40px;
height: 40px;
margin-right: 5px;
}
.jdGallery .gallerySelector .gallerySelectorInner div.galleryButton h3
{
margin: 0;
padding: 0;
font-size: 12px;
font-weight: normal;
}
.jdGallery .gallerySelector .gallerySelectorInner div.galleryButton p.info
{
margin: 0;
padding: 0;
font-size: 12px;
font-weight: normal;
color: #aaa;
}
.extra div.box { width: 310px; padding: 0px; margin:0;}
.extra div.box-popular { float: left; }
.extra div.box-recent { float: right; }

</style>

4.Now again scroll down to where you see below code:

<div id='main-wrapper'>

5.Copy below code and paste it just before <div id='main-wrapper'> .

<div id='featabout'>
<div id='featabout-wrapper'>
<div class='featured'>
<div class='top'/>
<div class='mid'>
<div id='featured'>

<style>
#myGallery, #myGallerySet, #flickrGallery {
width: 606px;
height: 220px;
z-index:5;
border: 1px solid #000;
overflow:hidden;
}

.jdGallery .slideInfoZone
{
position: absolute;
z-index: 10;
width: 100%;
margin: 0px;
left: 0;
bottom: 0;
height: 80px;
background: #000;
color: #fff;
text-indent: 0;
overflow: hidden;
}
</style>

<script type='text/javascript'>
 function startGallery() {
     var myGallery = new gallery($(&#39;myGallery&#39;), {
         timed: true
     });
 }
 window.addEvent(&#39;domready&#39;,startGallery);
</script>

<div id='myGallery'>

<script type='text/javascript'>
//<![CDATA[
function rp(json) {

for (var i = startposts; i < numposts; i++) {

var entry = json.feed.entry[i];
var posttitle = entry.title.$t;
var posturl;

if (i == json.feed.entry.length) break;

for (var k = 0; k < entry.link.length; k++) {
 if (entry.link[k].rel == 'alternate') {
  posturl = entry.link[k].href;
  break;
 }
}

posttitle = posttitle.link(posturl);
var readmorelink = "(Read More)";
readmorelink = readmorelink.link(posturl);
var postdate = entry.published.$t;
var cdyear = postdate.substring(0,4);
var cdmonth = postdate.substring(5,7);
var cdday = postdate.substring(8,10);
var monthnames = new Array();
monthnames[1] = "Jan";
monthnames[2] = "Feb";
monthnames[3] = "Mar";
monthnames[4] = "Apr";
monthnames[5] = "May";
monthnames[6] = "Jun";
monthnames[7] = "Jul";
monthnames[8] = "Aug";
monthnames[9] = "Sep";
monthnames[10] = "Oct";
monthnames[11] = "Nov";
monthnames[12] = "Dec";

if ("content" in entry) {
 var postcontent = entry.content.$t;
} else if ("summary" in entry) {
 var postcontent = entry.summary.$t;
} else
 var postcontent = "";
 var re = /<S[^>]*>/g;
 postcontent = postcontent.replace(re, "");
 if (showposttitle == true) document.write(posttitle);

 if (showpostdate == true) document.write(' - ' + monthnames[parseInt(cdmonth,10)] + ' ' + cdday);

if (showpostsummary == true) {
 if (postcontent.length < numchars) {
  document.write(postcontent);
 } else {
  postcontent = postcontent.substring(0, numchars);
  var quoteEnd = postcontent.lastIndexOf(" ");
  postcontent = postcontent.substring(0,quoteEnd);

  document.write(postcontent);

  document.write('...' + readmorelink);
 }
}

}


}
//]]>
</script>

<div class='imageElement'>
<h2>&lt;script&gt;var startposts = 0; numposts = 1; var showposttitle = true; showpostdate = false; var showpostsummary = false; var numchars = 0; &lt;/script&gt;&lt;script src=&quot;http://www.bloggertricksandtoolz.com/feeds/posts/default?orderby=published&amp;alt=json-in-script&amp;callback=rp&quot;&gt;
&lt;/script&gt;</h2>
<p>&lt;script&gt;var startposts = 0; numposts = 1; var showposttitle = false; showpostdate = false; var showpostsummary = true; var numchars = 150; &lt;/script&gt;&lt;script src=&quot;http://www.bloggertricksandtoolz.com/feeds/posts/default?orderby=published&amp;alt=json-in-script&amp;callback=rp&quot;&gt;
&lt;/script&gt;</p>

<a class='open' href='#' title='Read More'/>
<img class='full' src='https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhm0gIu34K77W21P0rkjL6No-NNXG9oRB2WVElZIXR4zgsN7rHodQ0_8zzeGFm_zbrmvd5gX6wQHc8Ra9dQMn2J1YV7F3MG7hOcZKy1EmDYjzgdIg873J5Zj4f3D8ee4RzkOaCy5wsNJlbo/+slider1.jpg'/>
<img class='thumbnail' src='https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhm0gIu34K77W21P0rkjL6No-NNXG9oRB2WVElZIXR4zgsN7rHodQ0_8zzeGFm_zbrmvd5gX6wQHc8Ra9dQMn2J1YV7F3MG7hOcZKy1EmDYjzgdIg873J5Zj4f3D8ee4RzkOaCy5wsNJlbo/+slider1.jpg'/>
</div>

<div class='imageElement'>
<h2>&lt;script&gt;var startposts = 1; numposts = 2; var showposttitle = true; showpostdate = false; var showpostsummary = false; var numchars = 0; &lt;/script&gt;&lt;script src=&quot;http://www.bloggertricksandtoolz.com/feeds/posts/default?orderby=published&amp;alt=json-in-script&amp;callback=rp&quot;&gt;
&lt;/script&gt;</h2>
<p>&lt;script&gt;var startposts = 1; numposts = 2; var showposttitle = false; showpostdate = false; var showpostsummary = true; var numchars = 150; &lt;/script&gt;&lt;script src=&quot;http://www.bloggertricksandtoolz.com/feeds/posts/default?orderby=published&amp;alt=json-in-script&amp;callback=rp&quot;&gt;
&lt;/script&gt;</p>

<a class='open' href='#' title='Read More'/>
<img class='full' src='https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhcPXNK_qRc2Lb1RiJVIasnkqVb1GZQI26GG-rSSMUKDOtoCZkQ3mXBMEIlmng8fQbNwksE4bKctroEabjAyddUID-Tls_66t62ZpzFOHM91Wt2V45et-5ULKST8X3OBKVhXAv5r9PLmxHU/+slider2.jpg'/>
<img class='thumbnail' src='https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhcPXNK_qRc2Lb1RiJVIasnkqVb1GZQI26GG-rSSMUKDOtoCZkQ3mXBMEIlmng8fQbNwksE4bKctroEabjAyddUID-Tls_66t62ZpzFOHM91Wt2V45et-5ULKST8X3OBKVhXAv5r9PLmxHU/+slider2.jpg'/>
</div>

<div class='imageElement'>
<h2>&lt;script&gt;var startposts = 2; numposts = 3; var showposttitle = true; showpostdate = false; var showpostsummary = false; var numchars = 0; &lt;/script&gt;&lt;script src=&quot;http://www.bloggertricksandtoolz.com/feeds/posts/default?orderby=published&amp;alt=json-in-script&amp;callback=rp&quot;&gt;
&lt;/script&gt;</h2>
<p>&lt;script&gt;var startposts = 2; numposts = 3; var showposttitle = false; showpostdate = false; var showpostsummary = true; var numchars = 150; &lt;/script&gt;&lt;script src=&quot;http://www.bloggertricksandtoolz.com/feeds/posts/default?orderby=published&amp;alt=json-in-script&amp;callback=rp&quot;&gt;
&lt;/script&gt;</p>

<a class='open' href='#' title='Read More'/>
<img class='full' src='https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiXFEhr_NbGNStBkO_CVTDoW606OZXPVlcKowgF33AbDK1yTPLQ64N9HQMphO5aQO1BO1N_vkQQhvGgTgmDK7gzTWgP-0CFqcHBehG-XLbE19a85pnEsr6XBZInuyjd2JMHrhNeraJddusL/+slider3.jpg'/>
<img class='thumbnail' src='https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiXFEhr_NbGNStBkO_CVTDoW606OZXPVlcKowgF33AbDK1yTPLQ64N9HQMphO5aQO1BO1N_vkQQhvGgTgmDK7gzTWgP-0CFqcHBehG-XLbE19a85pnEsr6XBZInuyjd2JMHrhNeraJddusL/+slider3.jpg'/>
</div>

<div class='imageElement'>
<h2>&lt;script&gt;var startposts = 3; numposts = 4; var showposttitle = true; showpostdate = false; var showpostsummary = false; var numchars = 0; &lt;/script&gt;&lt;script src=&quot;http://www.bloggertricksandtoolz.com/feeds/posts/default?orderby=published&amp;alt=json-in-script&amp;callback=rp&quot;&gt;
&lt;/script&gt;</h2>
<p>&lt;script&gt;var startposts = 3; numposts = 4; var showposttitle = false; showpostdate = false; var showpostsummary = true; var numchars = 150; &lt;/script&gt;&lt;script src=&quot;http://www.bloggertricksandtoolz.com/feeds/posts/default?orderby=published&amp;alt=json-in-script&amp;callback=rp&quot;&gt;
&lt;/script&gt;</p>

<a class='open' href='#' title='Read More'/>
<img class='full' src='https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgPHGRXMv4l7prYc3_7rb2cHAkzUxqyVNrFzAeWiJRUNIuaHyw0BMy8i8qTSgALKsnmAFz0KRj6qFYOja7QXU4hXyxWhOH7zEnBGRCT0RmH9YGa8dbx7U48vfoIcZGS9tuNMTaS_9tKeESI/+slider4.jpg'/>
<img class='thumbnail' src='https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgPHGRXMv4l7prYc3_7rb2cHAkzUxqyVNrFzAeWiJRUNIuaHyw0BMy8i8qTSgALKsnmAFz0KRj6qFYOja7QXU4hXyxWhOH7zEnBGRCT0RmH9YGa8dbx7U48vfoIcZGS9tuNMTaS_9tKeESI/+slider4.jpg'/>
</div>

<div class='imageElement'>
<h2>&lt;script&gt;var startposts = 4; numposts = 5; var showposttitle = true; showpostdate = false; var showpostsummary = false; var numchars = 0; &lt;/script&gt;&lt;script src=&quot;http://www.bloggertricksandtoolz.com/feeds/posts/default?orderby=published&amp;alt=json-in-script&amp;callback=rp&quot;&gt;
&lt;/script&gt;</h2>
<p>&lt;script&gt;var startposts = 4; numposts = 5; var showposttitle = false; showpostdate = false; var showpostsummary = true; var numchars = 150; &lt;/script&gt;&lt;script src=&quot;http://www.bloggertricksandtoolz.com/feeds/posts/default?orderby=published&amp;alt=json-in-script&amp;callback=rp&quot;&gt;
&lt;/script&gt;</p>

<a class='open' href='#' title='Read More'/>
<img class='full' src='https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhlL5l3Ah7MyhVOnzwA9tC5YnMq5aO5SNxQRh94j-9tzwlamzJqe7AIbDpOcQkzIrxsn5uO4pY-O5TQ857CNMBN3zNaHOeoKqwG-He13nrmG5lGzOMA10L1B0iuDpNFtu1VQzKZwaA8Z-mT/+slider5.jpg'/>
<img class='thumbnail' src='https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhlL5l3Ah7MyhVOnzwA9tC5YnMq5aO5SNxQRh94j-9tzwlamzJqe7AIbDpOcQkzIrxsn5uO4pY-O5TQ857CNMBN3zNaHOeoKqwG-He13nrmG5lGzOMA10L1B0iuDpNFtu1VQzKZwaA8Z-mT/+slider5.jpg'/>
</div>

</div>
</div>
</div>
<div class='bot'/>
</div></div></div>

Note: Replace "http://btricks-tools.blogspot.com/" with your blog address.
          Replace images addresses with your images addresses.

You can place above code as your choice.For explanation I place it just before <div id='main-wrapper'> .

6.Now save your template and you are done.