	function LoadEditor() {
		var oFCKeditor = new FCKeditor('FCKeditor1', '100%', '100%', 'Default');
		oFCKeditor.BasePath	= '/webAppLib/applications/cms/fckeditor/';
		oFCKeditor.ReplaceTextarea();
	}
	//--------------------------------------------------------
	function pollshow(object, val) {
		if (document.getElementById(object)) {
			document.getElementById(object).style.visibility = val;
			if (val == 'hidden') {
				document.getElementById(object).style.display = 'none';
			} else {
				document.getElementById(object).style.display = 'block';
			}
		}
	}
	//--------------------------------------------------------
	var pollPosition =(function(){
		function resolveObject(s){
			if (document.getElementById && document.getElementById(s)!=null){
				return document.getElementById(s);
			} else if(document.all && document.all[s]!=null) { 
				return document.all[s];
			} else if(document.anchors && document.anchors.length && document.anchors.length>0 && document.anchors[0].x) {
				for(var i=0;i<document.anchors.length;i++){if(document.anchors[i].name==s){
					return document.anchors[i];
				}
			}
		}
	}
	var pos ={};
	pos.$VERSION = 1.0;
	pos.set = function(o,left,top){
		if(typeof(o)=="string"){
			o = resolveObject(o);
		} if (o==null || !o.style) {
			return false;
		} if (typeof(left)=="object") {
			var pos = left;
			left = pos.left;
			top = pos.top;
		} 
		o.style.left = left + "px";
		o.style.top = top + "px";
		return true;
	};
	pos.get = function(o){
	var fixBrowserQuirks = true;
	if(typeof(o)=="string"){
		o = resolveObject(o);
	}
	if(o==null){
		return null;
	}
	var left = 0;
	var top = 0;
	var width = 0;
	var height = 0;
	var parentNode = null;
	var offsetParent = null;
	offsetParent = o.offsetParent;
	var originalObject = o;
	var el = o;
	while(el.parentNode!=null){
		el = el.parentNode;
		if (el.offsetParent==null){}
		else{
			var considerScroll = true;
			if(fixBrowserQuirks && window.opera){
				if(el==originalObject.parentNode || el.nodeName=="TR"){
					considerScroll = false;
				}
			}if(considerScroll){
				if(el.scrollTop && el.scrollTop>0){
					top -= el.scrollTop;
				}if(el.scrollLeft && el.scrollLeft>0){
					left -= el.scrollLeft;
				}
			}
		} if (el == offsetParent){
			left += o.offsetLeft;
			if(el.clientLeft && el.nodeName!="TABLE"){
				left += el.clientLeft;
			}
			top += o.offsetTop;
			if(el.clientTop && el.nodeName!="TABLE"){
				top += el.clientTop;
			}
			o = el;
			if(o.offsetParent==null){
				if(o.offsetLeft){
					left += o.offsetLeft;
				}
				if(o.offsetTop){
					top += o.offsetTop;
				}
			}
			offsetParent = o.offsetParent;
		}
	}
	if(originalObject.offsetWidth){
		width = originalObject.offsetWidth;
	} if (originalObject.offsetHeight){
		height = originalObject.offsetHeight;
	} 
	return{'left':left, 'top':top, 'width':width, 'height':height};};
	pos.getCenter = function(o,altx,alty){
		if (alty==null) {
			alty=0;	
		}
		if (altx==null) {
			altx=0;	
		}
		var c = this.get(o);
		if(c==null){
			return null;
		}
		var browserName=navigator.appName; 
		if (browserName=="Microsoft Internet Explorer") {
			var ww_left = -30;
			var ww_top = 12;
		} else {
			var ww_left = -30;
			var ww_top = 12;
		}
		c.left = c.left + ww_left + altx;
		c.top = c.top + ww_top + alty;
		return c;
	};return pos;})();
	//--------------------------------------------------------
	function Resize(){
		document.top = 100;
		document.left = 100;
		var img_width = document.getElementById('content').offsetWidth  + 20;
		//var img_height = document.content.height + 81;
		self.resizeTo(img_width, 500);
	}
	//--------------------------------------------------------
	function add_bookmark(title){
	  if ((navigator.appName == "Microsoft Internet Explorer") && (parseInt(navigator.appVersion) >= 4)) {
	  	window.external.AddFavorite(location.href,title);
	  } else if (navigator.appName == "Netscape") {
		window.sidebar.addPanel(title,window.location,"");
	  } else {
		alert("Press CTRL-D (Netscape) or CTRL-T (Opera) to bookmark");
	  }
	}
	//--------------------------------------------------------
	function popup(url, w, h) {
		var h = h + 25;
		var w = w + 20
		var winl = 100;
		var wint = 100;
		var mypage = window.open(url, "mypage", "height="+h+",width="+w+",top="+wint+",left="+winl+",scrollbars=no,resizable=yes");
	}
	//--------------------------------------------------------

