Drupal.behaviors.gaTrackerAttach=function(context){$('a',context).click(function(){var ga=Drupal.settings.googleanalytics,isInternal=new RegExp("^(https?):\/\/"+window.location.host,"i"),isInternalSpecial=new RegExp("(\/go\/.*)$","i"),isDownload=new RegExp("\\.("+ga.trackDownloadExtensions+")$","i");try{if(isInternal.test(this.href)){if(ga.trackDownload&&isDownload.test(this.href)){var extension=isDownload.exec(this.href);pageTracker._trackEvent("Downloads",extension[1].toUpperCase(),this.href.replace(isInternal,''))}else if(isInternalSpecial.test(this.href))pageTracker._trackPageview(this.href.replace(isInternal,''))}else if(ga.trackMailto&&$(this).is("a[href^=mailto:]")){pageTracker._trackEvent("Mails","Click",this.href.substring(7))}else if(ga.trackOutgoing)pageTracker._trackEvent("Outgoing links","Click",this.href)}catch(err){}})};(function($){Drupal.wysiwygInit=function(){if(/KDE/.test(navigator.vendor))return;jQuery.each(Drupal.wysiwyg.editor.init,function(editor){this(jQuery.extend(true,{},Drupal.settings.wysiwyg.configs[editor]))})};Drupal.behaviors.attachWysiwyg=function(context){if(/KDE/.test(navigator.vendor))return;$('.wysiwyg:not(.wysiwyg-processed)',context).each(function(){var params=Drupal.wysiwyg.getParams(this),$this=$(this).addClass('wysiwyg-processed');if(($this.is(':input')&&$this.is(':checked'))||$this.is('div'))Drupal.wysiwygAttach(context,params);if($this.is(':input')){$this.change(function(){Drupal.wysiwygDetach(context,params);Drupal.wysiwygAttach(context,params)});if($.browser.msie)$this.click(function(){this.blur()})};$('#'+params.field).parents('form').submit(function(){Drupal.wysiwygDetach(context,params)})})};Drupal.wysiwygAttach=function(context,params){if(typeof Drupal.wysiwyg.editor.attach[params.editor]=='function'){Drupal.wysiwyg.instances[params.field]={};jQuery.extend(Drupal.wysiwyg.instances[params.field],params);if(typeof Drupal.wysiwyg.editor.instance[params.editor]=='object')jQuery.extend(Drupal.wysiwyg.instances[params.field],Drupal.wysiwyg.editor.instance[params.editor]);Drupal.wysiwyg.activeId=params.field;if(params.toggle){Drupal.wysiwygAttachToggleLink(context,params)}else $('#wysiwyg-toggle-'+params.field).hide();if(params.status){Drupal.wysiwyg.editor.attach[params.editor](context,params,(Drupal.settings.wysiwyg.configs[params.editor]?jQuery.extend(true,{},Drupal.settings.wysiwyg.configs[params.editor][params.format]):{}))}else{Drupal.wysiwyg.editor.attach.none(context,params);Drupal.wysiwyg.instances[params.field].editor='none'}}};Drupal.wysiwygDetach=function(context,params){var editor=Drupal.wysiwyg.instances[params.field].editor;if(jQuery.isFunction(Drupal.wysiwyg.editor.detach[editor]))Drupal.wysiwyg.editor.detach[editor](context,params)};Drupal.wysiwygAttachToggleLink=function(context,params){if(!$('#wysiwyg-toggle-'+params.field).length){var text=document.createTextNode(params.status?Drupal.settings.wysiwyg.disable:Drupal.settings.wysiwyg.enable),a=document.createElement('a');$(a).attr({id:'wysiwyg-toggle-'+params.field,href:'javascript:void(0);'}).append(text);var div=document.createElement('div');$(div).addClass('wysiwyg-toggle-wrapper').append(a);$('#'+params.field).after(div)};$('#wysiwyg-toggle-'+params.field).html(params.status?Drupal.settings.wysiwyg.disable:Drupal.settings.wysiwyg.enable).show().unbind('click').click(function(){if(params.status){params.status=false;Drupal.wysiwygDetach(context,params);Drupal.wysiwyg.editor.attach.none(context,params);Drupal.wysiwyg.instances[params.field]=Drupal.wysiwyg.editor.instance.none;Drupal.wysiwyg.instances[params.field].editor='none';$(this).html(Drupal.settings.wysiwyg.enable).blur()}else{Drupal.wysiwyg.editor.detach.none(context,params);Drupal.wysiwyg.getParams($('.wysiwyg-field-'+params.field+':checked, div.wysiwyg-field-'+params.field,context).get(0),params);params.status=true;Drupal.wysiwygAttach(context,params);$(this).html(Drupal.settings.wysiwyg.disable).blur()}});if(params.editor=='none')$('#wysiwyg-toggle-'+params.field).hide()};Drupal.wysiwyg.getParams=function(element,params){var classes=element.className.split(' '),params=params||{};for(var i in classes)if(classes[i].substr(0,8)=='wysiwyg-'){var parts=classes[i].split('-'),value=parts.slice(2).join('-');params[parts[1]]=value};params.format='format'+params.format;params.status=parseInt(params.status,10);params.toggle=parseInt(params.toggle,10);params.resizable=parseInt(params.resizable,10);return params};Drupal.wysiwygInit()})(jQuery)
