var Claroline={};Claroline.version="1.9 rev. $Revision: 11432 $";Claroline.lang={};Claroline.getLang=function(a){if(Claroline.lang[a]){return Claroline.lang[a]}else{return a}};Claroline.json={isResponse:function(a){return(typeof a.responseType!="undefined")&&(typeof a.responseBody!="undefined")},isError:function(a){return Claroline.json.isResponse(a)&&(a.responseType=="error")},isSuccess:function(a){return Claroline.json.isResponse(a)&&(a.responseType=="success")},getResponseBody:function(a){return a.responseBody},handleJsonError:function(a){error=Claroline.json.getResponseBody(a);var b=Claroline.getLang("[Error] ")+error.error;if(error.errno){b+="("+error.errno+")"}if(error.file){b+=Claroline.getLang(" in ")+error.file;if(error.line){b+=Claroline.getLang(" at line ")+error.line}}if(error.trace){b+="\n\n"+error.trace}alert(b)}};Claroline.spoil=function(a){$(a).parents("div").children("div.spoiler").toggle();$(a).parents("div").children("a.reveal").toggleClass("showSpoiler");$(a).parents("div").children("a.reveal").toggleClass("hideSpoiler");return false};$(document).ready(function(){$("#loading").hide();$("#loading").ajaxStart(function(){$(this).show()});$("#loading").ajaxStop(function(){$(this).hide()})});function array_indexOf(a,c){for(var b=0;b<a.length;b++){if(a[b]==c){return b}}return -1}function isDefined(b){return typeof b!="undefined"}function isNull(b){return typeof b=="object"&&!b}function dump(a,g){var f="";if(!g){g=0}var e="";for(var b=0;b<g+1;b++){e+="    "}if(typeof(a)=="object"){for(var c in a){var d=a[c];if(typeof(d)=="object"){f+=e+"'"+c+"' ...\n";f+=dump(d,g+1)}else{f+=e+"'"+c+"' => \""+d+'"\n'}}}else{f="===>"+a+"<===("+typeof(a)+")"}return f};