Your IP : 216.73.216.240
// ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
// @license: Mad4Media Javascipt License - copyright Mad4Media - Fahrettin Kutyol - All rights reserved ++
// (re-) publishing or forking for any purpose of commercial or non-commercial use is not allowed. ++
// ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
var multiIndexOf=function(_1,_2){if(!dojo.isIE){return _1.indexOf(_2);}for(var i=0;i<_1.length;i++){if(_1[i]==_2){return i;}}return -1;};var FieldBalloon={node:null,contentNode:null,target:null,multiple:0,heap:null,name:null,namespace:null,decreasing:[],addCallBack:null,removeCallBack:null,isAlias:0,switchAliasNode:null,allowed:null,showsCurrent:null,parseMode:0,show:function(_3,_4,_5,_6){if(this.showsCurrent==_3){this.hide();}this.target=dojo.byId("sel_"+_3);this.name=_3;this.namespace=_4;if(_6!==undefined&&_6!=null){var _7=_6.split(",");for(t in _7){_7[t]=parseInt(_7[t]);}this.allowed=_7;}else{this.allowed=null;}var ps=(_4!==undefined&&ProformsSelectors[_4]!==undefined)?ProformsSelectors[_4]:null;this.heap=ps?ps.heap:"static";this.multiple=_5;if(this.heap=="decreasing"){if(this.decreasing[_4]===undefined){this.decreasing[_4]=dojo.clone(eids);}}if(!this.parseMode){this.create();var _8=_ViewportOffset(dojo.byId("selector_"+_3),true);var _9=_docScroll(dojo.byId("selector_"+_3));_8.t+=_9.top-222;_8.l+=_9.left;dojo.style(this.node,{opacity:0,left:_8.l+"px",top:_8.t+"px"});dojo.fadeIn({node:this.node}).play();}},hide:function(){dojo.fadeOut({node:this.node,onEnd:function(){dojo.style(FieldBalloon.node,{left:"-9999em"});}}).play();},create:function(){var _a=(this.decreasing[this.namespace]!==undefined);var _b="";var _c=_a?this.decreasing[this.namespace]:eids;var l=_c.length;var fe=formElements;for(var t=0;t<l;t++){var _d="_"+_c[t];var _e=1;if(this.allowed){var _f=fe[_d].form;_e=(multiIndexOf(this.allowed,_f)!=-1);}if(_e){var _10="";if(this.isAlias){_10=fe[_d].alias?"{"+fe[_d].alias+"}":fe[_d].question;}else{_10=fe[_d].question?fe[_d].question:"{"+fe[_d].alias+"}";}if(_10.length>70){_10=_10.slice(0,67)+"...";}_b+="<a onclick=\"javascript: FieldBalloon.add("+_c[t]+"); return false; \">"+_10+"</a>";}}this.contentNode.innerHTML=_b;},add:function(_11){var _12=dojo.byId("selwrap_"+this.name);var _13=_12.getAttribute("spanwidth");var _14=document.createElement("SPAN");dojo.style(_14,{width:_13});_14.id="span_"+this.name;_14.className="selectedElements";var IMG=document.createElement("IMG");IMG.src=M4J_IMAGES+"remove.png";IMG.className="add";IMG.id="IMG_"+this.name;IMG.selWrap=_12;IMG.span=_14;IMG.target=this.target;IMG.removeCallBack=this.removeCallBack?this.removeCallBack:null;IMG.decreasing=(this.decreasing[this.namespace]!==undefined)?this.decreasing[this.namespace]:null;IMG.elementID=_11;dojo.connect(IMG,"onclick",function(el){var te=this.target.value.split(",");for(t in te){te[t]=parseInt(te[t]);}var idx=multiIndexOf(te,this.elementID);if(idx!=-1){te.splice(idx,1);}this.target.value=te.join(",");if(this.decreasing){this.decreasing.push(parseInt(this.elementID));}if(this.removeCallBack){this.removeCallBack();}this.selWrap.removeChild(this.span);this.selWrap.removeChild(this);FieldBalloon.create();});var key="_"+_11;var fe=formElements[key];_14.question=fe.question;_14.alias=fe.alias;if(this.isAlias){_14.innerHTML=fe.alias?"{"+fe.alias+"}":fe.question;}else{_14.innerHTML=fe.question?fe.question:"{"+fe.alias+"}";}if(this.multiple){}else{_12.innerHTML="";}_12.appendChild(_14);_12.appendChild(IMG);if(this.decreasing[this.namespace]!==undefined){var idx=multiIndexOf(this.decreasing[this.namespace],_11);if(idx!=-1){this.decreasing[this.namespace].splice(idx,1);}if(!this.parseMode){if(!this.multiple){var val=parseInt(this.target.value);if(this.target.value!=""&&val!==0){this.decreasing[this.namespace].push(val);this.target.value="";}}this.create();}}if(!this.parseMode){if(!this.target.value){this.target.value=_11;}else{this.target.value+=","+_11;}if(!this.multiple){this.hide();}if(this.addCallBack){this.addCallBack();}}},switchAlias:function(){this.isAlias=this.isAlias?0:1;this.switchAliasNode.innerHTML=this.isAlias?this.switchAliasNode.getAttribute("question"):this.switchAliasNode.getAttribute("alias");var _15=dojo.query(".selectedElements");dojo.forEach(_15,function(_16){if(FieldBalloon.isAlias){_16.innerHTML=_16.alias?"{"+_16.alias+"}":_16.question;}else{_16.innerHTML=_16.question?_16.question:"{"+_16.alias+"}";}});this.create();},parse:function(){this.parseMode=1;var _17=dojo.query(".selectorinput");dojo.forEach(_17,dojo.hitch(this,function(_18){var _19=this.checkRegular(_18);if(_19!==undefined&&_19!=null&&_19!=""){var _1a=_18.getAttribute("name");var _1b=_18.getAttribute("namespace");var _1c=_18.getAttribute("allowed");_1c=(_1c===undefined)?null:_1c;var _1d=parseInt(_18.getAttribute("multiple"));this.show(_1a,_1b,_1d,_1c);if(multiIndexOf(_19,",")!=-1){var _1e=_19.split(",");for(t in _1e){if((typeof _1e[t])!="function"&&(typeof _1e[t])!="object"){this.add(parseInt(_1e[t]));}}}else{this.add(parseInt(_19));}}}));this.parseMode=0;},checkRegular:function(_1f){var _20=_1f.value;if(multiIndexOf(_20,",")!=-1){var _21=_20.split(",");var _22=[];for(t in _21){if((typeof _21[t])!="function"&&(typeof _21[t])!="object"&&dojo.indexOf(eids,parseInt(_21[t]))!==-1){_22.push(parseInt(_21[t]));}}_20=_22.join(",");}else{_20=(dojo.indexOf(eids,parseInt(_20))!==-1)?_20:null;}_1f.value=_20;return _20;}};var AliasBalloon={node:null,contentNode:null,target:null,extended:0,extendedOpt:["{J_OPT_IN}","{J_OPT_OUT}"],extendedUser:["{J_USER_NAME}","{J_USER_REALNAME}","{J_USER_IP}"],addCallBack:null,removeCallBack:null,isEditor:0,show:function(_23,_24,_25,_26){this.isEditor=_26;this.target=(!_26)?dojo.byId("ATA_"+_23):_23;this.extended=parseInt(_25);this.create();var _27=_ViewportOffset(_24,true);var _28=_docScroll(_24);_27.t+=_28.top-222;_27.l+=_28.left;dojo.style(this.node,{opacity:0,left:_27.l+"px",top:_27.t+"px"});dojo.fadeIn({node:this.node}).play();},hide:function(){dojo.fadeOut({node:this.node,onEnd:function(){dojo.style(AliasBalloon.node,{left:"-9999em"});}}).play();},create:function(){var _29="";if(this.extended>1){if(this.extended!=2){var ol=this.extendedOpt.length;for(var t=0;t<ol;t++){_29+="<a onclick=\"javascript: AliasBalloon.add('"+this.extendedOpt[t]+"'); return false; \">"+this.extendedOpt[t]+"</a>";}}var xl=this.extendedUser.length;for(var t=0;t<xl;t++){_29+="<a onclick=\"javascript: AliasBalloon.add('"+this.extendedUser[t]+"'); return false; \">"+this.extendedUser[t]+"</a>";}}var _2a=eids;var l=_2a.length;var fe=formElements;for(var t=0;t<l;t++){var key="_"+_2a[t];if(fe[key].alias){var _2b="{"+fe[key].alias+"}";if(_2b.length>70){_2b=_2b.slice(0,67)+"...";}_29+="<a onclick=\"javascript: AliasBalloon.add('"+_2b+"'); return false; \">"+_2b+"</a>";}}this.contentNode.innerHTML=_29;},add:function(_2c){if(this.isEditor){if(typeof IeCursorFix=="function"){IeCursorFix();}jInsertEditorText(_2c,this.target);}else{var _2d=this.target;var _2e=_2d.selectionStart;if(dojo.isIE){var c="",sel=document.selection.createRange(),dul=sel.duplicate(),len=0;dul.moveToElementText(_2d);sel.text=c;len=dul.text.indexOf(c);sel.moveStart("character",-1);sel.text="";_2e=len;}_2d.value=_2d.value.substr(0,_2e)+_2c+_2d.value.substr(_2e,_2d.value.length);}return false;}};dojo.addOnLoad(function(){var _2f=dojo.byId("fieldBalloon");document.body.appendChild(_2f);FieldBalloon.node=_2f;FieldBalloon.contentNode=dojo.byId("fbContentNode");FieldBalloon.switchAliasNode=dojo.byId("switchAliasNode");dojo.style(_2f,{opacity:1});dojo.connect(dojo.byId("fbBalloonClose"),"onclick",function(){FieldBalloon.hide();});FieldBalloon.parse();var _30=dojo.byId("aliasBalloon");document.body.appendChild(_30);AliasBalloon.node=_30;AliasBalloon.contentNode=dojo.byId("aliasContentNode");dojo.style(_30,{opacity:1});dojo.connect(dojo.byId("aliasBalloonClose"),"onclick",function(){AliasBalloon.hide();});if(IS_J3){dojo.query("FORM#appForm SELECT").style({height:"auto"});}});function appFormSubmit(){var _31=eAreas.length;if(_31!=0){for(t=0;t<_31;t++){eAL.toggle(eAreas[t]);}}dojo.byId("appForm").submit();return true;};