/* >> jQuery $ recover */
	$ = jQuery.noConflict();
/* << */


/* >> jQuery extensions Version: rel-2-0-0 */
	;(function($){
		$.fn.extend({
			allAttrs: function(withoutList){
				var set = this;
				var attrsObjsList = [];
				withoutList = withoutList || [];
				set.each(
					function(n){
						var obj = {};
						for (var i = 0; i < this.attributes.length; ++i){
							var a = this.attributes[i];
							if ($.inArray(a.nodeName, withoutList) == -1){
								obj[a.nodeName] = a.nodeValue;
							}
						}
						attrsObjsList.push(obj);
					}
				);
				return attrsObjsList;
			},
			// if value is a jquery object .html() will be used to handle value.
			// Otherwise a dom xhtml string representation will be produced.
			xhtml: function(value){
				var i, j, node, nodeName, nodeType, attr, attrName, attrValue, str,
				singleTags = [
					'img', 'br', 'hr', 'area', 'base', 'basefont', 'col', 'frame', 
					'input', 'isindex', 'link', 'meta', 'param'
				],
				encodeSpecialChars = function(s){
					s = s.replace(/&/, '&amp;');
					s = s.replace(/</, '&lt;');
					s = s.replace(/>/, '&gt;');
					//s = s.replace(/"/, '&quote;');
					return s;
				};
				if (value === undefined){
					// wrap value into root.
					node = this.get(0);
					nodeName = node.nodeName.toLowerCase();
					nodeType = node.nodeType;
					if (nodeType === 1){ // element node
						str = '<' + nodeName;
						if (node.attributes.length){
							for (j = 0; j < node.attributes.length; j += 1){
								attr = node.attributes[j];
								attrName = attr.nodeName.toLowerCase();
								attrValue = attr.nodeValue;
								str += ' ' + attrName + '="' + encodeSpecialChars(attrValue) + '"';
							}
						}
						if (jQuery.inArray(nodeName, singleTags) > -1){
							str += ' />';
						}else{
							str += '>';
							for (i = 0; i < node.childNodes.length; i += 1){
								str += jQuery.fn.xhtml.call($(node.childNodes[i]));
							}
							str += '</' + nodeName + '>';
						}
						return str;
					}else if (nodeType === 3){
						return encodeSpecialChars(node.nodeValue);
					}else if (nodeType === 8){
						return '<!--' + encodeSpecialChars(node.nodeValue) + '-->';
					}
					return '';
				}else{
					jQuery.fn.html(value);
				}
			}
		});
	
		// get iso date and get iso time
		$.extend({
			// deprecated
			getISODate: function(gmtDateStr, lang){
				var dateBox = {
					'de': {'month': ['Januar', 'Februar', 'März', 'April', 'Mai', 'Juni', 'Juli', 'August', 'September', 'Oktober', 'November', 'Dezember'], 'separator': '.'},
					'en': {'month': ['January', 'February', 'March', 'April', 'May', 'June', 'July', 'August', 'September', 'October', 'November', 'December'], 'separator': '/'}
				}
				if (arguments.length == 0){
					var date = new Date();
					var lang = 'en';
				}else if (arguments.length == 1){
					var arg = arguments[0];
					if (typeof arg == 'string' && arg.length == 2){
						var lang = arg;
						var date = new Date();
					}else{
						var lang = 'en';
						var date = new Date(gmtDateStr);
					}
				}else{
					var date = new Date(gmtDateStr);
				}
				var sep = dateBox[lang].separator;
				var y = date.getYear() - 100;
				var fy = date.getFullYear();
				var m = date.getMonth();
				var d = date.getDate();
				var md = d < 10 ? '0' + d : d;
				var mm = m + 1 < 10 ? '0' + (m + 1) : m + 1;
				var my = y < 10 ? '0' + y : y;
				if (lang == 'de'){
					return {
						'short': d + sep + (m + 1) + sep + y,
						'middle': md + sep + mm + sep + my,
						'long': md + sep + dateBox[lang].month[m] + sep + fy
					}
				}
				return {
					'short': (m + 1) + sep + d + sep + y,
					'middle': mm + sep + md + sep + my,
					'long': dateBox[lang].month[m] + sep + md + sep + fy
				}
			},
			// deprecated
			getISOTime: function(gmtDateStr){
				if (gmtDateStr) var date = new Date(gmtDateStr);
				var date = new Date();
				var h = date.getHours();
				if (h < 10) h = '0' + h;
				var m = date.getMinutes();
				if (m < 10) m = '0' + m;
				var s = date.getSeconds();
				if (s < 10) s = '0' + s;
				return h + ':' + m + ':' + s;
			},
			formatDate: function(gmtDateStr, lang){
				var dateBox = {
					'de': {'month': ['Januar', 'Februar', 'März', 'April', 'Mai', 'Juni', 'Juli', 'August', 'September', 'Oktober', 'November', 'Dezember'], 'separator': '.'},
					'en': {'month': ['January', 'February', 'March', 'April', 'May', 'June', 'July', 'August', 'September', 'October', 'November', 'December'], 'separator': '/'}
				}
				if (arguments.length == 0){
					var date = new Date();
					var lang = 'en';
				}else if (arguments.length == 1){
					var arg = arguments[0];
					if (typeof arg == 'string' && arg.length == 2){
						var lang = arg;
						var date = new Date();
					}else{
						var lang = 'en';
						var date = new Date(gmtDateStr);
					}
				}else{
					var date = new Date(gmtDateStr);
				}
				var sep = dateBox[lang].separator;
				var y = date.getYear() - 100;
				var fy = date.getFullYear();
				var m = date.getMonth();
				var d = date.getDate();
				var y = y < 10 ? '0' + y : y;
				var md = d < 10 ? '0' + d : d;
				var mm = m + 1 < 10 ? '0' + (m + 1) : m + 1;
				var my = fy;
				if (lang == 'de'){
					return {
						'_short': d + sep + (m + 1) + sep + y,
						'_middle': md + sep + mm + sep + my,
						'_long': [md + sep,dateBox[lang].month[m],fy].join('&nbsp;')
					}
				}
				return {
					'_short': (m + 1) + sep + d + sep + y,
					'_middle': mm + sep + md + sep + my,
					'_long': [dateBox[lang].month[m] + sep,md,fy].join('&nbsp;')
				}
			},
			formatTime: function(gmtDateStr){
				var date = gmtDateStr ? new Date(gmtDateStr) : new Date();
				var h = date.getHours();
				if (h < 10) h = '0' + h;
				var m = date.getMinutes();
				if (m < 10) m = '0' + m;
				var s = date.getSeconds();
				if (s < 10) s = '0' + s;
				return {'time': h + ':' + m + ':' + s, 'timeWithoutSec': h + ':' + m};
			}
		});
	
		// setter and getter for language resources
		$.extend({
			lang: function(name, lang){
				if (arguments.length > 1){
					if (typeof lang == 'object'){
						if (! $.lang._res) $.lang._res = {};
						$.lang._res[name] = lang;
						return lang;
					}else{
						if ($.lang._res && $.lang._res[name] && $.lang._res[name][lang]){
							return $.lang._res[name][lang];
						}
					}
					return '?-invalid-language-resource-?';
				}else if (arguments.length == 1){
					lang = $('html').attr('lang');
					if (!lang) lang = 'en';
					if ($.lang._res) return $.lang._res[name][lang];
					return '?-invalid-language-resource-?';
				}
				return $('html').attr('lang');
			}
		});
		
		// scroll to plugin easing type elasout
		$.easing.elasout = function(x, t, b, c, d) {
			var s=1.70158;var p=0;var a=c;
			if (t==0) return b;  if ((t/=d)==1) return b+c;  if (!p) p=d*.3;
			if (a < Math.abs(c)) { a=c; var s=p/4; }
			else var s = p/(2*Math.PI) * Math.asin (c/a);
			return a*Math.pow(2,-10*t) * Math.sin( (t*d-s)*(2*Math.PI)/p ) + c + b;
		};
	
		// serialize json data
		$.extend({
			toJson: function(o){
				var type = typeof o;
				if (type == 'undefined')
					return 'undefined';
				else if (type == 'number' || type == 'boolean')
					return o + "";
				else if (o === null)
					return 'null';
				else if (type == 'string'){
					var escapeable = /["\\\x00-\x1f\x7f-\x9f]/g;
					var meta = {
							'\b': '\\b',
							'\t': '\\t',
							'\n': '\\n',
							'\f': '\\f',
							'\r': '\\r',
							'"' : '\\"',
							'\\': '\\\\'
					};
					if (escapeable.test(o)){
						return '"' + o.replace(escapeable, function (a){
							var c = meta[a];
							if (typeof c === 'string') {
									return c;
							}
							c = a.charCodeAt();
							return '\\u00' + Math.floor(c / 16).toString(16) + (c % 16).toString(16);
						}) + '"';
					}
					return '"' + o + '"';
				}else if (type == 'function')
					return;
				else if (type == 'object' && typeof o.toJson == 'function')
					return o.toJson();
				else if (type == 'object' && typeof o.length == 'number'){
					var tempList = [];
					for (var i = 0; i < o.length; i++){
						tempList.push($.toJson(o[i]));
					}
					return '[' + tempList.join(',') + ']';
				}
				
				var tempList = [];
				if (typeof o.toJsonAttrs == 'object' && typeof o.toJsonAttrs.length == 'number'){
					for (var i = 0; i < o.toJsonAttrs.length; i++){
						var k = o.toJsonAttrs[i];
						if (typeof o[k] != 'function'){
							tempList.push($.toJson(k) + ':' + $.toJson(o[k]));
						}
					}
				}else{
					for (var k in o){
						if (typeof o[k] != 'function'){
							tempList.push($.toJson(k) + ':' + $.toJson(o[k]));
						}
					}
				}
				return '{' + tempList.join(',') + '}';
			}
		});
	
		// object clone
		$.extend({
			clone: function(o){
				function F(){};
				F.prototype = o;
				var result = new F();
				result.__prototype__ = o;
				return result;
			}
		});
	})(jQuery);
/* << */


/* >> AJAX URL Manager jQuery 1.2.6+ Version: rel-1-0-1 */
	AjaxURLManager = {
		mode: 'static',
		URL: {},
		sessionData: null,
		baseURL: '/backend/',
		baseURLStatic: '../static/',
		setBaseURL: function(url){
			this.baseURL = url;
		},
		setBaseURLStatic: function(url){
			this.baseURLStatic = url;
		},
		setMode: function(mode){
			this.mode = APP_MODE = mode;
		},
		registerKey: function(key, attrs, staticFile, allwaysStatic){
			this.URL[key] = {'attrs': attrs, 'staticFile': staticFile, 'allwaysStatic': allwaysStatic};
		},
		getUrlWithKey: function(key, attrs){
			if (this.URL[key]){
				var data = this.URL[key];
				if (data.attrs || attrs){
					if (data.attrs) attrs = $.extend(data.attrs, attrs);
					var realAttrs = {};
					for (var k in attrs){
						if (attrs[k] != null) realAttrs[k] = attrs[k];
					}
					if (this.sessionData) realAttrs = $.extend(realAttrs, this.sessionData);
					attrs = '?' + $.param(realAttrs);
				}else{
					if (this.sessionData){
						var attrs = $.extend(data.attrs, this.sessionData);
						attrs = '?' + $.param(this.sessionData);
					}
				}
				if (this.mode == 'static' && data.staticFile || data.allwaysStatic && data.staticFile){
					return [this.baseURLStatic,data.staticFile,attrs].join('');
				}
				return [this.baseURL,key,attrs].join('');
			}
			return null;
		}
	}
/* << */


/* >> utilities requires jQuery 1.2.6 Version: rel-1-1-0 */
	doNothing = function(){}
	Utils = {
		pixelPath: '/xist4c/px/spc.gif',
		pixel: function(){
			return $('<img src="' + this.pixelPath + '" height="1" width="1" border="0" alt=""/>');
		},
		pixelAsString: function(){
			return '<img src="' + this.pixelPath + '" height="1" width="1" border="0" alt=""/>';
		},
		getRecalculatedImage: function(args){
			var img = args.image;
			if ($.browser.msie){
				var w = img.width;
				var h = img.height;
			}else{
				var w = img.attr('width');
				var h = img.attr('height');
			}
			var mw = args.maxWidth;
			var mh = args.maxHeight;
			var nw, nh;
			var f = 1;
			if (args.proportional){
				f = mw / w;
				var nw = mw;
				var nh = h * f;
				if (nh > mh){
					f = mh / nh;
					var nh = mh;
					var nw = nw * f;
				}
				if ($.browser.msie){
					img.width = nw;
					img.height = nh;
				}else{
					img.attr('width', nw);
					img.attr('height', nh);
				}
				return img;
			}
			if ($.browser.msie){
				img.width = mw;
				img.height = mh;
			}else{
				img.attr('width', mw);
				img.attr('height', mh);
			}
			return img;
		},
		getUrlParamsAsJson: function(url, dontDecode){
			if (!url) var url = window.location.href;
			if (url.search(/\?/) > -1){
				var urlParams = url.substring(url.search(/\?/) + 1 , url.length);
				urlParams = urlParams.split('&');
				jParams = {};
				$(urlParams).each(function(i){
					var parVal = this.split('=');
					if (dontDecode){
						jParams[parVal[0]] = parVal[1];
					}else{
						jParams[decodeURI(parVal[0])] = decodeURI(parVal[1]);
					}
				});
				return jParams;
			}
			return null;
		},
		getUrlParamsFromJson: function(params){
			var paramStr = '?', i;
			if (params && typeof params === 'object'){
				for (var k in params){
					if (params[k] && typeof params[k].length === 'number' && typeof params[k] !== 'string'){
						for (i = 0; i < params[k].length; i+=1){
							paramStr += [encodeURIComponent(k),'=',encodeURIComponent(params[k][i]),'&'].join('');
						}
					}else{
						paramStr += [encodeURIComponent(k),'=',encodeURIComponent(params[k]),'&'].join('');
					}
				}
				return paramStr.substring(0, paramStr.length - 1);
			}
			return null;
		},
		stripTags: function(str){
			if (typeof str == 'string') return str.replace(/<\/?[^>]+>/gi, '');
			return null;
		},
		parseDeFloat: function(f){
			var f = f.replace(/\./g, '');
			f = f.replace(/\,/, '.');
			return f;
		},
		getUrlSession: function(keyString){
			var sidKeyLength = 12, sidKeyRex = /;jsessionid=/, sid = null,
					loc = window.location.href, params = Utils.getUrlParamsAsJson(), paramStartRex = /\?/, endPos,
					ks = keyString || '';
			if (sidKeyRex.test(loc)){
				if (params){
					endPos = loc.search(paramStartRex);
				}else{
					endPos = loc.length;
				}
				return ks + loc.substring(loc.search(sidKeyRex) + sidKeyLength, endPos);
			}
			return '';
		},
		isObject: function(obj){
			return (
				obj && 
				(typeof(obj) === 'object') && 
				!(typeof(obj.length) === 'number')
			);
		},
		isArray: function(obj){
			return (
				!(typeof(obj) === 'string') && 
				(typeof(obj) === 'object') && 
				(typeof(obj.length) === 'number')
			);
		},
		isFunction: function(obj){
			return typeof(obj) === 'function';
		}
	}
/* << */


/* >> livinglogic extended object with own prototype extension Version: rel-1-0-0 */
	LLObject = {
		__prototype__: null,
		create: function(){
			return $.clone(this);
		},
		instanceOf: function(type){
			if (this == type)
				return true;
			else if (this.__prototype__ == null)
				return false;
			else
				return this.__prototype__.instanceOf(type);
		}
	}
/* << */


/* >> XIST4C Globals */
	XIST4C_GLOBALS = {};
/* << */


/* >> LivingLogic DropDown Node (requires jQuery 1.2.6) Version: rel-1-0-0 */
	Node = function(Args){
		for (var name in Args){
			this[name] = Args[name];
		}
		this.children = [];
	}
	
	Node.prototype.childrenLayer = function(level){
		var layerId = ['childrenLevelContainer_',this.level].join('');
		if (level) layerId = ['childrenLevelContainer_',level].join('');
		return layer = $('<div></div>').css(
			{
				'position': 'absolute',
				'right': ['-',LL_DropDownNavi.layerWidth,'px'].join(''),
				'top': 0,
				'z-index': this.level * 10,
				'width': [LL_DropDownNavi.layerWidth,'px'].join('')
			}
		).attr({'id': layerId}).hide();
	}

	Node.prototype.nodeChildrenShell = function(){
		var cs = $('<div></div>').attr({'class': ['navCHS_',this.level+1].join('')});
		var self = this;
		if (this.styName){
			var sty = ['co_',this.styName].join('');
			var d = $('<div></div>').attr({'class': sty});
			if (this.children.length > 0){
				$(this.children).each(function(i){
					var Args = {};
					if (i == 0) Args.first = true;
					if (i == self.children.length -1) Args.last = true;
					d.append(this.nodeShell(Args));
				});
			}
			cs.append(d);
			return cs;
		}
		if (this.children.length > 0){
			$(this.children).each(function(i){
				var Args = {};
				if (i == 0) Args.first = true;
				if (i == self.children.length -1) Args.last = true;
				cs.append(this.nodeShell(Args));
			});
		}
		return cs;
	}
	
	Node.prototype.nodeFirstLevelShell = function(){
		var ns = $('<div></div>').attr({'class': ['navNS_',this.level].join(''), 'id': this.id})
		var node = this.node();
		ns.append(this.childrenLayer(1));
		if (this.styName){
			var sty = ['co_',this.styName].join('');
			var d = $('<div></div>').attr({'class': sty});
			d.append(node);
			if (this.children.length > 0){
				var cs = this.nodeChildrenShell();
				d.append(cs);
			}
			ns.append(d);
			return ns;
		}
		ns.append(node);
		if (this.children.length > 0){
			var cs = this.nodeChildrenShell();
			ns.append(cs);
		}
		return ns;
	}

	Node.prototype.nodeShell = function(Args){
		var ns = $('<div></div>').attr({'class': ['navNS_',this.level].join(''), 'id': this.id})
		var csOffset = $('<div></div>').css({'position': 'relative'}).attr({'id': [this.id,'_layerOffset'].join('')});
		ns.append(csOffset);
		var node = this.node();
		if (Args){
			var origClassName = node.attr('class');
			var newClassName = '';
			if (Args.first) newClassName += [' ',origClassName,'_first'].join('');
			if (Args.last) newClassName += [' ',origClassName,'_last'].join('');
			node.attr('class', origClassName + ' ' + newClassName);
		}
		if (this.styName){
			var sty = ['co_',this.styName].join('');
			var d = $('<div></div>').attr({'class': sty});
			d.append(node);
			ns.append(d);
			return ns;
		}
		ns.append(node);
		return ns;
	}

	Node.prototype.node = function(){
		var outer = $('<div></div>')
			.attr({'class': ['navEl_',this.level,'_',this.type].join('')});
		var n = $('<div></div>')
			.attr({'class': 'outer'});
		var text = $('<span></span>').attr({'class': 'inner'}).text(this.title);
		if (this.href){
			if (this.type == 'here'){
				text = $('<div></div>').attr({'class': 'noLink'}).append(text).css('cursor', 'hand');
			}else if(this.type == 'inPath'){
				text = $('<a></a>').attr({'href': this.href}).append(text).css('cursor', 'hand');
			}else if(this.type == 'normal'){
				text = $('<a></a>').attr({'href': this.href}).append(text).css('cursor', 'hand');
			}
		}
		n.append(text);
		outer.append(n);
		outer.css('cursor', 'hand');
		var self = this;
		if (this.children.length > 0 && this.level > 0){
			outer.bind('mouseover', function(e){
				var levelCont = ['#childrenLevelContainer_',self.level].join('');
				if ($(levelCont).size() == 0) $('body').append(self.childrenLayer());
				var layerOffset = ['#',self.id,'_layerOffset'].join('');
				$(levelCont).empty().append(self.nodeChildrenShell()).hide();
				$(layerOffset).append($(levelCont));
				$(levelCont).fadeIn(200);
			});
		}else{
			var level = self.level == 0 ? self.level + 1 : self.level;
			outer.bind('mouseover', function(e){
				 $('#childrenLevelContainer_' + level).fadeOut(200);
			});
		}
		return outer;
	}
	
/* << */


/* >> LivingLogic DropDown Navigation (requires jQuery 1.2.6) Version: rel-1-0-0 */
	LL_DropDownNavi = {
		path: [],
		layerWidth: 160,
		lay: {
			pixel: function(){
				return $('<img />').attr({'src': '../../px/spc.gif', 'width': 1, 'height': 1, 'alt': ''});
			},
			nodesOuterShell: function(content){
				var nos = $(
					'<div class="navOuterShell">' +
						'<div class="noDes1">' +
							'<div class="noDes2">' +
								'<div class="topImg">' +
									'<div class="bottomImg">' +
									'</div>' +
								'</div>' +
							'</div>' +
						'</div>' +
					'</div>'
				);
				nos.find('div.topImg').append(LL_DropDownNavi.lay.pixel())
				nos.find('div.bottomImg').append(content);
				nos.find('div.bottomImg').append(LL_DropDownNavi.lay.pixel());
				nos.bind('mouseleave', function(){
					$('div[id^=childrenLevelContainer_]').fadeOut(500);
				});
				return nos;
			}
		},
		sitemap: null,
		init: function(Args){
			this.sitemap = this.buildTreeFromArray(XIST4C_GLOBALS.sitemap);
			lay = LL_DropDownNavi.lay;
			var homeNode = this.sitemap[0].nodeFirstLevelShell();
			if (Args && Args.target){
				var target = $(['#',Args.target].join(''));
				target.append(lay.nodesOuterShell(homeNode));
			}else{
				$('div.navOuterShell').find('div.navNS_0').remove().end().find('div.noDes2').append(homeNode).bind('mouseleave', function(){
					$('div[id^=childrenLevelContainer_]').fadeOut(500);
				});
			}
		},
		renderFirstLevel: function(){
			var lay = LL_DropDownNavi.lay;
			var nodes = [];
			$(this.sitemap[1]).each(function(i){
				var node = this;
				if (typeof node == 'object' && typeof node.length != 'number'){
					var node = lay.nodeShell(node, lay.node(node))
					nodes.push(node);
				}
			});
			return lay.nodeChildrenShell(this.sitemap[0], nodes);
		},
		getChildren: function(id, level){
		},
		renderChildrenLayer: function(id, level){
			for (var i = 0; i < this.sitemap[1].length; i++){
				var node = this.sitemap[1][i];
				if (node.id == id){
					//if (i)
				}
			}
		},
		buildTreeFromArray: function(arr){
			var newArr = [];
			for (var i = 0; i < arr.length; i++){
				var data = arr[i];
				if (typeof data == 'object' && typeof data.length != 'number'){
					newArr.push(new Node(data));
				}else{
					newArr[newArr.length-1].children = this.buildTreeFromArray(data);
				}
			}
			return newArr;
		}
	}
/* << */


	/* deprecated */
	function hideInputBg(field)
	{
		ipField = document.getElementById(field);
		ipField.style.background = "#fff";
	}
	
	
	function IE_Refresh(){
		if (document.all) location.reload();
	}
	window.onresize = IE_Refresh;
	
	
/* >> Standard Popup functions Version: rel-1-0-0 */
	function StandardPopup(Attrs){
		// @params IE and Gecko-Browser compatible window parameter attributes.
		this.params = ['left', 'top', 'location', 'menubar', 'resizable', 'scrollbars', 'status', 'toolbar', 'height', 'width'];
		this.href = Attrs.href ? Attrs.href : 'http://www.google.de'; // url to the popup content
		this.name = Attrs.name ? Attrs.name : 'standardPopup'; // standard window name
		this.height = Attrs.height ? Attrs.height : '550'; // standard height opened window
		this.width = Attrs.width ? Attrs.width : '650'; // standard width opened window
		this.left = Attrs.left ? Attrs.left : null; // window left position from the upper left corner of the client screen
		this.top = Attrs.top ? Attrs.top : null; // window top position from the top of the client screen
		this.locationbar = Attrs.location ? Attrs.location : 'no'; // ['yes', 'no'] display the locationbar
		this.menubar = Attrs.menubar ? Attrs.menubar : 'no'; // ['yes', 'no'] display the menubar
		this.resizable = Attrs.resizable ? Attrs.resizable : 'yes'; // ['yes', 'no'] allows the user to change the window size
		this.scrollbars = Attrs.scrollbars ? Attrs.scrollbars : 'yes'; // ['yes', 'no'] show scrollbars if necessary
		this.status = Attrs.status ? Attrs.status : 'no'; // ['yes', 'no'] show statusbar
		this.toolbar = Attrs.toolbar ? Attrs.toolbar : 'no'; // ['yes', 'no'] show toolbar
		this.blank = Attrs.blank ? Attrs.blank : 'false'; // ['true', 'false'] show window as popup or blank window
		this.wRef = null // window reference to make changes on the opened windowe
	}
	
	StandardPopup.prototype._formatParams = function()
	{
		var str = '\'';
		var objParam;
		for (var i = 0; i < this.params.length; ++i){
			objParam = this.params[i] == 'location' ? 'locationbar' : this.params[i];
			p = eval("this." + objParam);
			if (p){
				str += this.params[i] + '=' + p + ',';
			}
		}
		str = str.substring(0, str.length -1);
		str += '\'';
		return str;
	}
	
	StandardPopup.prototype.open = function(){
		if (this.blank){
			this.wRef = window.open(this.href);
		}else{
			var paraStr = this._formatParams();
			this.wRef = window.open(this.href, this.name, paraStr);
		}
		if (this.wRef)
			this.wRef.focus();
		return false;
	}
/* << */


/* >> rss publisher, (requires jQuery 1.2.6) Version: rel-2-0-0 */
	RSSPublisher = {
		publishers: false,
		register: function(args){
			this.append(args);
		},
		append: function(args){
			var RSSObj = new RSS();
			RSSObj.target = args.target;
			RSSObj.source = args.source;
			RSSObj.tags = args.tags;
			RSSObj.descLength = args.descLength;
			RSSObj.descLengthEnding = args.descLengthEnding
			RSSObj.pubDateFormat = args.pubDateFormat;
			RSSObj.refresh = args.refresh;
			RSSObj.itemsCount = args.itemsCount ? args.itemsCount : 5;
			RSSObj.staticTest = args.staticTest;
			if (args.acceptMimeTypes && typeof args.acceptMimeTypes == 'object'){
				RSSObj.acceptMimeTypesCgiStr = this.createMimeTypeCgiStr(args.acceptMimeTypes);
			}
			if (typeof this.publishers != 'boolean'){
				this.publishers.push(RSSObj);
			}else{
				this.publishers = [RSSObj];
			}
			RSSObj.getSource();
		},
		createMimeTypeCgiStr: function(mtList){
			var str = '&mimetypes=';
			for (var i = 0; i < mtList.length; ++i){
				str += encodeURIComponent(this.strTrim(mtList[i])) + ',';
			}
			return str.substring(0, str.length -1);
		},
		strTrim: function(str){
			var ccSpace = 32;
			var ps = 0;
			var pe = 0;
			var psLock = false;
			var peLock = false;
			for (var i = 0; i < str.length; ++i){
				if (str.charCodeAt(i) == ccSpace){
					if (! psLock) ps++;
					if (str.charCodeAt(str.length - 1 - i) == ccSpace){
						if (! peLock) pe++;
					}else{
						peLock = true;
					}
				}else{
					psLock = true;
					if (str.charCodeAt(str.length - 1 - i) == ccSpace){
						if (! peLock) pe++;
					}else{
						peLock = true;
					}
				}
			}
			var string = str.substring(ps, str.length);
			return string.substring(0, str.length - pe - ps);
		}
	}


	function RSS(){
		this.root = $('<div></div>');
		this.target = null;
		this.source = null;
		this.tags = ['title', 'description'];
		this.descLength = null;
		this.descLengthEnding = 32;
		this.pubDateFormat = 2;
		this.refresh = null;
		this.itemsCount = null;
		this.staticTest = false;
		this.acceptMimeTypesCgiStr = null;
		this.charCount = 0;
		this.stop = false;
	}
	
	RSS.prototype.getSource = function(){
		this.charCount = 0;
		this.stop = false;
		this.root.empty();
		if (this.staticTest){
			var url = this.source;
		}else{
			var url = '/urlfetcher/?url=' + encodeURIComponent(this.source);
		}
		if (this.acceptMimeTypesCgiStr && ! this.staticTest) url += this.acceptMimeTypesCgiStr;
		var self = this;
		$.ajax({
			type: 'GET',
			url: url,
			success: function(data, msg){self.handleSource(data, msg)},
			error: function(req, status, error){self.handleSourceError(req, status, error)}
		});
		if (this.refresh) setTimeout(function(){self.getSource();}, this.refresh * 1000);
	}
	
	RSS.prototype.handleSource = function(data, msg){
		var xmlElements = data;
		var items = $('item', xmlElements);
		var count = items.size();
		if (this.itemsCount <= items.size()) count = this.itemsCount;
		var tags = this.tags;
		for (var i = 0; i < count; ++i){
			var href = self.getLink(items.get(i));
			self.appendElement(self.getItem(items.get(i), tags, href, i), self.root);
		}
		this.publish();
	}
	
	RSS.prototype.handleSourceError = function(def){
		console.log(def.message);
		$('#' + this.target).html('<div>Service ist voruebergehend nicht verfuegbar.</div>');
	}
	
	RSS.prototype.appendElement = function(elm, root){
		if (elm){
			$(root).append(elm);
			return true;
		}
		return false;
	}

	RSS.prototype.cloneXML2DOM = function(src, tar, igRoot, len, correctHyphen){
		for (var i = 0; i < src.childNodes.length; i++){
			var node = src.childNodes[i];
			switch (node.nodeType){
				case 1:
					if (! igRoot){
						var newNode = tar.appendChild(document.createElement(node.nodeName));
						for (var j = 0; j < node.attributes.length; j++){
							newNode.setAttribute(node.attributes[j].nodeName, node.attributes[j].nodeValue);
						}
						this.cloneXML2DOM(node, newNode, false, correctHyphen);
						break;
					}else{
						this.cloneXML2DOM(node, tar, false, correctHyphen);
						break;
					}
				case 3:
					if (len){
						var text = node.nodeValue;
						if (this.charCount + text.length < len){
							this.charCount += text.length;
						}else{
							var pos = 0;
							var t = '';
							while(1){
								t += text.substr(pos, 1);
								if (t.length + this.charCount >= len){
									var cCode = t.charCodeAt(t.length -1);
									if (cCode == this.descLengthEnding || pos == t.length){
										this.charCount += t.length;
										if (cCode == this.descLengthEnding){
											t += cCode == 32 ? '....' : ' ....';
											this.stop = true;
										}else{
											this.stop = false;
										}
										text = t;
										break;
									}
								}else if(text.length + this.charCount < len){
									var cCode = text.charCodeAt(text.length -1);
									this.charCount += text.length;
									text += cCode == 32 ? '....' : ' ....';
									this.stop = true;
									break;
								}
								pos++;
							}
						}
					}else{
						text = node.nodeValue;
					}
					if (correctHyphen) text = this.correctHyphenatedText(text);
					subNode = document.createTextNode(text);
				tar.appendChild(subNode);
			}
			if (this.stop){
				this.charCount = 0;
				break;
			}
		}
	}
	
	RSS.prototype.correctHyphenatedText = function(text){
		return text.replace(/-/g, '- ');
	}
	
	RSS.prototype.cloneContent = function(src, len, correctHyphen){
		var root = $('<div></div>').get(0);
		if (len){
			this.charCount = 0;
			this.stop = false;
		}
		this.cloneXML2DOM(src, root, false, len, correctHyphen);
		return root.childNodes;
	}

	RSS.prototype.getFirstNodeMatch = function(nName, parent, type){
		var n = parent.childNodes;
		var nName = nName.toLowerCase();
		type = type ? type : 1;
		for (var i = 0; i < n.length; ++i){
			if (n[i].nodeType == type && n[i].nodeName.toLowerCase() == nName){
				return n[i];
			}
		}
		return false;
	}
	
	RSS.prototype.getLink = function(item){
		return $('link', item).text();
	}
	
	RSS.prototype.getItem = function(item, tags, href, count){
		var sty = count % 2 == 0 ? 'item' : 'item odd';
		var itemShell = $('<div></div>').attr({'class': sty}).get(0);
		for (var j = 0; j < tags.length; ++j){
			switch (tags[j]){
				case 'title':
					this.appendElement(this.getTitle(item, href), itemShell);
					break;
				case 'description':
					this.appendElement(this.getDescription(item), itemShell);
					break;
				case 'pubDate':
					this.appendElement(this.getPubDate(item), itemShell);
					break;
			}
		}
		return itemShell;
	}

	RSS.prototype.getTitle = function(item, href){
		var title = $('title', item).get(0);
		if (title && title.childNodes.length > 0){
			return Layout.getTitle(this.cloneContent(title, false, true), href);
		}
		return false;
	}
	
	RSS.prototype.getDescription = function(item){
		var description = $('description', item).get(0);
		if (description && description.childNodes.length > 0) {
			return Layout.getDescription(this.cloneContent(description, this.descLength, true));
		}
		return false;
	}
	
	RSS.prototype.getPubDate = function(item){
		var pubDate = $('pubDate', item).get(0);
		if (pubDate && pubDate.childNodes.length > 0) {
			var dateGMT = pubDate.childNodes[0].nodeValue;
			pubDate.childNodes[0].nodeValue = this.formatDate(dateGMT);
			return Layout.getPubDate(this.cloneContent(pubDate, false, false));
		}
		return false;
	}
	
	RSS.prototype.formatDate = function(dateStr){
		var lang = $('html').attr('lang');
		var date = $.getISODate(new Date(dateStr), lang);
		var time = $.getISOTime(new Date(dateStr));
		if (this.pubDateFormat == 1){
			return date.short;
		}else if (this.pubDateFormat == 2){
			return date.middle;
		}else if (this.pubDateFormat == 3){
			return date.long;
		}else if (this.pubDateFormat == 4){
			return date.long + ' ' + time;
		}
	}
	
	RSS.prototype.publish = function(){
		$('#' + this.target).empty().html($(this.root).html());
	}
	
	Layout = {
		getTitle: function(t, href){
			if (href) t = $('<a></a>').attr({'href': href, 'target': '_blank'}).append(t);
			return $('<div></div>').attr({'class': 'rssElementTitle'}).append(
				$('<h3></h3>').append($('<span></span>').append(t))
			).get(0);
		},
		getDescription: function(desc){
			return $('<div></div>').attr({'class': 'rssElementDesc'}).append(
				$('<div></div>').attr({'class': 'inner'}).append(desc)
			).get(0);
		},
		getPubDate: function(d){
			return $('<div></div>').attr({'class': 'rssElementPubDate'}).append(
				$('<span></span>').append(d)
			).get(0);
		}
	}
/* << */


/* >> Generic Multimedia CMS tool, (requires jQuery 1.2.6) Version: rel-2-0-0 */
	function GenericMultimedia(args){
		this.lang = this.getLang();
		this.altText = args.altText;
		this.altImg = args.altImg;
		this.data = args.data;
		this.htmlSrcDom = this.getHtmlSrcDom(args.htmlSrc);
		this.javaApplet = this.isJavaApplet();
		this.modifyAndWriteDocumentElements();
	}
	
	GenericMultimedia.prototype.getLang = function(){
		var htmlEl = $('html');
		if (htmlEl.attr('lang')){
			return this.formatLang(htmlEl.attr('lang'));
		}else if(htmlEl.attr('xml:lang')){
			return this.formatLang(htmlEl.attr('xml:lang'));
		}
		return 'en';
	}
	
	GenericMultimedia.prototype.formatLang = function (lang){
		if (lang.search(/-/) > -1) return lang.substring(0, lang.search(/-/));
		return lang;
	}
	
	GenericMultimedia.prototype.getHtmlSrcDom = function(htmlSrc){
		if (typeof htmlSrc == 'string' && htmlSrc.length > 0){
			return $('<div><xml>' + htmlSrc + '</xml></div>').get(0);
		}
		return null;
	}
	
	GenericMultimedia.prototype.isJavaApplet = function(){
		var isJavaApp = false;
		$('xml > *', this.htmlSrcDom).each(
			function(n){
				if (this.nodeType == 1 && this.nodeName.toLowerCase() == 'object'){
					if($(this).attr('classid')){
						isJavaApp = $(this).attr('classid').search('java:') > -1;
					}
				}
			}
		);
		return isJavaApp;
	}
	
	GenericMultimedia.prototype.modifyAndWriteDocumentElements = function(){
		var output = '';
		var onlyEmbed = false;
		var model;
		var self = this;
		$('xml > *', this.htmlSrcDom).each(
			function(n){
				if (self.javaApplet || (! self.useEmbed() && ! self.javaApplet)){
					if (this.nodeType == 1 && this.nodeName.toLowerCase() == 'object'){
						model = false;
						output += self.startElement('object', self.getNodeAttributes(this), model);
						$('*', this).each(
							function(n){
								if (this.nodeType == 1 && this.nodeName.toLowerCase() == 'param'){
									model = true;
									output += self.startElement('param', self.getNodeAttributes(this), model);
								}
								if (this.nodeType == 1 && this.nodeName.toLowerCase() == 'embed'){
									model = true;
									output += self.startElement('embed', self.getNodeAttributes(this), model);
								}
							}
						);
					}
				}else{
					onlyEmbed = true;
					$('param, embed', this).each(
						function(n){
							if (this.nodeType == 1 && this.nodeName.toLowerCase() == 'embed'){
								model = true;
								output += self.startElement('embed', self.getNodeAttributes(this), model);
							}
						}
					);
				}
				if (self.altText || self.altImg){
					var text = '';
					var img = '';
					if (self.altText) var text = '<p>' + self.altText + '</p>';
					if (self.altImg) var img = '<img src="' + self.altImg + '" alt="" title="" />';
					if (!$.browser.safari){ //Workarround for safari 3.2.1 which interpreted the standard wrong.
						if (self.useEmbed() && ! self.javaApplet){
							output += '<noembed>' + text + img + '</noembed>';
						}else{
							output += text + img;
						}
					}
				}
				if (! onlyEmbed) output += self.endElement('object');
			}
		);
		document.write(output);
		
		
		
		/*var elms = this.htmlSrcDom.childNodes[0].childNodes;
		var onlyEmbed = false;
		var model;
		if (elms.length > 0){
			for (var i = 0; i < elms.length; ++i){
				var node = elms[i];
				var name = elms[i].nodeName.toLowerCase();
				var type = elms[i].nodeType;
				if (this.javaApplet || (! this.useEmbed() && ! this.javaApplet)){
					if (type == 1 && name == 'object'){
						model = false;
						output += this.startElement('object', this.getNodeAttributes(node), model);
						var objChilds = node.childNodes;
						for (var j = 0; j < objChilds.length; ++j){
							node = objChilds[j];
							name = objChilds[j].nodeName.toLowerCase();
							type = objChilds[j].nodeType;
							if (type == 1 && name == 'param'){
								model = true;
								output += this.startElement('param', this.getNodeAttributes(node), model);
							}
							if (type == 1 && name == 'embed'){
								model = true;
								output += this.startElement('embed', this.getNodeAttributes(node), model);
							}
						}
					}
				}else{
					onlyEmbed = true;
					var objChilds = node.childNodes;
					for (var j = 0; j < objChilds.length; ++j){
						node = objChilds[j];
						name = objChilds[j].nodeName.toLowerCase();
						type = objChilds[j].nodeType;
						if (type == 1 && name == 'embed'){
							model = true;
							output += this.startElement('embed', this.getNodeAttributes(node), model);
						}
					}
				}
			}
			if (this.altText || this.altImg){
				if (this.altText) var text = '<p>' + this.altText + '</p>';
				if (this.altImg) var img = '<img src="' + this.altImg + '" alt="" title="" />';
				if (this.useEmbed() && ! this.javaApplet){
					output += '<noembed>' + text + img + '</noembed>';
				}else{
					output += text + img;
				}
			}
			if (! onlyEmbed) output += this.endElement('object');
		}
		document.write(output);*/
	}
	
	GenericMultimedia.prototype.useEmbed = function(){
		var agent = navigator.userAgent;
		if (agent.search(/MSIE | Safari/) > -1) return false;
		return true;
	}
	
	GenericMultimedia.prototype.getNodeAttributes = function(node){
		var name = node.nodeName.toLowerCase();
		var codebase = false;
		if (node.attributes.length > 0){
			var attrs = {};
			var attrValue = '';
			for (var i = 0; i < node.attributes.length; ++i){
				var attrName = node.attributes[i].nodeName.toLowerCase();
				var attrValue = node.attributes[i].nodeValue;
				if (name == 'object' && (attrName == 'classid' || attrName == 'movie' || attrName == 'data')){
					if (attrName == 'classid'){
						attrs[attrName] = this.makeClassidAttribute(attrValue);
					}else if (this.javaApplet && attrName == 'codebase'){
						codebase = true;
						attrs[attrName] = this. makeJavaAppletCodebaseAttribute();
					}else{
						if (attrName == 'codebase') codebase = true;
						attrs[attrName] = this.data + this.copyCgiArgs(attrValue);
					}
				}else if (name == 'embed' && attrName == 'src'){
					attrs[attrName] = this.data + this.copyCgiArgs(attrValue);
				}else{
					attrs[attrName] = attrValue;
				}
			}
			if (this.javaApplet && ! codebase){
						codebase = true;
						attrs['codebase'] = this. makeJavaAppletCodebaseAttribute();
			}
			if (name == 'param'){
				attrNameValue = attrs.name.toLowerCase();
				attrValueValue = attrs.value;
				if (attrNameValue == 'filename' || attrNameValue == 'movie' || attrNameValue == 'src'){
					attrs.value = this.data + this.copyCgiArgs(attrValueValue);
				}
			}
			return attrs;
		}
		return null;
	}
	
	GenericMultimedia.prototype.copyCgiArgs = function(value){
		if (value.lastIndexOf('?') > -1){
			return value.substring(value.lastIndexOf('?'), value.length);
		}
		return '';
	}
	
	GenericMultimedia.prototype.startElement = function(name, attrs, single){
		var element = '<' + name;
		for (var attrName in attrs){
			element += ' ' + attrName + '="' + attrs[attrName] + '"';
		}
		if (single) return element += '/>';
		return element += '>';
	}

	GenericMultimedia.prototype.endElement = function(name){
		return '</' + name + '>';
	}

	GenericMultimedia.prototype.makeClassidAttribute = function(value){
		var data = this.data;
		if (value.search('java:') > -1){
			return 'java:' + data.substring(data.lastIndexOf('/') +1, data.length) + this.copyCgiArgs(value);
		}
		return value;
	}
	
	GenericMultimedia.prototype.makeJavaAppletCodebaseAttribute = function(){
		var data = this.data;
		return data.substring(0, data.lastIndexOf('/') +1);
	}
/* << */


/* >> bookmarking tool (requires jQuery 1.2.6 and ll StandardPopup) Version: rel-2-0-0 */
	function BookmarkStoreAt(args){
		this.targetName = null;
		this.container = null;
		this.titleHTML = null;
		this.textHTML = null;
		this.descSliceStandard = ' ...';
		this.imgPath = '../web/img/standard/bookmarkTool';
		this.bmItems = ['delicious', 'mrwong', 'blinklist', 'yahoo', 'yigg', 'furl', 'oneview', 'folkd', 'linkarena', 'google', 'webnews'];
		this.bmURL = null;
		this.bmTitle = null;
		this.bmTargets = {};
		this.init(args);
	}
	
	BookmarkStoreAt.prototype.init = function(args){
		this.targetName = args.targetName;
		if ($('#' + args.targetName).size() > 0) this.container = $('#' + args.targetName).get(0);
		if (args.bmItems) this.bmItems = args.bmItems;
		if (args.imgPath) this.imgPath = args.imgPath;
		this.titleHTML = args.titleHTML;
		this.textHTML = args.textHTML;
		this.bmURL = encodeURIComponent(location.href);
		this.bmTitle = encodeURIComponent(document.title);
		this.bmTargets['delicious'] = {'title': 'del.icio.us', 'desc': 'del.icio.us', 'url': 'http://del.icio.us/post?url=' + this.bmURL + '&title=' + this.bmTitle};
		this.bmTargets['mrwong'] = {'title': 'Mister Wong', 'desc': 'Mister Wong', 'url': 'http://www.mister-wong.de/index.php?action=addurl&bm_url=' + this.bmURL + '&bm_description=' + this.bmTitle};
		this.bmTargets['blinklist'] = {'title': 'BlinkList', 'desc': 'BlinkList', 'url': 'http://www.blinklist.com/index.php?Action=Blink/addblink.php&Description=&Url=' + this.bmURL + '&Title=' + this.bmTitle};
		this.bmTargets['yahoo'] = {'title': 'Yahoo MyWeb', 'desc': 'Yahoo MyWeb', 'url': 'http://myweb2.search.yahoo.com/myresults/bookmarklet?u=' + this.bmURL + '&t=' + this.bmTitle};
		this.bmTargets['yigg'] = {'title': 'YiGG', 'desc': 'YiGG', 'url': 'http://yigg.de/neu?exturl=' + this.bmURL + '&exttitle=' + this.bmTitle};
		this.bmTargets['furl'] = {'title': 'Furl', 'desc': 'Furl', 'url': 'http://www.furl.net/storeIt.jsp?u=' + this.bmURL + '&t=' + this.bmTitle};
		this.bmTargets['oneview'] = {'title': 'OneView', 'desc': 'OneView', 'url': 'http://beta.oneview.de:80/quickadd/neu/addBookmark.jsf?URL=' + this.bmURL + '&title=' + this.bmTitle};
		this.bmTargets['folkd'] = {'title': 'Folkd', 'desc': 'Folkd', 'url': 'http://www.folkd.com/submit/page/' + this.bmURL};
		this.bmTargets['linkarena'] = {'title': 'Linkarena', 'desc': 'Linkarena', 'url': 'http://linkarena.com/bookmarks/addlink/?url=' + this.bmURL + '&title=' + this.bmTitle + '&desc=&tags='};
		this.bmTargets['google'] = {'title': 'Google', 'desc': 'Google', 'url': 'http://www.google.com/bookmarks/mark?op=add&hl=de&bkmk=' + this.bmURL + '&title=' + this.bmTitle};
		this.bmTargets['webnews'] = {'title': 'Webnews', 'desc': 'Webnews', 'url': 'http://www.webnews.de/einstellen?url=' + this.bmURL + '&title=' + this.bmTitle};
		this._createLayout();
	}

	BookmarkStoreAt.prototype.store = function(target){
		this.open(this.bmTargets[target].url);
	}
	
	BookmarkStoreAt.prototype.open = function(url){
		if (typeof StandardPopup == 'function'){
			var p = new StandardPopup({'href': url, 'blank': true})
			p.open();
		}else{
			window.open(url);
		}
	}
	
	BookmarkStoreAt.prototype.changeDescSlice = function(key){
		var el = '#bmDescSlice_' + this.targetName;
		var slice = this.descSliceStandard;
		if (key) slice = '<span>' + this.bmTargets[key].desc + '</span>';
		$(el).html(slice);
	}
	
	BookmarkStoreAt.prototype._getTitle = function(){
		return $('<div class="bookmarkTitleOuter"><h3>' + this.titleHTML + '</h3></div>').get(0);
	}

	BookmarkStoreAt.prototype._getText = function(){
		return $(
			'<div class="bookmarkTextOuter"><p>' +
			this.textHTML + '<span id="bmDescSlice_' +
			this.targetName + '" class="bmDescSlice">' +
			this.descSliceStandard + '</span></p></div>'
		).get(0);
	}

	BookmarkStoreAt.prototype._getImageItems = function(){
		var bmi = this.bmItems;
		var imgOuter = $('<div class="imgOuter"></div>');
		var img;
		var self = this;
		for (var i = 0; i < bmi.length; ++i){
			function x(bmImgId){
				img = $('<img/>').attr({
						'src': self.imgPath + '/' + bmImgId + '.gif',
						'alt': self.bmTargets[bmImgId].title,
						'title': self.bmTargets[bmImgId].title
				}).click(
					function(e){self.store(bmImgId)}
				);
				if (self.textHTML.length > 0){
					img.mouseover(
						function(e){self.changeDescSlice(bmImgId)}
					).mouseout(
						function(e){self.changeDescSlice(false)}
					);
				}
				return img;
			};
			imgOuter.append(x(bmi[i]));
		}
		return imgOuter.get(0);
	}

	BookmarkStoreAt.prototype._createLayout = function(){
		var outer = $('<div id="bookmarksOuter"></div>').get(0);
		if (this.titleHTML.length > 0) outer.appendChild(this._getTitle());
		if (this.textHTML.length > 0) outer.appendChild(this._getText());
		outer.appendChild(this._getImageItems());
		this.container.appendChild(outer);
	}
/* << */


/* >> login teaser (requires jQuery 1.2.6) Version: rel-2-0-0 */
	function handleFieldPrompt(fieldList){
		$(function(){
			for (var i = 0; i < fieldList.length; ++i){
				function x(f){
					var elm = $('#' + f);
					if (elm.length === 0) {
						elm = $(f);
					}
					elm.focus(
						function(e){hidePrompt($(this), e)}
					).blur(
						function(e){
							if ($(this).val() == ''){
								showPrompt($(this), e)
							}
						}
					)
					if (elm.val() != '') hidePrompt(elm);
				}
				x(fieldList[i]);
			}
		});
	}
	
	function hidePrompt(field, e){
		field.css({'background-image': 'none'});
	}

	function showPrompt(field, e){
		field.removeAttr('style');
	}
/* << */


/* >> client current date (requires jQuery 1.2.6) Version: rel-2-0-0 */
	function getCurrentDate(id){
		$(function(){
			//getElement(id).innerHTML = '';
			var week = ['Sonntag', 'Montag', 'Dienstag', 'Mittwoch', 'Donnerstag', 'Freitag', 'Samstag'];
			var month = ['Januar', 'Februar', 'März', 'April', 'Mai', 'Juni', 'Juli', 'August', 'September', 'Oktober', 'November', 'Dezember'];
			var date = new Date();
			var d = week[date.getDay()];
			var dom = date.getDate();
			var m = month[date.getMonth()];
			var y = date.getFullYear();
			var std = date.getHours();
			var min = date.getMinutes();
			var sec = date.getSeconds();
			if (dom < 10) dom = '0' + dom;
			if (min < 10) min = '0' + min;
			if (sec < 10) sec = '0' + sec;
			var timeSection = $('<span class="timeSection"><span class="inner"></span></span>');
			var timeSectionInner = timeSection.find('.inner');
			timeSectionInner.append('<span class="sepYT">,</span>')
				.append('<span class="hour">' + std + '</span>')
				.append('<span class="sepHM">:</span>')
				.append('<span class="min">' + min + '</span>')
				.append('<span class="sepHM">:</span>')
				.append('<span class="sec">' + sec + '</span>')
				.append('<span class="clock">Uhr</span>')
			$('#' + id).empty().append(
				$('<div></div>')
					.append('<span class="weekday">' + d + '</span>')
					.append('<span class="sepWD">,</span>')
					.append('<span class="text">den </span>')
					.append('<span class="day">' + dom + '.</span>')
					.append('<span class="month">' + m + '</span>')
					.append('<span class="year">' + y + '</span>')
					.append(timeSection)
			)
			setTimeout(function(){getCurrentDate(id)}, 1000);
		});
	}
/* << */


/* >> LL_TableColumnEnhancer (require jQuery 1.2.6) Version: rel-2-0-0 */
	LL_TableColumnEnhancer = function(){
		this.table = null;
		this.colConfig = [0,1,2,-3,-2,-1];
		this.tableFullWidth = 0;
		this.tableFullHeight = 0;
		this.tableCurrentWidth = 0;
		this.tableCurrentHeight = 0;
		this.variantsWidth = 0;
		this.variantsHeight = 0;
		this.moved = false;
		this.columns = []; // holds to hide columns with there cells
		this.idOuter = null;
		$('#variants').hide();
	}
	
	LL_TableColumnEnhancer.prototype.setColumnConfig = function(){
		if (arguments.length > 0){
			var conf = [];
			for (var i = 0; i < arguments.length; ++i){
				if (! isNaN(parseInt(arguments[i]))) conf.push(arguments[i]);
			}
			if (conf.length > 0) this.colConfig = conf;
			return this.colConfig;
		}
		return null;
	}
	
	LL_TableColumnEnhancer.prototype.init = function(id, idOuter, display){
		var t = $('#' + id).get(0);
		this.idOuter = idOuter;
		var columnsIndex = [];
		var self = this;
		if (t.nodeName.toLowerCase() == 'table'){
			this.table = t;
			this.tableFullWidth = t.offsetWidth;
			this.tableFullHeight = t.offsetHeight;
			var tbody = this.getElementChildNodeWithName(t, 'tbody', null);
			for (var i = 0; i < this.getElementChildNodesCount(tbody, 1); ++i){
				var row = this.getElementChildNodeWithName(tbody, 'tr', i);
				for (var j = 0; j < this.getElementChildNodesCount(row, 1); ++j){
					columnsIndex = this.getColumnsIndex(this.getElementChildNodesCount(row, 1), this.colConfig);
					var cell = this.getElementChildNodeWithName(row, 'td', j);
					if (! this._inArray(j, columnsIndex)){
						if (this.columns[j] instanceof DefaultTableColumn){
							this.columns[j].addCell(cell);
						}else{
							this.columns[j] = new DefaultTableColumn(j);
							this.columns[j].addCell(cell);
						}
					}
				}
			}
		}
		$('#variantsButtons').show();
		this.updateDisplay(display);
		$('#variantsViewAllButton').click(function(e){self.openInlinePopup()});
		$('#variantsViewLessButton').click(function(e){self.closeInlinePopup()});
		$('#variants').show();
		this.tableCurrentWidth = this.getContentAreaDimensions().w;
		this.tableCurrentHeight = t.offsetHeight;
		this.variantsWidth = $('#' + this.idOuter).width();
		this.variantsHeight = $('#' + this.idOuter).height();
	}

	LL_TableColumnEnhancer.prototype.getContentAreaDimensions = function(){
		var ca, dims;
		ca = $('td.contentColumn');
		return {'w': ca.width(), 'h': ca.height()};
	}
	
	LL_TableColumnEnhancer.prototype.openInlinePopup = function(){
		var contOrig = $('#variantsOuterShell');
		var cont = $('#variantsPopupContainer');
		var elm = $('#' + this.idOuter);
		if (elm){
			cont.empty().append(elm);
			contOrig.empty().append(
				$('<img/>').attr({
					'src': '../px/spc.gif',
					'height': this.variantsHeight + 32,
					'width': 1,
					'class': 'variantsDvShellDummy'
				})
			);
			this.updateDisplay(true);
			$('#variantsInlinePopupOuter').show();
			this.tableFullWidth = this.table.offsetWidth;
			if (this.tableFullWidth <= this.tableCurrentWidth){
				this.tableFullWidth = this.tableCurrentWidth;
				setNodeAttribute(this.table, 'style', {'width': this.tableCurrentWidth + 'px'});
			}
			var distance = ((this.tableFullWidth - this.tableCurrentWidth) / 2) + 12;
			$('#variantsPopupShell').css('left', '-' + distance + 'px');
			this.moved = true;
			var self = this;
			$('#variantsViewLessButton').click(function(e){self.closeInlinePopup()});
		}
	}
	
	LL_TableColumnEnhancer.prototype.closeInlinePopup = function(){
		var cont = $('#variantsOuterShell').get(0);
		$('#variantsInlinePopupOuter').hide();
		var elm = $('#' + this.idOuter);
		if (elm.size() > 0){
			this.updateDisplay(false);
			cont.replaceChild(elm.get(0), this.getElementChildNodeWithName(cont, 'img', null));
		}
		var self = this;
		$('#variantsViewAllButton').click(function(e){self.openInlinePopup()});
	}

	LL_TableColumnEnhancer.prototype.updateDisplay = function(display, e){
		if (e) e.stop();
		this.hidden = true;
		if (display) this.hidden = false;
		for (var i = 0; i < this.columns.length; ++i){
			var col = this.columns[i];
			if (col instanceof DefaultTableColumn) col.setDisplay(display);
		}
		if (this.hidden){
			$('#variantsViewAllButton').css({'display': 'inline'});
			$('#variantsViewLessButton').css({'display': 'none'});
		}else{
			$('#variantsViewAllButton').css({'display': 'none'});
			$('#variantsViewLessButton').css({'display': 'inline'});
		}
	}
	
	LL_TableColumnEnhancer.prototype._inArray = function(needle, arr){
		for (var i = 0; i < arr.length; ++i){
			if (needle == arr[i]) return true;
		}
		return false;
	}
	
	LL_TableColumnEnhancer.prototype.getElementChildNodeWithName = function(parent, name, pos){
		var pos = pos ? pos : 0;
		var count = 0;
		var childs = parent.childNodes;
		if (childs){
			for (var i = 0; i < childs.length; ++i){
				var c = childs[i];
				if (c.nodeType == 1){
					var nname = c.nodeName.toLowerCase();
					var n = name.toLowerCase();
					if (n = nname && count == pos) return c;
					++count;
				}
			}
		}
		return null;
	}
	
	LL_TableColumnEnhancer.prototype.getElementChildNodesCount = function(parent, type){
		var childs = parent.childNodes;
		var count = 0;
		if (childs){
			for (var i = 0; i < childs.length; ++i){
				var c = childs[i];
				if (c.nodeType == type) ++count;
			}
		}
		return count;
	}

	LL_TableColumnEnhancer.prototype.getColumnsIndex = function(colCount, permCols){
		for (var i = 0; i < permCols.length; ++i){
			if (permCols[i] < 0) permCols[i] += colCount;
		}
		return permCols;
	}


	DefaultTableColumn = function(cid){
		this.cid = cid;
		this.cells = [];
		this.hidden = false;
	}
	
	DefaultTableColumn.prototype.addCell = function(Cell){
		if (Cell.nodeName.toLowerCase() == 'td' || Cell.nodeName.toLowerCase() == 'th'){
			this.cells.push(new DefaultTableCell(Cell));
		}
	}
	
	DefaultTableColumn.prototype.setDisplay = function(display){
		this.hidden = true;
		if (display) this.hidden = false;
		for (var i = 0; i < this.cells.length; ++i){
			this.cells[i].setDisplay(display);
		}
	}


	DefaultTableCell = function(domel){
		this.domel = domel;
		this.hidden = false;
		this.attrs = {};
		this.children = null;
		this.content = null;
		this._backupAttrsAndChildren();
		this._backupContent();
	}
	
	DefaultTableCell.prototype._backupAttrsAndChildren = function(){
		var elm = this.domel;
		this.children = elm.childNodes;
		for (var i = 0; i < elm.attributes.length; ++i){
			var attr = elm.attributes[i];
			var name = attr.nodeName;
			var value = attr.nodeValue;
			this.attrs[name] = value;
		}
	}
	
	DefaultTableCell.prototype._backupContent = function(){
		var node = this.domel;
		while (node.nodeType == 1){
			node = node.childNodes[0];
			if (node && node.nodeType == 3){
				this.content = node.nodeValue;
				break;
			}else{
				if (! node) break;
			}
		}
	}
	
	DefaultTableCell.prototype.setDisplay = function(display){
		if (display){
			this.hidden = false;
			$(this.domel).css({'display': ''});
			return true;
		}
		this.hidden = true;
		$(this.domel).css({'display': 'none'});
		return true;
	}
/* << */


/* >> LL_CookieTool (require jQuery 1.2.6+) Version: rel-1-1-0  **-Deprecated-** use jquery cookie plugin instead */
	LL_CookieTool = {
		isCookieEnabled: function(){
			if (navigator.cookieEnabled == true) return true;
			return false;
		},
		setCookies: function(cObjs){
			for (var i = 0; i < arguments.length; ++i){
				var c = arguments[i];
				c.setCookie();
			}
		},
		getCookie: function(name){
			var cstr = document.cookie;
			if (cstr.length > 0){
				cookies = cstr.split('; ');
				for (var i = 0; i < cookies.length; ++i){
					var cook = cookies[i];
					if (cook.substring(0, cook.lastIndexOf('=')) == name){
						return cook.substring(cook.lastIndexOf('=') + 1 , cook.length);
					}
				}
			}
			return null;
		},
		eraseCookie: function(name, domain, path){
			var c = new CookieData(name, null, domain, path, null, null);
			c.eraseCookie();
		}
	}
	
	CookieData = function(name, value, domain, path, expires, secure){
		this.name = name;
		this.value = value;
		this.domain = domain;
		this.path = path;
		this.expires = expires;
		this.secure = secure;
	}
	
	CookieData.prototype.setCookie = function(){
		var cook = this.name + '=' + unescape(this.value);
		cook += this.domain ? '; domain=' + this.domain : '';
		cook += this.expires ? '; expires=' + this.expires : '';
		cook += this.path ? '; path=' + this.path : '/';
		cook += this.secure ? '; secure' : '';
		document.cookie = cook;
	}
	
	CookieData.prototype.eraseCookie = function(){
		var cook = this.name + '=; expires=Thu, 01-Jan-70 00:00:01 GMT';
		cook += this.domain ? '; domain=' + this.domain : '';
		cook += this.path ? '; path=' + this.path : '/';
		document.cookie = cook;
	}
/* << */


/* >> LL_FontSizeAdjust (require jQuery 1.2.6, plugins: cookie 1.0) Version: rel-2-0-0 */
	LL_FontSizeAdjust = {
		symbols: [],
		currentFS: 0,
		domain: location.hostname,
		customerPath: 'standard/xx/',
		coId: -1,
		init: function(path, coId){
			// path: Specifies the image and css path
			// coId: The content object id of a special startpage with different css rules.
			if (coId) this.coId = coId;
			this.connectAndGetSymbols();
			this.setCustomerPath(path);
			this.handleFontSize(this.getFontSize());
		},
		connectAndGetSymbols: function(){
			var self = this;
			$('div[id*=font_adjust_symbol_]').each(
				function(n){
					self.symbols.push(this);
					$(this).click(function(){self.handleFontSize(n)});
				}
			);
		},
		setCustomerPath: function(path){
			var p = path ? path : this.customerPath;
			this.customerPath = p;
		},
		getFontSize: function(){
			var size = $.cookie('FontSizeAdjust');
			if (size) return size;
			return this.currentFS;
		},
		setFontSize: function(size){
			$.cookie('FontSizeAdjust', size, {path: '/', expires: 100});
			return size;
		},
		isStartpage: function(){
			var ps = location.href.search(/_id_/);
			if (ps > -1){
				var url = location.href;
				var slice1 = url.substring(ps + 4, url.length);
				var coId = slice1.substring(0, slice1.indexOf('_'));
				if (this.coId == coId) return true;
				return false;
			}
			return false;
		},
		handleFontSize: function(size, e){
			if (navigator.cookieEnabled){
				this.currentFS = this.setFontSize(size);
				var head = $('head').get(0);
				$('#fontSizeAdjustCssLink').remove();
				$('#fontSizeAdjustCssLink_startpage').remove();
				var l1 = document.createElement('link');
				l1.href = this.customerPath + 'layout_fontSize' + this.currentFS + '.css';
				l1.type = 'text/css';
				l1.rel = 'stylesheet';
				l1.id = 'fontSizeAdjustCssLink';
				head.appendChild(l1);
				if(this.isStartpage()){
					var l2 = document.createElement('link');
					l2.href = this.customerPath + 'layout_fontSizeStartpage' + this.currentFS + '.css';
					l2.type = 'text/css';
					l2.rel = 'stylesheet';
					l2.id = 'fontSizeAdjustCssLink_startpage';
					head.appendChild(l2);
				}
			}
			this.switchStyleSheet(this.currentFS);
		},
		switchStyleSheet: function(size){
			// change the stylesheet element at the head element.
			if (this.symbols.length > 0){
				for (var i = 0; i < this.symbols.length; ++i){
					var s = this.symbols[i];
					if (i == size){
						this.updateSymbol(s, 'act');
					}else{
						this.updateSymbol(s, 'pass');
					}
				}
			}
		},
		updateSymbol: function(sym, status){
			var className = sym.className;
			var pref = className.substring(0, className.lastIndexOf('_') + 1);
			var suff = className.substring(className.lastIndexOf('_') + 1, className.length).toLowerCase();
			if (status){
				sym.className = pref + status;
				return sym;
			}else{
				if (suff == 'pass'){
					sym.className = pref + 'act';
					return sym;
				}
				sym.className = pref + 'pass';
				return sym;
			}
			return null;
		},
		handleSymbolStyle: function(){
			// switch the symbol css rules to get an active or passive symbol.
		}
	}
/* << */


/* >> LL_RelationshipManager (require jQuery 1.2.6+) Version: rel-2-0-0 */
	LL_RelationshipManager = function(){
		this.relHandler = [];
	}
	
	LL_RelationshipManager.prototype.addRelHandler = function(Handler){
		if (Handler instanceof DefaultRelationHandler){
			this.relHandler.push(Handler);
			if (Handler.elms.length > 0 && Handler.autoAction) Handler.action();
		}
	}

	// abstract relation handler
	DefaultRelationHandler = function(){
		this.name = 'testDefaultHandler';
		this.links = document.links;
		this.autoAction = false;
		this.filter(this.name);
		this.elms = []; // holds the elements and the rel attrs as a json object
	}
	
	// filter links wih rels with a given name and allocates the attributes.
	DefaultRelationHandler.prototype.filter = function(name){
		var links = this.links;
		for (var i = 0; i < links.length; ++i){
			this.addElementAndGetRelAttrs(links[i]);
		}
	}
	
	DefaultRelationHandler.prototype.addElementAndGetRelAttrs = function(elm){
		var attr = $(elm).attr('rel');
		if (attr){
			if (attr.toLowerCase() == this.name || attr.substring(0, attr.indexOf('[')).toLowerCase() == this.name){
				var relAttrs = null;
				if (attr.search(/\[/) > -1 && attr.search(/\]/) > -1){
					relAttrs = attr.substring(attr.indexOf('[') + 1, attr.lastIndexOf(']'));
					relAttrs = relAttrs.split(',');
				}
				var obj = {'elm': elm, 'relAttrs': relAttrs};
				this.elms.push(obj);
				return obj;
			}
		}
		return null;
	}
	
	DefaultRelationHandler.prototype.action = function(){} // do something with the rels


	// Use the xpopup functionality to display detail information
	XPopupHandler = function(){
		this.name = 'xpopup';
		this.autoAction = true;
		this.filter(this.name);
	}
	XPopupHandler.prototype = new DefaultRelationHandler();
	
	XPopupHandler.prototype.action = function(){
		var self = this;
		setTimeout(
			function(){
				for (var i = 0; i < self.elms.length; ++i){
					var TAttrs = {};
					var TAttrsArr = [];
					var elm = self.elms[i].elm;
					var eAttrs = self.elms[i].relAttrs;
					if (eAttrs && eAttrs.length == 6){
						TAttrs.url = elm.href;
						TAttrs.height = 'auto';
						TAttrs.width = 'auto';
					}else{
						var TAttrsRaw = eAttrs.slice(6);
						for (var j = 0; j < TAttrsRaw.length; ++j){
							var TAttrRawSplitted = TAttrsRaw[j].split(',');
							for (var k = 0; k < TAttrRawSplitted.length; ++k){
								var tAttrRaw = TAttrRawSplitted[k];
								var key = tAttrRaw.substring(0, tAttrRaw.indexOf(':'));
								var value = tAttrRaw.substring(tAttrRaw.indexOf(':') + 1, tAttrRaw.length);
								TAttrs[key] = value;
							}
						}
						if (! TAttrs.url) TAttrs.url = elm.href;
					}
					LL_XPopup.registerPopup(
						elm,
						eAttrs[0],
						eAttrs[1],
						eAttrs[2],
						eAttrs[3],
						eAttrs[4],
						eAttrs[5],
						TAttrs
					);
				}
			},
			10
		);
	}
	
	// use the xpopup to display lightbox photogalleries
	LightboxHandler = function(){
		this.name = 'lightbox';
		this.autoAction = true;
		this.filter(this.name);
	}
	LightboxHandler.prototype = new DefaultRelationHandler();
	
	LightboxHandler.prototype.action = function(){
		var self = this;
		setTimeout(
			function(){
				for (var i = 0; i < self.elms.length; ++i){
					var TAttrs = {};
					var TAttrsArr = [];
					var elm = self.elms[i].elm;
					var eAttrs = self.elms[i].relAttrs;
					if (eAttrs && eAttrs.length == 1){
						TAttrs.group = eAttrs[0];
					}
					TAttrs.url = elm.href;
					TAttrs.background = 'true';
					TAttrs.fixedPosition = 'true';

					LL_XPopup.registerPopup(
						elm,
						'click',
						'IMAGE',
						'p_c',
						'c',
						0,
						0,
						TAttrs
					);
				}
			},
			10
		);
	}
/* << */


/* >> LL_XPopup (require jQuery 1.2.6 and LL_RelationshipManager with XPopupHandler) Version: rel-2-0-1 */
	/*
		Possible positions for the source and popup element:
		nw, w, sw, n, c, s, ne, e, se, p_nw, p_w, p_sw, p_n, p_c, p_s, p_ne, p_e, p_se, cursor (only for the source element)
		
		possible types: IMAGE, WEBPAGE, AJAX
			IMAGE: Display images in a special gallery mode.
			WEBPAGE: Sisplay a web page in an iframe.
			AJAX: Load ajax-content into a div container with a given url.
		
		Example for rel-Attributes: xpopup[onmouseenter,WEBPAGE,ne,nw,10,10,height:300,width:200]
			identfier[event, type, source position, popup position, popup margin width, popup margin height,--mode attributes--]
			--mode attributes--:
				A commata separated list with key:value items.
				Note: Each mode can have different attributes.
	*/
	LL_XPopup = {
		xpopups: [],
		popup: null,
		initScrollPos: 0,
		preparedGallery: [],
		currentGalleryIdx: -1,
		galleryOverall: -1,
		slideshowBusy: 0,
		slideshowInterval: null,
		nextConnect: null,
		previousConnect: null,
		closeConnect: null,
		registerPopup: function(elm, event, type, spos, ppos, margin_w, margin_h, TypeAttrs){
			//type = 'AJAX';
			var self = this;
			setTimeout(function(){self.makePopup()}, 1);
			switch (type){
				case 'IMAGE':
					this.xpopups.push(new ImageXPopup(elm, event, spos, ppos, margin_w, margin_h, TypeAttrs));
					break;
				case 'WEBPAGE':
					this.xpopups.push(new WebpageXPopup(elm, event, spos, ppos, margin_w, margin_h, TypeAttrs));
					break;
				case 'AJAX':
					this.xpopups.push(new AjaxXPopup(elm, event, spos, ppos, margin_w, margin_h, TypeAttrs));
					break;
			}
		},
		makePopup: function(){
			if (! this.popup){
				this.popup = $('<div></div>').append(
						this.makeCloseButton()
					).append(
						$('<div>').attr(
							{'id': 'xpopupContent'}
						)
					).append(
						$('<div>').attr(
							{'id': 'xpopupAddOns'}
						)
					).attr(
						{'id': 'xpopup', 'class': 'xpopup'}
					).css(
						{'display': 'none'}
					).get(0);
				$('body').append(this.popup);
			}
			return this.popup;
		},
		makeCloseButton: function(){
			var self = this;
			$(document).keydown(function(e){self.destruct(e)});
			return $('<div>').append(
				$('<div>').append(
					$('<img>').attr(
						{'src': '/xist4c/px/spc.gif', 'alt': '', 'id': 'xpopupCloseGfx'}
					).click(
						function(e){self.destruct(e)}
					)
				).attr(
					{'class': 'inner'}
				)
			).attr(
				{'id': 'xpopupCloseButton'}
			).get(0)
		},
		showBodyScrollbars: function(){
			$('body').css('overflow', 'auto');
		},
		cleanUp: function(){
			var self = this;
			var bg = $('#xpopup_background');
			if (bg.size() > 0){
				bg.fadeOut(
					function(){
						bg.remove();
						self.showBodyScrollbars();
					}
				)
			}else{
				this.showBodyScrollbars();
			}
			$('#xpopupGalleryOverview').remove();
			$('#xpopup').unbind('.specials');
			with(this){
				initScrollPos = 0;
				preparedGallery = [];
				currentGalleryIdx = -1;
				galleryOverall = -1;
				slideshowBusy = 0;
				if (slideshowInterval) clearTimeout(slideshowInterval);
			}
		},
		destruct: function(e){
			if (this.popup){
				if(e){
					if (e.type == 'keydown'){
						if (e.keyCode == 27){
							$(this.popup).fadeOut();
							this.cleanUp();
						}
					}else if (e.type == 'click' || e.type == 'mouseleave' || e.type == 'mouseout'){
						if (e.type == 'click'){
							$(this.popup).fadeOut();
							this.cleanUp();
						}else{
							$(this.popup).hide();
							this.cleanUp();
						}
					}
				}else{
					$(this.popup).fadeOut();
					this.cleanUp();
				}
			}
		}
	}
	
	DefaultXPopup = function(src, event, spos, ppos, margin_w, margin_h, TypeAttrs){
		this.src = src;
		this.event = event;
		this.spos = spos; // layer position on the connected source element
		this.ppos = ppos; // position of the popup layer relative to the layer position of the source element
		this.mw = margin_w; // margin width of the popup from the connected source element (negative integer values allowed)
		this.mh = margin_h; // margin height of the popup from the connected source element (negative integer values allowed)
		this.Attrs = TypeAttrs;
		this.srcDeferred = null;
		this.srcOutDeferred = null;
		if (arguments.length >= 6){
			this.connectSrcElement();
		}
	}

	DefaultXPopup.prototype.connectSrcElement = function(){
		var self = this;
		$(this.src).bind(this.event, function(e){self.show(e)});
	}

	DefaultXPopup.prototype.pushContentIntoPopup = function(){
		$('#xpopupContent').empty().append(this.getContent());
	}
	
	DefaultXPopup.prototype.getContent = function(){
		return $('<span>Test Content of the default xpopup!</span>').get(0);
	}

	DefaultXPopup.prototype.getAttr = function(name){
		if (this.Attrs){
			for (var k in this.Attrs){
				if (k.toLowerCase() == name.toLowerCase()) return this.Attrs[name];
			}
		}
		return null;
	}

	DefaultXPopup.prototype.setPopupPosition = function(src, mousePos){
		var self = this;
		var p = LL_XPopup.popup;
		var srcDims = {'w': $(src).outerWidth(), 'h': $(src).outerHeight()};
		var srcPos = {'x': $(src).offset().left, 'y': $(src).offset().top}
		var mCords = mousePos;
		var pDims = {'w': $(p).width(), 'h': $(p).height()};
		var vpDims = {'w': $(window).width(), 'h': $(window).height()};
		var vpPos = {'x': $(document).scrollLeft(), 'y': $(document).scrollTop()}
		var pWidth = pDims.w;
		var pHeight = pDims.h;
		var buffer = 0;
		var xPos, yPos, x, y;

		LL_XPopup.initScrollPos = vpPos;
		if (this.spos.substring(0, 2) == 'p_'){
			srcDims = vpDims;
			if(! this.isIE()){
				if (this.isFixedPosition()) vpPos = {'x': 0, 'y': 0};
			}
			srcPos = vpPos;
		}else{
			if(! this.isIE()){
				if (this.isFixedPosition()){
					srcPos.x = srcPos.x - vpPos.x;
					srcPos.y = srcPos.y - vpPos.y;
					vpPos = {'x': 0, 'y': 0};
				}
			}
		}
		if (this.spos == 'nw' || this.spos == 'w' || this.spos == 'sw' || this.spos == 'p_nw' || this.spos == 'p_w' || this.spos == 'p_sw'){
			x = srcPos.x;
		}else if (this.spos == 'n' || this.spos == 'c' || this.spos == 's' || this.spos == 'p_n' || this.spos == 'p_c' || this.spos == 'p_s'){
			x = srcPos.x + (srcDims.w / 2);
		}else if (this.spos == 'ne' || this.spos == 'e' || this.spos == 'se' || this.spos == 'p_ne' || this.spos == 'p_e' || this.spos == 'p_se'){
			x = srcPos.x + srcDims.w;
		}else if (this.spos == 'cursor'){
			x = mCords.x;
		}else{
			x = 0;
		}
		
		if (this.spos == 'nw' || this.spos == 'n' || this.spos == 'ne' || this.spos == 'p_nw' || this.spos == 'p_n' || this.spos == 'p_ne'){
			y = srcPos.y;
		}else if (this.spos == 'w' || this.spos == 'c' || this.spos == 'e' || this.spos == 'p_w' || this.spos == 'p_c' || this.spos == 'p_e'){
			y = srcPos.y + (srcDims.h / 2);
		}else if (this.spos == 'sw' || this.spos == 's' || this.spos == 'se' || this.spos == 'p_sw' || this.spos == 'p_s' || this.spos == 'p_se'){
			y = srcPos.y + srcDims.h;
		}else if (this.spos == 'cursor'){
			y = mCords.y;
		}else{
			y = 0;
		}
		
		relPopPos = this.getRelativePopupPosition(x, y, srcDims, pDims, this.ppos);
		xPos = relPopPos.x;
		yPos = relPopPos.y;
		if (xPos + pWidth > vpDims.w + vpPos.x) xPos = vpDims.w + vpPos.x - (pWidth + buffer);
		if (yPos + pHeight > vpDims.h + vpPos.y) yPos = vpDims.h + vpPos.y - (pHeight + buffer);
		if (xPos <= vpPos.x) xPos = vpPos.x + buffer;
		if (yPos <= vpPos.y) yPos = vpPos.y + buffer;

		$(LL_XPopup.popup).animate({'left': xPos, 'top': yPos}, 'fast', 'swing', function(){
				self.handlePopupPositionMode();
		});
	}
	
	DefaultXPopup.prototype.setPopupWidth = function(){
		$('#xpopup, #xpopupContent').css({'width': null});
	}
	
	DefaultXPopup.prototype.isIE = function(){
		if(window.clientInformation){
			if (window.clientInformation.appName == 'Microsoft Internet Explorer') return true;
		}
		return false;
	}
	
	DefaultXPopup.prototype.isFixedPosition = function(){
		var fp = this.getAttr('fixedPosition');
		if (fp){
			if (fp.toLowerCase() == 'true' || fp == 1) return true;
		}
		return false;
	}
	
	DefaultXPopup.prototype.handlePopupPositionMode = function(e){
		if (! this.isIE()){
			if (this.isFixedPosition()){
				return $(LL_XPopup.popup).attr('class', 'xpopup_fixed');
			}
		}
		return $(LL_XPopup.popup).attr('class', 'xpopup');
	}
	
	DefaultXPopup.prototype.getRelativePopupPosition = function(xPos, yPos, srcDims, pDims, ppos){
		if (!ppos || ppos == 'nw'){
			xPos += this.mw / 1;
			yPos += this.mh / 1;
			return {'x': xPos, 'y': yPos};
		}else if(ppos == 'w'){
			xPos += this.mw / 1;
			return {'x': xPos, 'y': yPos - (pDims.h / 2)};
		}else if(ppos == 'sw'){
			xPos += this.mw / 1;
			yPos -= this.mh / 1;
			return {'x': xPos, 'y': yPos - pDims.h};
		}else if(ppos == 'n'){
			yPos += this.mh / 1;
			return {'x': xPos - (pDims.w / 2), 'y': yPos};
		}else if(ppos == 'c'){
			return {'x': xPos - (pDims.w / 2), 'y': yPos - (pDims.h / 2)};
		}else if(ppos == 's'){
			yPos -= this.mh / 1;
			return {'x': xPos - (pDims.w / 2), 'y': yPos - pDims.h};
		}else if(ppos == 'ne'){
			xPos -= this.mw / 1;
			yPos += this.mh / 1;
			return {'x': xPos - pDims.w, 'y': yPos};
		}else if(ppos == 'e'){
			xPos -= this.mw / 1;
			return {'x': xPos - pDims.w, 'y': yPos - (pDims.h / 2)};
		}else if(ppos == 'se'){
			xPos -= this.mw / 1;
			yPos -= this.mh / 1;
			return {'x': xPos - pDims.w, 'y': yPos - pDims.h};
		}
	}
	
	DefaultXPopup.prototype.handleSrcAndPopupConnect = function(){
		if (this.event != 'click' && this.spos != this.ppos){
			$(this.src).bind('mouseleave', function(e){LL_XPopup.destruct(e)});
		}else if (this.event != 'click' && this.spos == this.ppos){
			$(LL_XPopup.popup).bind('mouseleave', function(e){LL_XPopup.destruct(e)});
		}
	}
	
	DefaultXPopup.prototype.makeAddOns = function(e){
		$('#xpopupAddOns').empty();
	}
	
	DefaultXPopup.prototype.makeBackground = function(r,g,b){
		var red, green, blue;
		rv = r ? r : 0;
		gv = g ? g : 0;
		bv = b ? b : 0;
		var bg = $('<div> </div>').attr(
			'id', 'xpopup_background'
		).css(
			{
				'display': 'none',
				'position': 'absolute',
				'z-index': 500000,
				'left': 0,
				'top': 0,
				'background-color': 'rgb(' + rv + ',' + gv + ',' + bv + ')',
				'width': $('body').get(0).scrollWidth + 'px',
				'height': $('body').get(0).scrollHeight + 'px'
			}
		);
		if ($('#xpopup_background').size() == 0){
			var bg = $(bg).click(function(e){LL_XPopup.destruct(e)})
			$('body').append(bg);
			bg.css({'display': 'block', 'opacity': 0}).fadeTo('fast', 0.9);
		}
	}
	
	DefaultXPopup.prototype.hideBodyScrollbars = function(){}

	DefaultXPopup.prototype.show = function(e){
		var mousePos = {'x': 0, 'y': 0};
		if (e){
			e.preventDefault();
			mousePos = {'x': e.pageX, 'y': e.pageY};
		}
		var aos = $('#xpopupAddOns');
		aos.hide();
		src = this.src;
		this.hideBodyScrollbars();
		this.pushContentIntoPopup();
		this.handleSrcAndPopupConnect();
		this.makeAddOns();
		aos.show();
		var self = this;
		setTimeout(
			function(){
				self.setPopupPosition(src, mousePos);
				$(LL_XPopup.popup).fadeIn();
			},
			1
		);
	}

	// Image xpopup
	ImageXPopup = function(src, event, spos, ppos, margin_w, margin_h, TypeAttrs){
		/* TypeAttrs: url, href, jsFunc, height, width, background
		 * url: Source of the image to display.
		 * group: An identifier for group related images.
		 * href: Link reference for the image.
		 * jsFunc: Mochikit bind or partial functions.
		 * height: Popup height.
		 * width: Popup width.
		 * background: The popup stay on a dark background
		 * fixedPosition: The popup is position fixed and has no response on scroll events.
		 */
		this.constructor(src, event, spos, ppos, margin_w, margin_h, TypeAttrs);
		this.image = this.makeImage(this.getAttr('url'), {'border': 0, 'alt': '', 'title': ''});
		this.appearingHud = null;
		this.activeHud = false;
	}
	ImageXPopup.prototype = new DefaultXPopup();
	
	ImageXPopup.prototype.setPopupWidth = function(w){
		var p = $('#xpopup');
		var pc = $('#xpopupContent');
		var imgWidth = w.substring(0, w.length -2) / 1;
		var pl = pc.css('padding-left');
		pl = pl.substring(0, pl.length -2) / 1;
		var pr = pc.css('padding-right');
		pr = pr.substring(0, pr.length -2) / 1;
		p.css({'width': (imgWidth + pl + pr) + 'px'});
	}
	
	ImageXPopup.prototype.getSrcImage = function(){
		nodes = $('img', this.src);
		if (nodes.size() > 0) return nodes.get(0);
		return null;
	}
	
	ImageXPopup.prototype.getSrcImageTitle = function(){
		var elm = this.getSrcImage();
		if (elm && elm.title && elm.title != '') return elm.title;
		return null;
	}

	ImageXPopup.prototype.prepareGalleryByGroup = function(){
		LL_XPopup.preparedGallery = [];
		LL_XPopup.currentGalleryIdx = -1;
		LL_XPopup.galleryOverall = -1;
		var grp = this.getAttr('group');
		if (grp){
			var xpopups = LL_XPopup.xpopups;
			var idx = -1;
			for (var i = 0; i < xpopups.length; ++i){
				var xp = xpopups[i];
				if (xp instanceof ImageXPopup){
					if (xp.getAttr('group') == grp){
						idx++;
						if (xp === this) LL_XPopup.currentGalleryIdx = idx;
						LL_XPopup.preparedGallery.push(xp);
					}
				}
			}
			if(LL_XPopup.preparedGallery.length > 0) LL_XPopup.galleryOverall = LL_XPopup.preparedGallery.length;
		}
	}
	
	ImageXPopup.prototype.makeImage = function(src, attrs){
		var img = new Image();
		img.src = src;
		for (var k in attrs){
			if (k == 'class'){
				img.className = attrs[k];
			}else{
				img[k] = attrs[k];
			}
		}
		return img;
	}
	
	ImageXPopup.prototype.resizeImgOnOverflow = function(img, maxHeight, maxWidth){
		var h = img.height;
		var w = img.width;
		var ah = maxHeight;
		var aw = maxWidth;
		if (ah && aw){
			if (h > ah){
				w = Math.floor(w * ah / h);
				h = ah;
			}
			if (w > aw){
				h = Math.floor(h * aw / w);
				w = aw;
			}
			img.height = h;
			img.width = w;
		}
		return img;
	}
	
	ImageXPopup.prototype.makeImageTitleIfAny = function(){
		var t = this.getSrcImageTitle();
		if (t){
			return $('<div>').append(
				$('<span>' + t + '</span>')
			).attr(
				{'id': 'xpopupImgTitle', 'class': 'xpopupImgTitle'}
			).get(0);
		}
		return null;
	}
	
	ImageXPopup.prototype.activateHud = function(e){
		if (! this.appearingHud && ! this.activeHud){
			this.appearingHud = 1;
			this.activeHud = true;
			var self = this;
			$('#xpopupHoverMenuOuter').fadeIn('fast');
			self.appearingHud = null;
		}
		this.activeHud = true;
	}
	
	ImageXPopup.prototype.deactivateHud = function(e){
		if (this.activeHud){
			$('#xpopupHoverMenuOuter').hide();
		}
		this.activeHud = false;
	}

	ImageXPopup.prototype.makeHudAndPrepareGallery = function(){
		var self = this;
		$(LL_XPopup.popup).unbind('mousemove.special');
		$(LL_XPopup.popup).bind('mousemove.special', function(e){
			e.preventDefault();
			e.stopPropagation();
			self.activateHud(e);
		});
		$('#xpopup_background').bind('mouseover.special', function(e){
			e.preventDefault();
			e.stopPropagation();
			self.deactivateHud(e);
		});
		this.prepareGalleryByGroup();
		var hm = $('<div>').append(
			$('<div>').append(
				$('<div>').append(
					this.getPlayPauseButton(),
					this.getPreviousButton(),
					this.getNextButton(),
					this.getThumbsButton(),
					this.getCloseButton()
				).attr(
					{'id': 'xpopupHoverMenu'}
				)
			).attr(
				{'id': 'xpopupHoverMenuPos'}
			)
		).attr(
			{'id': 'xpopupHoverMenuOuter'}
		).get(0);
		return hm;
	}
	
	ImageXPopup.prototype.buttonsStateController = function(){
		var buttons = [
			'xpopupHoverMenuPlayPauseButton',
			'xpopupHoverMenuPreviousButton',
			'xpopupHoverMenuNextButton',
			'xpopupHoverMenuThumbsButton',
			'xpopupHoverMenuCloseButton'
		];
	
		if (LL_XPopup.galleryOverall > 1){
			this.updateButton(buttons[0], 'act');
			if (LL_XPopup.slideshowBusy){
				this.updateButton(buttons[0], 'act', 'pauseButton');
			}
			this.updateButton(buttons[3], 'act'); // Thumb not connected now.
		}else{
			this.updateButton(buttons[0], 'pass');
			this.updateButton(buttons[3], 'pass');
		}

		if (LL_XPopup.galleryOverall > 1 && LL_XPopup.currentGalleryIdx > 0){
			this.updateButton(buttons[1], 'act');
		}else{
			this.updateButton(buttons[1], 'pass');
		}
		
		if (LL_XPopup.galleryOverall > 1 && LL_XPopup.currentGalleryIdx < LL_XPopup.preparedGallery.length - 1){
			this.updateButton(buttons[2], 'act');
		}else{
			this.updateButton(buttons[2], 'pass');
		}
		this.updateButton(buttons[4], 'act');
	}
	
	ImageXPopup.prototype.getPlayPauseButton = function(){
		var self = this;
		return $('<div>').attr(
			{'class': 'playButton_pass', 'id': 'xpopupHoverMenuPlayPauseButton'}
		).click(
			function(e){
				self.handleSlideshow(e);
				self.activeHud = false;
			}
		).get(0);
	}
	
	ImageXPopup.prototype.getPreviousButton = function(){
		var self = this;
		return $('<div>').attr(
			{'class': 'previousButton_pass', 'id': 'xpopupHoverMenuPreviousButton'}
		).click(
			function(e){
				self.changeImage(-1, 'pager', e);
				self.activeHud = false;
			}
		).get(0);
	}
	
	ImageXPopup.prototype.getNextButton = function(){
		var self = this;
		return $('<div>').attr(
			{'class': 'nextButton_pass', 'id': 'xpopupHoverMenuNextButton'}
		).click(
			function(e){
				self.changeImage(1, 'pager', e)
				self.activeHud = false;
			}
		).get(0);
	}

	ImageXPopup.prototype.getThumbsButton = function(){
		var self = this;
		return $('<div>').attr(
			{'class': 'thumbsButton_pass', 'id': 'xpopupHoverMenuThumbsButton'}
		).click(
			function(e){
				self.handleGalleryOverview(e)
				self.activeHud = false;
			}
		).get(0);
	}

	ImageXPopup.prototype.getCloseButton = function(){
		return $('<div>').attr(
			{'class': 'closeButton_pass', 'id': 'xpopupHoverMenuCloseButton'}
		).click(
			function(e){
				LL_XPopup.destruct(e)
				self.activeHud = false;
			}
		).get(0);
	}

	ImageXPopup.prototype.updateButton = function(id, state, cnPrefix){
		var button = $('#' + id);
		if (arguments.length < 3){
			var cn = button.attr('class');
			cnPrefix = cn.substring(0, cn.lastIndexOf('_'));
		}
		button.attr({'class': cnPrefix + '_' + state});
	}
	
	ImageXPopup.prototype.isButtonActive = function(e, className){
		var cn = e.target.className;
		if (className) cn = className;
		var state = cn.substring(cn.lastIndexOf('_') + 1, cn.length).toLowerCase();
		if (state == 'act') return true;
		return false;
	}

	ImageXPopup.prototype.makeAddOns = function(e){
		var aos = $('#xpopupAddOns');
		aos.empty();
		aos.append(this.makeHudAndPrepareGallery());
		$('#xpopupHoverMenu').css({'left': (this.image.width / 2 - 132) + 'px'});
		var title = this.makeImageTitleIfAny();
		aos.append(title);
		this.buttonsStateController();
	}
	
	ImageXPopup.prototype.changeImage = function(idx, modeStr, e){
		if (LL_XPopup.slideshowBusy > 0){
			if (e && this.isButtonActive(e) && modeStr == 'pager'){
				var idx = LL_XPopup.currentGalleryIdx += idx;
				var xpopup = LL_XPopup.preparedGallery[idx];
				xpopup.show();
			}else if (modeStr == 'slideshow'){
				var idx = LL_XPopup.currentGalleryIdx += idx;
				if (idx == LL_XPopup.preparedGallery.length) idx = LL_XPopup.currentGalleryIdx = 0;
				var xpopup = LL_XPopup.preparedGallery[idx];
				var self = this;
				$('#xpopup').fadeOut(
					'fast',
					function(){
						xpopup.pushContentIntoPopup();
						xpopup.makeAddOns();
						setTimeout(
							function(){
								var mousePos = {'x': 0, 'y': 0};
								xpopup.setPopupPosition(xpopup.src, mousePos);
								$('#xpopup').fadeIn();
							},
							500
						);
					}
				);
			}
			if (LL_XPopup.slideshowInterval) clearTimeout(LL_XPopup.slideshowInterval);
			var self = this;
			LL_XPopup.slideshowInterval = setTimeout(function(){self.changeImage(1, 'slideshow')}, 7000);
		}else{
			if (e && this.isButtonActive(e) && modeStr == 'pager'){
				var idx = LL_XPopup.currentGalleryIdx += idx;
				var xpopup = LL_XPopup.preparedGallery[idx];
				xpopup.show();
			}else if(modeStr == 'gallery'){
				var idx = LL_XPopup.currentGalleryIdx = idx;
				var xpopup = LL_XPopup.preparedGallery[idx];
				xpopup.show();
			}
		}
	}
	
	ImageXPopup.prototype.getContent = function(){
		var img = null;
		var href, jsFunc;
		if (this.Attrs){
			var Attrs = this.Attrs;
			img = this.resizeImgOnOverflow(this.image, this.getAttr('height'), this.getAttr('width'));
			height = Attrs.height ? Attrs.height + 'px' : img.height + 'px' ;
			width = Attrs.width ? Attrs.width + 'px' : img.width + 'px';
			if (Attrs.href && ! Attrs.jsFunc){
				href = Attrs.href;
				img = $('<a>').append(img).attr({'href': Attrs.href}, img);
			}
			if (Attrs.jsFunc){
				$(img).css({'cursor': 'pointer'}).click(Attrs.jsFunc)
			}
			if (this.Attrs.background){
				if (this.Attrs.background.toLowerCase() == 'true' || this.Attrs.background == 1) this.makeBackground();
			}
		}
		this.setPopupWidth(width);
		return $('<div>').append(img).css({'height': height, 'width': width, 'overflow': 'auto', 'text-align': 'center'})
	}
	
	ImageXPopup.prototype.changeSlideshowPopupCSS = function(){
		if (LL_XPopup.slideshowBusy){
			var xPopupClass = 'xpopup_slideshow';
			var xPopupTitleClass = 'xpopupImgTitle_slideshow';
			if (! this.isIE() && this.isFixedPosition()) xPopupClass = 'xpopup_slideshow_fixed';
		}else{
			var xPopupClass = 'xpopup';
			var xPopupTitleClass = 'xpopupImgTitle';
			if (! this.isIE() && this.isFixedPosition()) xPopupClass = 'xpopup_fixed';
		}
		$('#xpopup').attr({'class': xPopupClass});
		if($('#xpopupImgTitle').size() > 0) $('#xpopupImgTitle').attr({'class': xPopupTitleClass});
	}

	ImageXPopup.prototype.hideBodyScrollbars = function(){
		$('body').css({'overflow': 'hidden'});
	}
	
	ImageXPopup.prototype.handleSlideshow = function(e){
		if (this.isButtonActive(e)){
			if (LL_XPopup.slideshowBusy){
				var buttonClass = 'playButton';
				LL_XPopup.slideshowBusy = 0;
				clearTimeout(LL_XPopup.slideshowInterval);
			}else{
				var buttonClass = 'pauseButton';
				LL_XPopup.slideshowBusy = 1;
				var self = this;
				LL_XPopup.slideshowInterval = setTimeout(function(){self.changeImage(1, 'slideshow')}, 7000);
			}
			this.updateButton('xpopupHoverMenuPlayPauseButton', 'act', buttonClass);
		}
	}
	
	ImageXPopup.prototype.handleGalleryImgClick = function(idx, e){
		e.preventDefault();
		e.stopPropagation();
		var self = this;
		$('#xpopupGalleryOverview').fadeOut('fast', function(){$('#xpopupGalleryOverview').remove()});
		this.changeImage(idx, 'gallery');
	}
	
	ImageXPopup.prototype.handleGalleryOverview = function(e){
		if (LL_XPopup.slideshowBusy) this.handleSlideshow({'target': $('#xpopupHoverMenuPlayPauseButton').get(0)});
		$('#xpopup').hide();
		var images = this.getOverviewImagesWithDeco();
		var vpDims = {'w': $(window).width(), 'h': $(window).height()};
		var vpPos = {'x': $(document).scrollLeft(), 'y': $(document).scrollTop()}
		var px = null;
		var py = null;
		var h = vpDims.h;
		var w = vpDims.w;
		var position = 'fixed';
		if (this.isIE()){
			px = vpPos.x;
			py = vpPos.y;
			var position = 'absolute';
		}
		var container = $('<div>').attr(
			{'id': 'xpopupGalleryOverview', 'class': 'xpopupGalleryOverview'}
		).css(
		{'height': '100%', 'width': '100%', 'position': position, 'left': px, 'top': py}
		).click(
			function(e){LL_XPopup.destruct(e)}
		);
		for (var i = 0; i < images.length; ++i){
			container.append(images[i]);
		}
		$('body').append(container);
		$('#xpopupGalleryOverview').fadeIn('fast');
	}

	ImageXPopup.prototype.getOverviewImagesWithDeco = function(){
		var pg = LL_XPopup.preparedGallery;
		var images = [];
		var mw= 135;
		var mh = 90;
		for (var i = 0; i < pg.length; ++i){
			function x(self, idx){
				var srcImg = pg[idx].getSrcImage();
				var paddingTop = '0';
				if (srcImg.height < mh) paddingTop = parseInt((mh - srcImg.height) / 2) + 'px';
				var img = self.makeImage(srcImg.src, {'width': srcImg.width, 'height': srcImg.height, 'border': 0, 'alt': srcImg.alt, 'title': srcImg.title});
				var img = self.resizeImgOnOverflow(img, mh, mw);
				var imgWrapped = $('<span></span>').append(img).css({'padding-top': paddingTop});
				images.push(
					$('<div>').append(
						$('<a></a>').append(
							$('<span></span>').append(imgWrapped).attr({'class': 'image'})
						).attr({'class': 'inner1', 'href': '#'})
					).attr({'class': 'xpopupGalleryImageDeco'}).click(
						function(e){self.handleGalleryImgClick(idx, e)}
					).get(0)
				);
				return images;
			}
			images = x(this, i);
		}
		return images;
	}


	// Webpage xpopup
	WebpageXPopup = function(src, event, spos, ppos, margin_w, margin_h, TypeAttrs){
		/* TypeAttrs: url, href, jsFunc, height, width, background
		 * url: Source of the image to display.
		 * height: Popup height.
		 * width: Popup width.
		 * background: The xpopup stay on a dark background
		 * fixedPosition: The popup is position fixed and has no response on scroll events.
		 */
		this.constructor(src, event, spos, ppos, margin_w, margin_h, TypeAttrs);
	}
	WebpageXPopup.prototype = new DefaultXPopup();

	WebpageXPopup.prototype.getContent = function(){
		this.setPopupWidth();
		var height = parseInt($(window).height() / 1.5);
		var width = parseInt($(window).width() / 1.5);
		var url = 'http://www.example.com';
		if (this.Attrs){
			height = this.Attrs.height == 'auto'? height : this.Attrs.height;
			width = this.Attrs.width == 'auto'? width : this.Attrs.width;
			url = this.Attrs.url ? this.Attrs.url : url;
			if (this.Attrs.background){
				if (this.Attrs.background.toLowerCase() == 'true' || this.Attrs.background == 1) this.makeBackground();
			}
		}
		return $('<iframe>').attr({'src': url, 'frameborder': 0, 'height': height, 'width': width}).get(0);
	}

	// Ajax xpopup
	AjaxXPopup = function(src, event, spos, ppos, margin_w, margin_h, TypeAttrs){
		/* TypeAttrs: url, href, jsFunc, height, width, background
		 * url: Source of the image to display.
		 * height: Popup height.
		 * width: Popup width.
		 * background: The popup stay on a dark background
		 * fixedPosition: The popup is position fixed and has no response on scroll events.
		 */
		this.constructor(src, event, spos, ppos, margin_w, margin_h, TypeAttrs);
		this.def = null;
	}
	AjaxXPopup.prototype = new DefaultXPopup();

	AjaxXPopup.prototype.getContent = function(){
		this.setPopupWidth();
		var height = parseInt($(window).height() / 3);
		var width = parseInt($(window).width() / 2);
		var url = '/';
		if (this.Attrs){
			height = this.Attrs.height == 'auto'? height : this.Attrs.height + 'px';
			width = this.Attrs.width == 'auto'? width : this.Attrs.width + 'px';
			url = this.Attrs.url ? this.Attrs.url : url;
			if (this.Attrs.background){
				if (this.Attrs.background.toLowerCase() == 'true' || this.Attrs.background == 1) this.makeBackground();
			}
		}
		var container = $('<div>').css({ 'height': height, 'width': width, 'overflow': 'auto'}).load(url);
		return container.get(0);
	}
	
	AjaxXPopup.prototype.loadContent = function(container, def){
		container.innerHTML = def.responseText;
	}

	AjaxXPopup.prototype.loadContentError = function(def){
		console.log('Fehler beim Abruf von AJAX content:', def.message);
	}
/* << */


/* >> tabbed elements (requires jQuery 1.2.6) Version: rel-1-0-0 */
	TabbedElements = {
		tabGroups: [],
		tabsCont: null,
		tabsOuter: null,
		register: function(tabEl, activeId){
			this.tabsCont = $('#' + tabEl).get(0);
			var tOut = this.tabsOuter = this.tabsCont.parentNode;
			tOutChilds = this._getTabContainerChildNodes('div', tOut);
			var titlesOuter = this._getTabContainerElementsTitleShells(tOutChilds);
			var grp = {'id': tabEl, 'tabs': [], 'elements': [], 'hereId': -1};
			for (var i = 1; i < tOutChilds.length -1; ++i){
				grp.tabs.push(this._getTab(this._getTabTitleAndDeleteShell(titlesOuter[i -1]), this.tabGroups.length, i -1));
				grp.elements.push(tOutChilds[i]);
			}
			this.tabGroups.push(grp);
			var actGrpId = this.tabGroups.length -1;
			this._fillTabsElement(actGrpId);
			this._prepareParagraphShells(actGrpId);
			this.show(actGrpId, activeId);
		},
		_getTabGroupId: function(id){
			if (! isNaN(id)){
				return id;
			}else{
				for (var i = 0; i < this.tabGroups.length; ++i){
					var strId = this.tabGroups[i].id.substring(this.tabGroups[i].id.indexOf('_') + 1, this.tabGroups[i].id.length).toLowerCase();
					if (strId == id.toLowerCase()) return i;
				}
			}
			return false;
		},
		_getTabTitleAndDeleteShell: function(titleEl){
			t = titleEl.getElementsByTagName('h3')[0];
			$(titleEl).remove();
			return t.innerHTML;
		},
		_getTabContainerChildNodes: function(elmName, parent){
			var nList = [];
			for (var i = 0; i < parent.childNodes.length; ++i){
				var n = parent.childNodes[i];
				if (n.nodeType == 1 && n.nodeName.toLowerCase == elmName.toLowerCase){
					nList.push(n);
				}
			}
			return nList;
		},
		_getFirstMatchChildNode: function(node, tag, nodeType){
			if (! nodeType) var nodeType = 1;
			for (var i = 0; i < node.childNodes.length; ++i){
				if (node.childNodes[i].nodeType == nodeType){
					if (tag && node.childNodes[i].nodeName.toLowerCase == tag.toLowerCase){
						return node.childNodes[i];
					}
					if (! tag) return node.childNodes[i];
				}
			}
			return false;
		},
		_getTabContainerElementsTitleShells: function(contentElms){
			var tList = [];
			var prevNode;
			for (var i = 1; i < contentElms.length -1; ++i){
				var node = contentElms[i];
				while (this._getFirstMatchChildNode(node, 'div', 1)){
					prevNode = node;
					node = this._getFirstMatchChildNode(node, 'div', 1);
				}
				tList.push(prevNode);
			}
			return tList;
		},
		_getTab: function(title, grpId, tabId){
			var id = 'tab_' + grpId + '_' + tabId;
			var tab = $(
				'<div id="' + id + '" class="tab_passive">' +
					'<div class="inner1">' +
						'<div class="inner2">' +
							'<span>' + title + '</span>' +
						'</div>' +
					'</div>' +
				'</div>'
			).get(0);
			var self = this;
			$(tab.childNodes[0].childNodes[0].childNodes[0]).bind('click', function(e){self.show(grpId, tabId, e)});
			return tab;
		},
		_fillTabsElement: function(grpId){
			var tabs = this.tabGroups[grpId].tabs;
			var outer = $('<div class="outer1"></div>');
			for (var i = 0; i < tabs.length; ++i){
				outer.append($(tabs[i]));
			}
			
			outer.append($('<div></div>').css({'clear': 'both', 'min-height': '1px', 'margin-bottom': '-1px'}));
			$(this.tabsCont).css({'display': 'block'});
			$(this.tabsCont).append(outer);
		},
		_prepareParagraphShells: function(grpId){
			var paras = this.tabGroups[grpId].elements;
			for (var i = 0; i < paras.length; ++i){
				var id = 'tabContent_' + grpId + '_' + i;
				$(paras[i]).css({'display': 'none'});
			}
			
		},
		show: function(grpId, tabId, e){
			var grpId = this._getTabGroupId(grpId);
			var tabId = isNaN(parseInt(tabId)) ? 0 : tabId;
			if (tabId > this.tabGroups[grpId].tabs.length -1 || tabId < 0) tabId = 0;
			var tabs = this.tabGroups[grpId].tabs;
			var elements = this.tabGroups[grpId].elements;
			var hereId = this.tabGroups[grpId].hereId;
			if (hereId > -1){
				$(tabs[hereId]).attr('class', 'tab_passive');
				$(elements[hereId]).css({'display': 'none'});
			}
			$(tabs[tabId]).attr('class', 'tab_active');
			$(elements[tabId]).css({'display': 'block'});
			this.tabGroups[grpId].hereId = tabId;
		}
	}
/* << */


/* >> Calendar control (requires jQuery 1.2.6+ and scrollTo plugin). Version: rel-1-0-0 */
	// The script supports horizontal and vertical scrolling in the future!
	function CalendarControl(mode){
		this.months = [];
		this.scrollToDef = null;
		this.mode = this.getMode(mode); // horizontal or vertical
		this.currScrollPos = 0;
		this.scrollPane = $('#calendarHorizontalScrollPane');
		this.mBoxName = 'calendarMonthContainer_'; // month container id snippet
		this.ctrlBoxName = '#horizontalScrollControls' // holds the calendar controlls (left and right arrow)
		// @controls:
		// 'key': [element, event, binding, attributes, connection id]
		this.controlsHorz = {
			'l': [$('#scrollLeft'), 'click', 'scroll', -1],
			'r': [$('#scrollRight'), 'click', 'scroll', 1]
		};
		this.scrollStep = 2; // how many months to scroll with one click
	}
	
	CalendarControl.prototype.init = function(args){
		this.handleLayout();
		this.detectMonths();
		if (args.current > 0){
			if (args.current % this.scrollStep > 0){
				this.currScrollPos = Math.floor(args.current / this.scrollStep) * this.scrollStep;
			}else{
				this.currScrollPos = args.current - this.scrollStep;
			}
			var mode = this.mode > 1 ? 'y': 'x';
			this.scrollPane.scrollTo(this.months[this.currScrollPos].monthElement, 600, {'axis': mode, 'offset': {'left': -35, 'top': 0}});
		}
		this.handleControls();
	}
	
	CalendarControl.prototype.handleControls = function(){
		var c = this.controlsHorz;
		var status = {
			'l': this.currScrollPos > 0 ? 1 : null,
			'r': this.currScrollPos + this.scrollStep < this.months.length ? 1 : null
		};
		for (var i in c){
			var ctrl = c[i];
			ctrl[0].unbind().removeClass('act').addClass('pass');
			if (status[i]){
				var self = this;
				(function(m){
					ctrl[0].bind(ctrl[1], function(e){
						e.preventDefault();
						self[ctrl[2]](m);
					});
				})(ctrl[3]);
				ctrl[0].removeClass('pass').addClass('act');
			}
		}
	}
	
	CalendarControl.prototype.handleLayout = function(){
		$(this.ctrlBoxName).show();
		this.scrollPane.css({'overflow': 'hidden'});
	}
	
	CalendarControl.prototype.detectMonths = function(){
		for (var count = 0;;){
			var month = $('#' + this.mBoxName + count++);
			if (month.size() == 0) break;
			this.months.push(new CalendarMonth(month));
		}
	}
	
	CalendarControl.prototype.scroll = function(direction){
		var nextPos = this.currScrollPos + direction * this.scrollStep;
		if (nextPos >= 0 && nextPos <= this.months.length){
			var mode = this.mode > 1 ? 'y': 'x';
			this.scrollPane.scrollTo(this.months[nextPos].monthElement, 600, {'axis': mode, 'offset': {'left': -35, 'top': 0}});
			this.currScrollPos = nextPos;
		}
		this.handleControls();
	}

	CalendarControl.prototype.getMonthDims = function(){
		return {'w': this.months[0].monthElement.width(), 'h': this.months[0].monthElement.height()};
	}
	
	CalendarControl.prototype.getMode = function(mode){
		mode = (String(mode)).toLowerCase;
		if (mode == 'h'){
			return 1;
		}else if (mode == 'v'){
			return 2
		}
		return 1;
	}


	function CalendarMonth(monthElement){
		this.monthElement = monthElement;
		this.name = this.getName();
		this.here = null;
	}
	
	CalendarMonth.prototype.getName = function(){
		return null;
	}
/* << */


/* >> LL_ImageWidthTest (requires jQuery) Version: rel-1-0-0 */
	LL_ImageWidthTest = {
		images:  null, //Bildbereiche Absatz
		teaserImages: null, //Bildbereiche Teaser
		contentTableWidth: null, //Breiten der Bereiche fuer abschliessenden Test
		contentWidth: null, //Breiten der Bereiche content-Spalte fuer Panels
		twoColWidth: null, //Breiten der Bereiche zweispaltiger Bereich
		multiColWidth: null, //Breiten der Bereiche mehrspaltiger Bereich
		leftColWidth: null, //Breiten der Bereiche Teaser links
		rightColWidth: null, //Breiten der Bereiche Teaser rechts
		fixTextWidth: 110, //Breiten für Texte bei "links/rechts feste Breite" Absätze
		fixTeaserTextWidth: 80, //Breiten für Texte bei "links/rechts feste Breite" Teaser
		summary: [
			['Teaser links', 'teaserL'],
			['Teaser rechts', 'teaserR'],
			['Absätze einzeln', 'paras'],
			['Absätze 2spaltig', 'paras2C'],
			['Absätze 3spaltig', 'paras3C']
		],
		init: function(){
			$('img.imgWidthPx').css('background-color', 'blue');
			this.images = $('div.paraImgInner img');
			this.teaserImages = $('div.teaserImgInner img');
			this.contentTableWidth = $('table.contentMainTable').width();
			this.contentWidth = $('div.contSpcShellStd').width();
			this.twoColWidth = $('table.twoColElShell').width();
			this.multiColWidth = $('div.multipleColumnShellOuter').width();
			this.leftColWidth = $('td.leftBorderCol div.lElCont').width();
			this.rightColWidth = $('td.rightBorderCol div.rElCont').width();
			this.newImageWidth();
		},
		getSummary: function(){
			$('div.contSpcShellStd').prepend('<div id="testSummary"></div>');
			$('#testSummary').append(
				'<div style="margin-bottom: 5px;">(Mindestbreite für Texte bei &quot;link/rechts fest&quot;: ' +
					'<span>Teaser:&nbsp;</span><span>' + this.fixTeaserTextWidth + 'px, &nbsp;</span>' +
					'<span>Text:&nbsp;</span><span>' + this.fixTextWidth + 'px</span>' +
				')</div>' +
				'<h2>Ermittelte max. Breiten:</h2>'
			);
			for (var i = 0; i < this.summary.length; ++i) {
				$('#testSummary').append(
					'<div id="' + this.summary[i][1] + '"><h3>' + this.summary[i][0] + '</h3></div>'
				);
			}
		},
		printSize: function(shell, title, imageWidthNew){
			$('#' + shell).append('<div><span class="title">' + title + ':</span>&nbsp;&nbsp;<span class="width">' + imageWidthNew + 'px</span></div>');
			$('#' + shell).css({'-moz-border-radius': '15px', '-webkit-border-radius': '15px', 'border': '1px solid #666', 'padding': '10px', 'margin-bottom': '10px'})
		},
		filterOffset: function(offset){
			offset = parseInt(offset);
			if (isNaN(offset)){
				offset = 0;
			}
			return offset
		},
		getOffsets: function(image, target, dist){
			var parent = image.parent();
			var title = "";
			while (parent.parent(target).length == 0){
				dist = dist +
					this.filterOffset(parent.css("padding-left")) +
					this.filterOffset(parent.css("padding-right")) +
					this.filterOffset(parent.css("margin-left")) +
					this.filterOffset(parent.css("margin-right")) +
					this.filterOffset(parent.css("border-left-width")) +
					this.filterOffset(parent.css("border-right-width"));
				if (parent.parent().prev('h3').size() > 0) {
					title = parent.parent().prev('h3').text();
				}
				else if (parent.parent('div.paraCeTopImgOuter').next('h3').size() > 0) {
					title = parent.parent('div.paraCeTopImgOuter').next('h3').text();
				}
				else if (parent.siblings("div[class$='Title']").find('h3').size() > 0) {
					title = parent.siblings("div[class$='Title']").find('h3').text();
				}
				else if (parent.siblings("div[class^='title']").find('h3').size() > 0) {
					title = parent.siblings("div[class^='title']").find('h3').text();
				}
				
				parent = parent.parent();
			}
			return [dist, title]
		},
		newImageWidth: function(){
			this.getSummary();
			var self = this;
			this.images.each(function(i){
				var image = $(this);
				var dist = 0;
				var title = '';
				var imageWidthNew = parseInt(image.attr('width'));
				var result = [];
				var shell = null;
				
				// paragraphs, panels, desPanels normal
				if ((image.parents('table.twoColElShell').length == 0) && (image.parents('div.multipleColumnShellOuter').length == 0)){
					result = self.getOffsets(image, 'td.contentColumn', dist);
					dist = result[0];
					title = result[1];
					imageWidthNew = (self.contentWidth - dist);
					shell = self.summary[2][1];
				}
				// paragraphs, panels, desPanels 2spaltig
				else if (image.parents('table.twoColElShell').length > 0){
					result = self.getOffsets(image, 'table.twoColElShell', dist);
					dist = result[0];
					title = result[1];
					var twoColSpc = parseInt(image.parents('table.twoColElShell').find('td.middleSpc img').css('width'));
					imageWidthNew = (Math.floor((self.twoColWidth / 2)) - twoColSpc - dist);
					shell = self.summary[3][1];
				}
				// paragraphs, panels, desPanels 3spaltig
				else if (image.parents('div.multipleColumnShellOuter').length > 0){
					result = self.getOffsets(image, 'div.multipleColumnShellOuter', dist);
					dist = result[0];
					title = result[1];
					var multiColSpc = parseInt(image.parents('div.multipleColumnShellOuter').find('td.colSpacer img').css('width'));
					imageWidthNew = (Math.floor((self.multiColWidth / 3)) - (2*multiColSpc) - dist);
					shell = self.summary[4][1];
				}
				// links/rechts feste Breite
				if (image.parents('div.paraFxImgOuter').length > 0){
					imageWidthNew = imageWidthNew - self.fixTextWidth;
					image.parents('div.paraFxImgOuter').siblings('div.paraContOuterL').css('margin-left', ("" + imageWidthNew));
					image.parents('div.paraFxImgOuter').siblings('div.paraContOuterR').css('margin-right', ("" + imageWidthNew));
				}
				// umgebendes div vergroessern und neue Bildbreite setzen
				image.parents('div.paraImgInner').css('width', imageWidthNew);
				image.attr('width', imageWidthNew);
				self.printSize(shell, title, imageWidthNew)
			})
			
			this.teaserImages.each(function(i){
				var image = $(this);
				var dist = 0;
				var title = '';
				var imageWidthNew = parseInt(image.attr('width'));
				var result = [];
				var shell = null;
				
				if (image.parents('div.lElCont').length > 0){
					result = self.getOffsets(image, 'div.lElCont', dist);
					dist = result[0];
					title = result[1];
					imageWidthNew = (self.leftColWidth - dist);
					shell = self.summary[0][1];
				}
				else{
					result = self.getOffsets(image, 'div.rElCont', dist);
					dist = result[0];
					title = result[1];
					imageWidthNew = (self.rightColWidth - dist);
					shell = self.summary[1][1];
				}
				// links/rechts feste Breite
				if (image.parents('div.teaserFxImgOuter').length > 0){
					imageWidthNew = imageWidthNew - self.fixTeaserTextWidth;
					image.parents('div.teaserFxImgOuter').siblings('div.teaserContOuterL').css('margin-left', ("" + imageWidthNew));
					image.parents('divteaserFxImgOuter').siblings('div.teaserContOuterR').css('margin-right', ("" + imageWidthNew));
				}
				// umgebendes div vergroessern und neue Bildbreite setzen
				image.parents('div.teaserImgInner').css('width', imageWidthNew);
				image.attr('width', imageWidthNew);
				self.printSize(shell, title, imageWidthNew);
			})
			
			if ($.browser.safari){
				$('#testSummary').prepend('<div class="alert">SAFARI: Keine korrekten Werte f&uuml;r zentrierte Bilder!</div>');
				$('#testSummary div.alert').css({'color': 'red', 'font-size': '13px', 'font-weight': 'bold', 'padding-bottom': '10px'});
				$('#testSummary span:contains("center")').css({'color': 'red', 'text-decoration': 'line-through'});
				$('#testSummary span:contains("center")').next('span').css({'color': 'red', 'text-decoration': 'line-through'});
			}
			
			if ((this.contentTableWidth - $('table.contentMainTable').width()) < 0){
				alert("" + this.contentTableWidth - $('table.contentMainTable').width() + "px zu breit")
			}
		}
	}
/* << */


/* >> LivingLogic jsPager (requires jQuery 1.2.6 +) */
	JsPager = $.extend(
		$.clone(LLObject),
		{
			create: function(options){
				var o = LLObject.create.call(this);
				o.items = [];
				o.groupCnt = -1;
				o.pos = 0;
				o.data = null;
				o.countPerLine = 1;
				o.slideInterval = 0;
				o.interval = null;
				o.defaults = {
					target: null
				};
				if (options) $.extend(o.defaults, options);
				for (var k in o.defaults) o[k] = o.defaults[k];
				o.prepareContentArea();
				return o;
			},
			slide: function(pos){
				this.pos += pos;
				if (this.pos < 0){
					this.pos = 0;
				}else if (this.pos > this.groupCnt){
					if (this.interval){
						this.pos = 0;
					}else{
						this.pos = this.groupCnt;
					}
				}
				$(this.target).find('div.jsArea').scrollTo(this.props.width * this.pos, this.props.duration, {'axis': 'x'});
			},
			prepareContentArea: function(){
				var t = this.target;
				t.css({'overflow': 'auto'});
				var w = this.props.width;
				var h = this.props.height;
				var content = t.find('div.jsArea');
				content.css({
					'width': w,
					'height': h,
					'overflow': 'hidden'
				});
			},
			makeContentAreaItems: function(){
				var self = this;
				var t = self.target;
				var prefix = t.attr('id');
				var d = this.target.find('div.jsPagerItem');
				var grpShell = null;
				
				if (d && typeof d.length == 'number'){
					var groups = 1;
					if (d.length / self.countPerLine >= 1){
						groups = d.length / self.countPerLine;
						if (groups % 1 > 0) groups++;
					}
					var scrollPaneWidth = self.props.width * groups;
					var scrollPane = $('<div class="ms_scrollPane ms_scrollPane_' + prefix + '"></div>');
					scrollPane.css({'width': scrollPaneWidth, 'height': self.props.height});
					if (groups > 1){
						if (this.props.slideInterval && this.props.slideInterval > 0){
							var slideInterval = this.props.slideInterval;
						}else{
							var slideInterval = 0;
						}
						if (slideInterval == 0){
							t.find('.prev').bind('click', function(e){self.slide(-1)}).css({'cursor': 'pointer'}).end()
								.find('.next').css({'cursor': 'pointer'}).bind('click', function(e){self.slide(1)});
							t.find('div.jsPagerButtons').hover(
								function(){$(this).addClass('jspb_hover');},
								function(){$(this).removeClass('jspb_hover')}
							);
						}else{
							var iterval = slideInterval;
							t.find('table.jsPagerOuterTable td.button').hide();
							this.interval = setInterval(function(){self.slide(1)}, slideInterval);
						}
					}
					$(d).each(function(i){
						if (i % self.countPerLine == 0){
							self.groupCnt++;
							var hwAttrs = {'width': self.props.width, 'height': self.props.height};
							grpShell = $('<div id="ms_grpShell_' + prefix + '_' + self.groupCnt + '" class="ms_grpShell"></div>');
							grpShell.css(hwAttrs);
							var table = $('<table class="jsPagerContentTable" cellpadding="0" cellspacing="0" border="0"><tr></tr></table>');
							table.css(hwAttrs);
							grpShell.append(table);
						}
						var item = JsPagerItem.create(i, this, self);
						self.items.push(item);
						item = item.make();
						grpShell.find('table tr').append(item);
						scrollPane.append(grpShell);
					});
					t.find('.jsArea').append(scrollPane);
				}
				t.find('div.jsPagerItem').empty();
			}
		}
	);

	JsPagerItem = $.extend(
		$.clone(LLObject),
		{
			create: function(id, data, JsPager){
				var o = LLObject.create.call(this);
				o.slider = JsPager || null;
				o.id = id;
				o.data = data || null;
				o.itemWidth = JsPager.defaults.props.itemWidth || null;
				return o;
			},
			make: function(){
				var sliderId = this.slider.target.attr('id');
				var item = $(
					'<td>' + $(this.data).html() + '</td>'
				);
				item.css({'vertical-align': 'top', 'text-align': 'center'});
				return item;
			}
		}
	);
/* << */


/* >> Media player element (requires jQuery 1.2.6 +) Version: rel-1-0-0 */
	MediaPlayerSystem = $.extend(
		$.clone(LLObject),
		{
			create: function(opts){
				var o = LLObject.create.call(this);
				o.mode = opts.mode;
				o.target = opts.target;
				o.width = opts.width;
				o.height = opts.height;
				o.expertData = opts.expertData;
				o.filePath = opts.filePath;
				o.previewFilePath = opts.previewFilePath;
				return o;
			},
			make: function(){
				if (swfobject){
					var w = this.width;
					var h = this.height;
					var flashvars = {
						file: this.filePath
					};
					if (this.mode && this.mode != '') flashvars = $.extend(flashvars, {'type': this.mode});
					if (this.expertData){
						var realExpData = {};
						for (var k in this.expertData){
							if (k != 'width' && k != 'height'){
								realExpData[k] = this.expertData[k];
							}else if(k == 'width'){
								w = this.expertData[k];
							}else if(k == 'height'){
								h = this.expertData[k];
							}
						}
						flashvars = $.extend(flashvars, realExpData);
					}
					if (this.previewFilePath){
						flashvars = $.extend(flashvars, {'image': this.previewFilePath});
					}
					var params = {'allowfullscreen': true};
					var attributes = {};
					var playerurl = '/xist4c/web/mediaplayer/player-licensed.swf'
					
					//static test case
					if (window.location.href.search('/xist4c/xist4c') != -1)
						playerurl = '../web/mediaplayer/player-licensed.swf'
					
					swfobject.embedSWF(playerurl, this.target, w, h, "9.0.0",null, flashvars, params, attributes);
				}
			}
		}
	);
/* << */

