/*!
 * jquery.base64.js 0.1 - https://github.com/yckart/jquery.base64.js
 * Makes Base64 en & -decoding simpler as it is.
 *
 * Based upon: https://gist.github.com/Yaffle/1284012
 *
 * Copyright (c) 2012 Yannick Albert (http://yckart.com)
 * Licensed under the MIT license (http://www.opensource.org/licenses/mit-license.php).
 * 2013/02/10
 **/
(function(u){function k(b,a,d,e,h,l){b=String(b);for(var c=0,m=0,k=b.length,n="",f=0;m<k;){for(var g=b.charCodeAt(m),g=256>g?d[g]:-1,c=(c<<h)+g,f=f+h;f>=l;)f-=l,g=c>>f,n+=e.charAt(g),c^=g<<f;++m}!a&&0<f&&(n+=e.charAt(c<<l-f));return n}for(var h="",p=[256],q=[256],e=0,r={encode:function(b){return b.replace(/[\u0080-\u07ff]/g,function(a){a=a.charCodeAt(0);return String.fromCharCode(192|a>>6,128|a&63)}).replace(/[\u0800-\uffff]/g,function(a){a=a.charCodeAt(0);return String.fromCharCode(224|a>>12,128|a>>6&63,128|a&63)})},decode:function(b){return b.replace(/[\u00e0-\u00ef][\u0080-\u00bf][\u0080-\u00bf]/g,function(a){a=(a.charCodeAt(0)&15)<<12|(a.charCodeAt(1)&63)<<6|a.charCodeAt(2)&63;return String.fromCharCode(a)}).replace(/[\u00c0-\u00df][\u0080-\u00bf]/g,function(a){a=(a.charCodeAt(0)&31)<<6|a.charCodeAt(1)&63;return String.fromCharCode(a)})}};256>e;){var t=String.fromCharCode(e),h=h+t;q[e]=e;p[e]="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/".indexOf(t);++e}var d=u.base64=function(b,a,c){return a?d[b](a,c):b?null:this};d.btoa=d.encode=function(b,a){b=!1===d.raw||d.utf8encode||a?r.encode(b):b;b=k(b,!1,q,"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",8,6);return b+"\x3d\x3d\x3d\x3d".slice(b.length%4||4)};d.atob=d.decode=function(b,a){b=String(b).split("\x3d");var c=b.length;do--c,b[c]=k(b[c],!0,p,h,6,8);while(0<c);b=b.join("");return!1===d.raw||d.utf8decode||a?r.decode(b):b}})(jQuery);