function setUpMenu(){var n=responsiveNav("#top-menu",{animate:!0,transition:250,label:"Menu",insert:"after",customToggle:"custom-nav-toggle",openPos:"relative",jsClass:"js",init:function(){},open:function(){},close:function(){}});$("#top-menu li.dropdown").hover(function(){$(this).children("a:first").addClass("hover")},function(){$(this).children("a:first").removeClass("hover")}).bind("touchstart",function(){}).bind("touchend",function(){})}function setUpSocial(){var r=function(n,t,i,r){var u=window.screenLeft!==undefined?window.screenLeft:screen.left,f=window.screenTop!==undefined?window.screenTop:screen.top,e=window.innerWidth?window.innerWidth:document.documentElement.clientWidth?document.documentElement.clientWidth:screen.width,o=window.innerHeight?window.innerHeight:document.documentElement.clientHeight?document.documentElement.clientHeight:screen.height,s=e/2-i/2+u,h=o/3-r/3+f,c=window.open(n,t,"scrollbars=yes, width="+i+", height="+r+", top="+h+", left="+s);window.focus&&c.focus()};$(".share ul li a.popup").on("click",function(n){var t=$(this);r(t.attr("href"),"Share",580,470);n.preventDefault()});var n,i=$(document).find("title").first().text()=="WSIS Forum 2016"?"WSIS Forum 2016 | 2–6 May 2016, Geneva, Switzerland":$(document).find("title").first().text(),t=document.URL;n="mailto:?subject=";n+=encodeURIComponent(i).replace(/[!'()]/g,escape).replace(/\*/g,"%2A");n+="&body=The World Summit on the Information Society Forum 2016 represents the world's largest annual gathering of the 'ICT for development' community. The forum will be held in the ITU Headquarters, Geneva, from 2–6 May 2016. This forum will provide structured opportunities to network, learn and participate in multi-stakeholder discussions and consultations on WSIS implementation. This event builds upon the tradition of annual WSIS May meetings, and its format is the result of open consultations with all WSIS Stakeholders. The WSIS Forum 2016 Open Consultation Process on the Thematic Aspects and Innovations on the Format will aim at ensuring the participatory and inclusive spirit of the WSIS Forum 2016 by actively engaging governments, civil society, the private sector and intergovernmental organizations in the preparatory process. The Agenda and program of the WSIS Forum will be built on the basis of the official submissions received during the Open Consultation Process.";n+="%0A%0A"+encodeURIComponent(t).replace(/[!'()]/g,escape).replace(/\*/g,"%2A");$(".share ul li.email a").attr("href",n).on("click",function(){ga("send","event","social","share","email")});n="https://www.facebook.com/sharer/sharer.php?u="+t;$(".share ul li.facebook a").attr("href",n).on("click",function(){ga("send","event","social","share","facebook")});n="//twitter.com/home?status=";n+=encodeURIComponent(i+" #wsis ").replace(/[!'()]/g,escape).replace(/\*/g,"%2A");n+=encodeURIComponent(t).replace(/[!'()]/g,escape).replace(/\*/g,"%2A");$(".share ul li.twitter a").attr("href",n).on("click",function(){ga("send","event","social","share","twitter")});n="//www.linkedin.com/shareArticle?mini=true&url="+t+"&title=";n+=encodeURIComponent(i).replace(/[!'()]/g,escape).replace(/\*/g,"%2A");n+="&summary="+encodeURIComponent("The World Summit on the Information Society Forum 2016 represents the world's largest annual gathering of the 'ICT for development' community. The forum will be held in the ITU Headquarters, Geneva, from 2–6 May 2016.").replace(/[!'()]/g,escape).replace(/\*/g,"%2A");$(".share ul li.linkedin a").attr("href",n).on("click",function(){ga("send","event","social","share","linkedin")});n="https://plus.google.com/share?url="+t;$(".share ul li.googleplus a").attr("href",n).on("click",function(){ga("send","event","social","share","googleplus")});$(".follow ul li.facebook a").on("click",function(){ga("send","event","social","follow","facebook")});$(".follow ul li.twitter a").on("click",function(){ga("send","event","social","follow","twitter")});$(".follow ul li.youtube a").on("click",function(){ga("send","event","social","follow","youtube")})}function setUpLinks(){$("a.blank,.button.blank").click(function(n){n.preventDefault()});$(".jumplink").click(function(n){n.preventDefault();$("html,body").animate({scrollTop:$("#"+this.hash.substring(1)).offset().top},500);this.hash!="#top"?history.pushState?history.pushState(null,null,this.hash):location.hash=this.hash:location.hash="#"})}function css_browser_selector(n){var i=n.toLowerCase(),t=function(n){return i.indexOf(n)>-1},s=new RegExp("msie ([0-9]{1,}[.0-9]{0,})"),h=new RegExp("trident/.*rv:([0-9]{1,}[.0-9]{0,})"),r="gecko",f="webkit",o="safari",e="opera",u="mobile",l=document.documentElement,a=[!/opera|webtv/i.test(i)&&(s.test(i)||h.test(i))?"ie ie"+RegExp.$1:t("firefox/2")?r+" ff ff2":t("firefox/3.5")?r+" ff ff3 ff3_5":t("firefox/3.6")?r+" ff ff3 ff3_6":t("firefox/3")?r+" ff ff3":t("gecko/")?r:t("opera")?e+(/version\/(\d+)/.test(i)?" "+e+RegExp.$1:/opera(\s|\/)(\d+)/.test(i)?" "+e+RegExp.$2:""):t("konqueror")?"konqueror":t("blackberry")?u+" blackberry":t("android")?u+" android":t("chrome")?f+" chrome":t("iron")?f+" iron":t("applewebkit/")?f+" "+o+(/version\/(\d+)/.test(i)?" "+o+RegExp.$1:""):t("mozilla/")?r:"",t("j2me")?u+" j2me":t("iphone")?u+" iphone":t("ipod")?u+" ipod":t("ipad")?u+" ipad":t("mac")?"mac":t("darwin")?"mac":t("webtv")?"webtv":t("win")?"win"+(t("windows nt 6.0")?" vista":""):t("freebsd")?"freebsd":t("x11")||t("linux")?"linux":"","js"];return c=a.join(" "),l.className+=" "+c,c}var responsiveNav=function(n,t){var y=!!window.getComputedStyle;y||(window.getComputedStyle=function(n){return this.el=n,this.getPropertyValue=function(t){var i=/(\-([a-z]){1})/g;return t==="float"&&(t="styleFloat"),i.test(t)&&(t=t.replace(i,function(){return arguments[2].toUpperCase()})),n.currentStyle[t]?n.currentStyle[t]:null},this});var i,u,r,f=document.createElement("style"),l,a,o=function(n,t,i,r){if("addEventListener"in n)try{n.addEventListener(t,i,r)}catch(u){if(typeof i=="object"&&i.handleEvent)n.addEventListener(t,function(n){i.handleEvent.call(i,n)},r);else throw u;}else"attachEvent"in n&&(typeof i=="object"&&i.handleEvent?n.attachEvent("on"+t,function(){i.handleEvent.call(i)}):n.attachEvent("on"+t,i))},e=function(n,t,i,r){if("removeEventListener"in n)try{n.removeEventListener(t,i,r)}catch(u){if(typeof i=="object"&&i.handleEvent)n.removeEventListener(t,function(n){i.handleEvent.call(i,n)},r);else throw u;}else"detachEvent"in n&&(typeof i=="object"&&i.handleEvent?n.detachEvent("on"+t,function(){i.handleEvent.call(i)}):n.detachEvent("on"+t,i))},p=function(n){var i,t;if(n.children.length<1)throw new Error("The Nav container has no containing elements");for(i=[],t=0;t<n.children.length;t++)n.children[t].nodeType===1&&i.push(n.children[t]);return i},s=function(n,t){for(var i in t)n.setAttribute(i,t[i])},h=function(n,t){n.className.indexOf(t)!==0&&(n.className+=" "+t,n.className=n.className.replace(/(^\s*)|(\s*$)/g,""))},c=function(n,t){var i=new RegExp("(\\s|^)"+t+"(\\s|$)");n.className=n.className.replace(i," ").replace(/(^\s*)|(\s*$)/g,"")},v=function(n,t){var r;this.options={animate:!0,transition:250,label:"Menu",insert:"after",customToggle:"",openPos:"relative",jsClass:"js",init:function(){},open:function(){},close:function(){}};for(r in t)this.options[r]=t[r];if(h(document.documentElement,this.options.jsClass),this.wrapperEl=n.replace("#",""),document.getElementById(this.wrapperEl))this.wrapper=document.getElementById(this.wrapperEl);else if(document.querySelector(this.wrapperEl))this.wrapper=document.querySelector(this.wrapperEl);else throw new Error("The nav element you are trying to select doesn't exist");this.wrapper.inner=p(this.wrapper);u=this.options;i=this.wrapper;this._init(this)};return v.prototype={destroy:function(){this._removeStyles();c(i,"closed");c(i,"opened");c(i,"nav-collapse");i.removeAttribute("style");i.removeAttribute("aria-hidden");i=null;e(window,"resize",this,!1);e(document.body,"touchmove",this,!1);e(r,"touchstart",this,!1);e(r,"touchend",this,!1);e(r,"mouseup",this,!1);e(r,"keyup",this,!1);e(r,"click",this,!1);u.customToggle?r.removeAttribute("aria-hidden"):r.parentNode.removeChild(r)},toggle:function(){l===!0&&(a?(c(i,"opened"),h(i,"closed"),s(i,{"aria-hidden":"true"}),u.animate?(l=!1,setTimeout(function(){i.style.position="absolute";l=!0},u.transition+10)):i.style.position="absolute",a=!1,u.close()):(c(i,"closed"),h(i,"opened"),i.style.position=u.openPos,s(i,{"aria-hidden":"false"}),a=!0,u.open()))},resize:function(){window.getComputedStyle(r,null).getPropertyValue("display")!=="none"?(s(r,{"aria-hidden":"false"}),i.className.match(/(^|\s)closed(\s|$)/)&&(s(i,{"aria-hidden":"true"}),i.style.position="absolute"),this._createStyles(),this._calcHeight()):(s(r,{"aria-hidden":"true"}),s(i,{"aria-hidden":"false"}),i.style.position=u.openPos,this._removeStyles())},handleEvent:function(n){var t=n||window.event;switch(t.type){case"touchstart":this._onTouchStart(t);break;case"touchmove":this._onTouchMove(t);break;case"touchend":case"mouseup":this._onTouchEnd(t);break;case"click":this._preventDefault(t);break;case"keyup":this._onKeyUp(t);break;case"resize":this.resize(t)}},_init:function(){h(i,"nav-collapse");h(i,"closed");l=!0;a=!1;this._createToggle();this._transitions();this.resize();o(window,"resize",this,!1);o(document.body,"touchmove",this,!1);o(r,"touchstart",this,!1);o(r,"touchend",this,!1);o(r,"mouseup",this,!1);o(r,"keyup",this,!1);o(r,"click",this,!1);u.init()},_createStyles:function(){f.parentNode||(f.type="text/css",document.getElementsByTagName("head")[0].appendChild(f))},_removeStyles:function(){f.parentNode&&f.parentNode.removeChild(f)},_createToggle:function(){var n,t;if(u.customToggle)if(t=u.customToggle.replace("#",""),document.getElementById(t))r=document.getElementById(t);else if(document.querySelector(t))r=document.querySelector(t);else throw new Error("The custom nav toggle you are trying to select doesn't exist");else n=document.createElement("a"),n.innerHTML=u.label,s(n,{href:"#","class":"nav-toggle"}),u.insert==="after"?i.parentNode.insertBefore(n,i.nextSibling):i.parentNode.insertBefore(n,i),r=n},_preventDefault:function(n){n.preventDefault?(n.preventDefault(),n.stopPropagation()):n.returnValue=!1},_onTouchStart:function(n){n.stopPropagation();this.startX=n.touches[0].clientX;this.startY=n.touches[0].clientY;this.touchHasMoved=!1;e(r,"mouseup",this,!1)},_onTouchMove:function(n){(Math.abs(n.touches[0].clientX-this.startX)>10||Math.abs(n.touches[0].clientY-this.startY)>10)&&(this.touchHasMoved=!0)},_onTouchEnd:function(n){var t,r;if(this._preventDefault(n),!this.touchHasMoved){if(n.type==="touchend"){this.toggle(n);t=this;i.addEventListener("click",t._preventDefault,!0);setTimeout(function(){i.removeEventListener("click",t._preventDefault,!0)},u.transition+100);return}r=n||window.event;r.which===3||r.button===2||this.toggle(n)}},_onKeyUp:function(n){var t=n||window.event;t.keyCode===13&&this.toggle(n)},_transitions:function(){if(u.animate){var n=i.style,t="max-height "+u.transition+"ms";n.WebkitTransition=t;n.MozTransition=t;n.OTransition=t;n.transition=t}},_calcHeight:function(){for(var n,r=0,t=0;t<i.inner.length;t++)r+=i.inner[t].offsetHeight;n=".nav-collapse.opened{max-height:"+r+"px}";f.styleSheet?f.styleSheet.cssText=n:f.innerHTML=n;n=""}},new v(n,t)};!function(n,t,i){n.fn.scrollUp=function(t){n.data(i.body,"scrollUp")||(n.data(i.body,"scrollUp",!0),n.fn.scrollUp.init(t))};n.fn.scrollUp.init=function(r){var u=n.fn.scrollUp.settings=n.extend({},n.fn.scrollUp.defaults,r),e=u.scrollTitle?u.scrollTitle:u.scrollText,f=n("<a/>",{id:u.scrollName,href:"#top",title:e}).appendTo("body");u.scrollImg||f.html(u.scrollText);f.css({display:"none",position:"fixed",zIndex:u.zIndex});u.activeOverlay&&n("<div/>",{id:u.scrollName+"-active"}).css({position:"absolute",top:u.scrollDistance+"px",width:"100%",borderTop:"1px dotted"+u.activeOverlay,zIndex:u.zIndex}).appendTo("body");scrollEvent=n(t).scroll(function(){switch(scrollDis="top"===u.scrollFrom?u.scrollDistance:n(i).height()-n(t).height()-u.scrollDistance,u.animation){case"fade":n(n(t).scrollTop()>scrollDis?f.fadeIn(u.animationInSpeed):f.fadeOut(u.animationOutSpeed));break;case"slide":n(n(t).scrollTop()>scrollDis?f.slideDown(u.animationInSpeed):f.slideUp(u.animationOutSpeed));break;default:n(n(t).scrollTop()>scrollDis?f.show(0):f.hide(0))}});f.click(function(t){t.preventDefault();n("html, body").animate({scrollTop:0},u.topSpeed,u.easingType)})};n.fn.scrollUp.defaults={scrollName:"scrollUp",scrollDistance:300,scrollFrom:"top",scrollSpeed:300,easingType:"linear",animation:"fade",animationInSpeed:200,animationOutSpeed:200,scrollText:"Scroll to top",scrollTitle:!1,scrollImg:!1,activeOverlay:!1,zIndex:2147483647};n.fn.scrollUp.destroy=function(r){n.removeData(i.body,"scrollUp");n("#"+n.fn.scrollUp.settings.scrollName).remove();n("#"+n.fn.scrollUp.settings.scrollName+"-active").remove();n.fn.jquery.split(".")[1]>=7?n(t).off("scroll",r):n(t).unbind("scroll",r)};n.scrollUp=n.fn.scrollUp}(jQuery,window,document);jQuery.fn.exists=function(){return this.length>0},function(n){n.extend({inArrayIn:function(t,i,r){if(typeof t!="string")return n.inArray.apply(this,arguments);if(i){var u=i.length;for(r=r?r<0?Math.max(0,u+r):r:0,t=t.toLowerCase();r<u;r++)if(r in i&&i[r].toLowerCase()==t)return r}return-1}})}(jQuery);$(document).ready(function(){setUpMenu();setUpLinks();$("#share.share").length&&setUpSocial();$.scrollUp({animation:"fade",scrollImg:{active:!0,type:"background",src:"http://www.itu.int/res/templates/wsis/inc/scrollup-master/img/top.png"},zIndex:1e3})});css_browser_selector(navigator.userAgent)