// Generated: Tue Jul 14 15:31:46 2009


// ##########################
// File: /storage/www/yur/www/lib/admin.js
// ##########################
function MM_preloadImages() { //v3.0
  var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array();
    var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0; i<a.length; i++)
    if (a[i].indexOf("#")!=0){ d.MM_p[j]=new Image; d.MM_p[j++].src=a[i];}}
}

function MM_swapImgRestore() { //v3.0
  var i,x,a=document.MM_sr; for(i=0;a&&i<a.length&&(x=a[i])&&x.oSrc;i++) x.src=x.oSrc;
}

function MM_findObj(n, d) { //v4.01
  var p,i,x;  if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) {
    d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}
  if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n];
  for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document);
  if(!x && d.getElementById) x=d.getElementById(n); return x;
}

function MM_swapImage() { //v3.0
  var i,j=0,x,a=MM_swapImage.arguments; document.MM_sr=new Array; for(i=0;i<(a.length-2);i+=3)
   if ((x=MM_findObj(a[i]))!=null){document.MM_sr[j++]=x; if(!x.oSrc) x.oSrc=x.src; x.src=a[i+2];}
}


function ele(id) {
	return document.getElementById(id)
}

function showNewMessage() {
	ele("newMessageLayer").style.display="inline"
	ele("headline").focus()
}

function hideNewMessage() {
	if (ele("newMessageLayer")) ele("newMessageLayer").style.display="none"
}

function showPersonSearch() {
	ele("personSearchLayer").style.display="inline"
	ele("alias").focus()
	hideNewMessage()
}

function showShare() {
	ele("ShareDateLayer").style.display="inline"
	hideNewMessage()
}

function hidePersonSearch() {
	ele("searchResult").style.display="none"
	ele("personSearchLayer").style.display="none"
}

function hideShareDate() {
	ele("ShareDateLayer").style.display="none"
}

function showPersonResult() {
	ele("searchResult").style.display="inline"
}

function doSearch() {
	ele("searchForm").submit()
	showPersonResult()
}

function init() {
	Admin_initPersonLink()
}

function abort_action(){
	document.location.href="./?action=intro";
}

function initMenu() {
	var eles = document.getElementsByClassName("collabsable");
	
	for(var i in eles) {
		var ele = eles[i];
		
	
		ele.onclick= function () {
			var style;
			var next = this.nextSibling
			if(next.style != null) {
				style = next.style
			} else {
				style = next.nextSibling.style
			}
			
			if(style.display == "block") {
				style.display = "none"
			} else {
				style.display = "block"
			}
		}
		
	}
}

var personLoading = false;

function Admin_initPersonLink() {
	var eles = document.getElementsByClassName("person");
	
	for(var i in eles) {
		var ele = eles[i];
		
		__Admin_initPersonLink(ele)
	}
}

function __Admin_initPersonLink(ele) {
	var person_id = ele.innerHTML;
	
	if(person_id == null) {
		return
	}
	
	ele.onclick = function () {
		window.open("./?action=show_person&person_id=" + person_id);
	}
}

function click_action(obj) {
	obj.disabled = true;
	obj.value    = "wird gemacht"
}

function getSelectedRadio(buttonGroup) {
	if (buttonGroup[0]) { // if the button group is an array (one button is not an array)
      for (var i=0; i<buttonGroup.length; i++) {
         if (buttonGroup[i].checked) {
            return i
         }
      }
   } else {
      if (buttonGroup.checked) { return 0; } // if the one button is checked, return zero
   }
   
   // if we get to this point, no radio button is selected
   return -1;
}

function getSelectedRadioValue(buttonGroup) {
	var i = getSelectedRadio(buttonGroup);
	if (i == -1) {
      return "";
	} else {
      if (buttonGroup[i]) { // Make sure the button group is an array (not just one button)
         return buttonGroup[i].value;
      } else { // The button group is just the one button, and it is checked
         return buttonGroup.value;
      }
	}
}

function noop(){}

// ##########################
// File: /storage/www/yur/www/lib/builtin_class_extensions.js
// ##########################
Object.prototype.yurAddEvent = function(event, func) {	
	
	var event_array = "yur_"+event+"_steps";
	
	if(this[event] == null || this[event_array] == null) {
		this[event_array] = []
		this[event] = function () {
			var args   = arguments
			var events = this[event_array];
			for(var i = 0; i < events.length; i++) {
				events[i].apply(this,args)
			}
		}
	}
	
	this[event_array].push(func)
}

var __yurAccessorMaker =  function (target,name) {
	var instance_var_name = "_"+name
	target[name] = function () {
		if(arguments.length > 0) {
				this[instance_var_name] = arguments[0] 
		}
		return this[instance_var_name]
	}
}

Object.prototype.yurMakeAccessors = function () {
	for(var i = 0; i < arguments.length; i++) {
		__yurAccessorMaker(this, arguments[i])
	}
}

Date.prototype.getTimeSeconds = function () {
	return Math.round(this.getTime() / 1000);
}


document.getFlashMovieById = function (id) {
    if (document.all) {
        return window[id]
    }
    else {
        return document[id]
    }

}
// ##########################
// File: /storage/www/yur/www/lib/Jemplate.js
// ##########################
// MALTE: CHANGED, Do not Update
/*------------------------------------------------------------------------------
Jemplate - Template Toolkit for Javascript

DESCRIPTION - This module provides the runtime Javascript support for
compiled Jemplate templates.

AUTHOR - Ingy dÃ¶t Net <ingy@cpan.org>

Copyright 2006 Ingy dÃ¶t Net. All Rights Reserved.

This module is free software; you can redistribute it and/or
modify it under the same terms as Perl itself.
------------------------------------------------------------------------------*/

//------------------------------------------------------------------------------
// Main Jemplate class
//------------------------------------------------------------------------------
if (typeof Jemplate == 'undefined')
    Jemplate = function() {};

Jemplate.templateMap = {};

Jemplate.process = function(template, data, output) {
    var context = new Jemplate.Context();
    context.stash = new Jemplate.Stash();
    context._filter = new Jemplate.Filter();
    var result;

    var proc = function(input) {
        try { 
            result = context.process(template, input);
        }
        catch(e) {
            if (! String(e).match(/Jemplate\.STOP\n/))
                throw(e);
            result = e.toString().replace(/Jemplate\.STOP\n/, '')
        }

        if (typeof output == 'undefined')
            return result;
        if (typeof output == 'function') {
            output(result);
            return;
        }
        if (typeof(output) == 'string' || output instanceof String) {
            if (output.match(/^#[\w\-]+$/)) {
                var id = output.replace(/^#/, '');
                var element = document.getElementById(id);
                if (typeof element == 'undefined')
                    throw('No element found with id="' + id + '"');
                element.innerHTML = result;
                return;
            }
        }
        else {
            output.innerHTML = result;
            return;
        }

        throw("Invalid arguments in call to Jemplate.process");

        return 1;
    }

    if (typeof data == 'function')
        data = data();
    else if (typeof data == 'string') {
        Ajax.get(data, function(r) { proc(JSON.parse(r)) });
        return;
    }

    return proc(data);
}

//------------------------------------------------------------------------------
// Jemplate.Context class
//------------------------------------------------------------------------------
if (typeof Jemplate.Context == 'undefined')
    Jemplate.Context = function() {};

proto = Jemplate.Context.prototype;

proto.include = function(template, args) {
    return this.process(template, args, true);
}

proto.process = function(template, args, localise) {
    if (localise)
        this.stash.clone(args);
    else
        this.stash.update(args);
    var func = Jemplate.templateMap[template];
    if (typeof func == 'undefined')
        throw('No Jemplate template named "' + template + '" available');
    var output = func(this);
    if (localise)
        this.stash.declone();
    return output;
}

proto.set_error = function(error, output) {
    this._error = [error, output];
    return error;
}

proto.filter = function(text, name, args) {
    if (name == 'null') 
        name = "null_filter";
    if (typeof this._filter.filters[name] == "function")
        return this._filter.filters[name](text, args, this);  
    else 
        throw "Unknown filter name ':" + name + "'";
}

//------------------------------------------------------------------------------
// Jemplate.Filter class
//------------------------------------------------------------------------------
if (typeof Jemplate.Filter == 'undefined') {
    Jemplate.Filter = function() { };
}

proto = Jemplate.Filter.prototype;

proto.filters = {};

proto.filters.null_filter = function(text) {
    return ''; 
}

proto.filters.upper = function(text) {
    return text.toUpperCase();
}

proto.filters.lower = function(text) {
    return text.toLowerCase();
}

proto.filters.ucfirst = function(text) {
    var first = text.charAt(0);
    var rest = text.substr(1);
    return first.toUpperCase() + rest;
}

proto.filters.lcfirst = function(text) {
    var first = text.charAt(0);
    var rest = text.substr(1);
    return first.toLowerCase() + rest;
}

proto.filters.trim = function(text) {
    return text.replace( /^\s+/g, "" ).replace( /\s+$/g, "" );
}

proto.filters.collapse = function(text) {
    return text.replace( /^\s+/g, "" ).replace( /\s+$/g, "" ).replace(/\s+/, " ");
}

proto.filters.html = function(text) {
    text = text.replace(/&/g, '&amp;'); 
    text = text.replace(/</g, '&lt;');
    text = text.replace(/>/g, '&gt;');
    text = text.replace(/"/g, '&quot;'); // " end quote for emacs
    return text;
}

proto.filters.html_para = function(text) {
    var lines = text.split(/(?:\r?\n){2,}/);
    return "<p>\n" + lines.join("\n</p>\n\n<p>\n") + "</p>\n";
}

proto.filters.html_break = function(text) {
    return text.replace(/(\r?\n){2,}/g, "$1<br />$1<br />$1");
}

proto.filters.html_line_break = function(text) {
    return text.replace(/(\r?\n)/g, "$1<br />$1");
}

proto.filters.uri = function(text) {
    return encodeURI(text);
}

proto.filters.indent = function(text, args) {
    var pad = args[0];
    if (! text) return;
    if (typeof pad == 'undefined') 
        pad = 4;

    var finalpad = '';
    if (typeof pad == 'number' || String(pad).match(/^\d$/)) {
        for (var i = 0; i < pad; i++) {
            finalpad += ' '; 
        }
    } else {
        finalpad = pad;
    }
    var output = text.replace(/^/gm, finalpad);
    return output;
}

proto.filters.truncate = function(text, args) {
    var len = args[0];
    if (! text) return;
    if (! len) 
        len = 32;
    // This should probably be <=, but TT just uses <
    if (text.length < len)
        return text;
    var newlen = len - 3;
    return text.substr(0,newlen) + '...';
}

proto.filters.repeat = function(text, iter) {
    if (! text) return;
    if (! iter || iter == 0) 
        iter = 1;
    if (iter == 1) return text
    
    var output = text;
    for (var i = 1; i < iter; i++) {
        output += text;
    } 
    return output;
}

proto.filters.replace = function(text, args) {
    if (! text) return;
    var re_search = args[0];
    var text_replace = args[1];
    if (! re_search)
        re_search = '';
    if (! text_replace)
        text_replace = '';
    var re = new RegExp(re_search, 'g');
    return text.replace(re, text_replace);
}

//------------------------------------------------------------------------------
// Jemplate.Stash class
//------------------------------------------------------------------------------
if (typeof Jemplate.Stash == 'undefined') {
    Jemplate.Stash = function() {
        this.data = {};
    };
}

proto = Jemplate.Stash.prototype;

proto.clone = function(args) {
    var data = this.data;
    this.data = {};
    this.update(data);
    this.update(args);
    this.data._PARENT = data;
}

proto.declone = function(args) {
    this.data = this.data._PARENT || this.data;
}

proto.update = function(args) {
    if (typeof args == 'undefined') return;
    for (var key in args) {
        var value = args[key];
        this.set(key, value);
    }
}

proto.get = function(key) {
    var root = this.data;
    if (key instanceof Array) {
        for (var i = 0; i < key.length; i += 2) {
            var args = key.slice(i, i+2);
            args.unshift(root);
            value = this._dotop.apply(this, args);
            if (typeof value == 'undefined')
                break;
            root = value;
    
    }
    }
    else {
        value = this._dotop(root, key);
    }

    return value;
}

proto.set = function(key, value, set_default) {
    if (! (set_default && (typeof this.data[key] != 'undefined')))
        this.data[key] = value;
}

proto._dotop = function(root, item, args) {
    if (typeof item == 'undefined' ||
        typeof item == 'string' && item.match(/^[\._]/)) {
        return undefined;
    }
 

    if ((! args) &&
        (typeof root == 'object') &&
        (!(root instanceof Array) || (typeof item == 'number')) &&
        (typeof root[item] != 'undefined')) {
        var value = root[item];
        if (typeof value == 'function') {
        	// MALTE: Added para root to allow method calls
          	value = value.apply(root);
        }
        return value;
    }

    if (typeof root == 'string' && this.string_functions[item])
        return this.string_functions[item](root, args);
    if (root instanceof Array && this.list_functions[item])
        return this.list_functions[item](root, args);
    if (typeof root == 'object' && this.hash_functions[item])
        return this.hash_functions[item](root, args);
    if (typeof root[item] == 'function') {	
    	// MALTE: Added para root, to allow method calls
        return root[item].apply(root,args);
    }

    return undefined;
}

proto.string_functions = {};

// chunk(size)     negative size chunks from end 
proto.string_functions.chunk = function(string, args) {
    var size = args[0];
    var list = new Array();
    if (! size)
        size = 1;
    if (size < 0) {
        size = 0 - size;
        for (i = string.length - size; i >= 0; i = i - size)
            list.unshift(string.substr(i, size));
        if (string.length % size)
            list.unshift(string.substr(0, string.length % size));
    }
    else
        for (i = 0; i < string.length; i = i + size)
            list.push(string.substr(i, size));
    return list;
}

// defined         is value defined? 
proto.string_functions.defined = function(string) {
    return 1;
}

// hash            treat as single-element hash with key value 
proto.string_functions.hash = function(string) {
    return { 'value': string };
}

// length          length of string representation 
proto.string_functions.length = function(string) {
    return string.length;
}

// list            treat as single-item list 
proto.string_functions.list = function(string) {
    return [ string ];
}

// match(re)       get list of matches
proto.string_functions.match = function(string, args) {
    var regexp = new RegExp(args[0], 'gm');
    var list = string.match(regexp);
    return list;
}

// repeat(n)       repeated n times 
proto.string_functions.repeat = function(string, args) {
    var n = args[0] || 1;
    var output = '';
    for (var i = 0; i < n; i++) {
        output += string;
    }
    return output;
}

// replace(re, sub)    replace instances of re with sub 
proto.string_functions.replace = function(string, args) {
    var regexp = new RegExp(args[0], 'gm');
    var sub = args[1];
    if (! sub)
        sub  = '';
    var output = string.replace(regexp, sub);
    return output;
}

// search(re)      true if value matches re
proto.string_functions.search = function(string, args) {
    var regexp = new RegExp(args[0]);
    return (string.search(regexp) >= 0) ? 1 : 0;
}

// size            returns 1, as if a single-item list 
proto.string_functions.size = function(string) {
    return 1;
}

// split(re)       split string on re 
proto.string_functions.split = function(string, args) {
    var regexp = new RegExp(args[0]);
    var list = string.split(regexp);
    return list;
}



proto.list_functions = {};

proto.list_functions.join = function(list, args) {
    return list.join(args[0]);
};

proto.list_functions.sort = function(list) {
    return list.sort();
}

proto.list_functions.nsort = function(list) {
    return list.sort(function(a, b) { return (a-b) });
}

proto.list_functions.grep = function(list, args) {
    var regexp = new RegExp(args[0]);
    var result = [];
    for (var i = 0; i < list.length; i++) {
        if (list[i].match(regexp))
            result.push(list[i]);
    }
    return result;
}

proto.list_functions.unique = function(list) {
    var result = [];
    var seen = {};
    for (var i = 0; i < list.length; i++) {
        var elem = list[i];
        if (! seen[elem])
            result.push(elem);
        seen[elem] = true;
    }
    return result;
}

proto.list_functions.reverse = function(list) {
    var result = [];
    for (var i = list.length - 1; i >= 0; i--) {
        result.push(list[i]);
    }
    return result;
}

proto.list_functions.merge = function(list, args) {
    var result = [];
    var push_all = function(elem) {
        if (elem instanceof Array) {
            for (var j = 0; j < elem.length; j++) {
                result.push(elem[j]);
            }
        }
        else {
            result.push(elem);
        }
    }
    push_all(list);
    for (var i = 0; i < args.length; i++) {
        push_all(args[i]);
    }
    return result;
}

proto.list_functions.slice = function(list, args) {
    return list.slice(args[0], args[1]);
}

proto.list_functions.splice = function(list, args) {
    if (args.length == 1)
        return list.splice(args[0]);
    if (args.length == 2)
        return list.splice(args[0], args[1]);
    if (args.length == 3)
        return list.splice(args[0], args[1], args[2]);
}

proto.list_functions.push = function(list, args) {
    list.push(args[0]);
    return list;        
}

proto.list_functions.pop = function(list) {
    return list.pop();
}

proto.list_functions.unshift = function(list, args) {
    list.unshift(args[0]);
    return list;        
}

proto.list_functions.shift = function(list) {
    return list.shift();
}

proto.list_functions.first = function(list) {
    return list[0];        
}

proto.list_functions.size = function(list) {
    return list.length;
}

proto.list_functions.max = function(list) {
    return list.length - 1;
}

proto.list_functions.last = function(list) {
    return list.slice(-1);        
}

proto.hash_functions = {};


// each            list of alternating keys/values 
proto.hash_functions.each = function(hash) {
    var list = new Array();
    for ( var key in hash )
        list.push(key, hash[key]);
    return list;
}

// exists(key)     does key exist? 
proto.hash_functions.exists = function(hash, args) {
    return ( typeof( hash[args[0]] ) == "undefined" ) ? 0 : 1;
}

// FIXME proto.hash_functions.import blows everything up
//
// import(hash2)   import contents of hash2 
// import          import into current namespace hash 
//proto.hash_functions.import = function(hash, args) {
//    var hash2 = args[0];
//    for ( var key in hash2 )
//        hash[key] = hash2[key];
//    return '';
//}

// keys            list of keys 
proto.hash_functions.keys = function(hash) {
    var list = new Array();
    for ( var key in hash )
        list.push(key);
    return list;
}

// list            returns alternating key, value 
proto.hash_functions.list = function(hash, args) {
    var what = '';
    if ( args )
        var what = args[0];
        
    var list = new Array();
    if (what == 'keys')
        for ( var key in hash )
            list.push(key);
    else if (what == 'values')
        for ( var key in hash )
            list.push(hash[key]);
    else if (what == 'each')
        for ( var key in hash )
            list.push(key, hash[key]);
    else
        for ( var key in hash )
            list.push({ 'key': key, 'value': hash[key] });

    return list;
}

// nsort           keys sorted numerically 
proto.hash_functions.nsort = function(hash) {
    var list = new Array();
    for (var key in hash)
        list.push(key);
    return list.sort(function(a, b) { return (a-b) });
}

// size            number of pairs 
proto.hash_functions.size = function(hash) {
    var size = 0;
    for (var key in hash)
        size++;
    return size;
}


// sort            keys sorted alphabetically 
proto.hash_functions.sort = function(hash) {
    var list = new Array();
    for (var key in hash)
        list.push(key);
    return list.sort();
}

// values          list of values 
proto.hash_functions.values = function(hash) {
    var list = new Array();
    for ( var key in hash )
        list.push(hash[key]);
    return list;
}



//------------------------------------------------------------------------------
// Jemplate.Iterator class
//------------------------------------------------------------------------------
if (typeof Jemplate.Iterator == 'undefined') {
    Jemplate.Iterator = function(object) {
        if( object instanceof Array ) {
            this.object = object;
        }
        else if ( object instanceof Object ) {
            this.object = object;
            var object_keys = new Array;
            for( var key in object ) {
                object_keys[object_keys.length] = key;
            }
            this.object_keys = object_keys.sort();
        }
    }
}

proto = Jemplate.Iterator.prototype;

proto.get_first = function() {
    this.index = 0;
    return this.get_next();
}

proto.get_next = function() {
    var object = this.object;
    var index = this.index++;
    if (typeof object == 'undefined')
        throw('No object to iterate');
    if( this.object_keys ) {
        if (index < this.object_keys.length)
            return [this.object_keys[index], false];
    } else {
        if (index < object.length)
            return [object[index], false];
    }
    return [null, true];
}

//------------------------------------------------------------------------------
// Debugging Support
//------------------------------------------------------------------------------

function XXX(msg) {
    if (! confirm(msg))
        throw("terminated...");
}

function JJJ(obj) {
    XXX(JSON.stringify(obj));
}

//------------------------------------------------------------------------------
// Ajax support
//------------------------------------------------------------------------------
if (! this.Ajax) Ajax = {};

Ajax.get = function(url, callback) {
    var req = new XMLHttpRequest();
    req.open('GET', url, Boolean(callback));
    return Ajax._send(req, null, callback);
}

Ajax.post = function(url, data, callback) {
    var req = new XMLHttpRequest();
    req.open('POST', url, Boolean(callback));
    req.setRequestHeader(
        'Content-Type', 
        'application/x-www-form-urlencoded'
    );
    return Ajax._send(req, data, callback);
}

Ajax._send = function(req, data, callback) {
    if (callback) {
        req.onreadystatechange = function() {
            if (req.readyState == 4) {
                if(req.status == 200)
                    callback(req.responseText);
            }
        };
    }
    req.send(data);
    if (!callback) {
        if (req.status != 200)
            throw('Request for "' + url +
                  '" failed with status: ' + req.status);
        return req.responseText;
    }
}

//------------------------------------------------------------------------------
// Cross-Browser XMLHttpRequest v1.1
//------------------------------------------------------------------------------
/*
Emulate Gecko 'XMLHttpRequest()' functionality in IE and Opera. Opera requires
the Sun Java Runtime Environment <http://www.java.com/>.

by Andrew Gregory
http://www.scss.com.au/family/andrew/webdesign/xmlhttprequest/

This work is licensed under the Creative Commons Attribution License. To view a
copy of this license, visit http://creativecommons.org/licenses/by/1.0/ or send
a letter to Creative Commons, 559 Nathan Abbott Way, Stanford, California 94305,
USA.
*/

// IE support
if (window.ActiveXObject && !window.XMLHttpRequest) {
  window.XMLHttpRequest = function() {
    return new ActiveXObject((navigator.userAgent.toLowerCase().indexOf('msie 5') != -1) ? 'Microsoft.XMLHTTP' : 'Msxml2.XMLHTTP');
  };
}

// Opera support
if (window.opera && !window.XMLHttpRequest) {
  window.XMLHttpRequest = function() {
    this.readyState = 0; // 0=uninitialized,1=loading,2=loaded,3=interactive,4=complete
    this.status = 0; // HTTP status codes
    this.statusText = '';
    this._headers = [];
    this._aborted = false;
    this._async = true;
    this.abort = function() {
      this._aborted = true;
    };
    this.getAllResponseHeaders = function() {
      return this.getAllResponseHeader('*');
    };
    this.getAllResponseHeader = function(header) {
      var ret = '';
      for (var i = 0; i < this._headers.length; i++) {
        if (header == '*' || this._headers[i].h == header) {
          ret += this._headers[i].h + ': ' + this._headers[i].v + '\n';
        }
      }
      return ret;
    };
    this.setRequestHeader = function(header, value) {
      this._headers[this._headers.length] = {h:header, v:value};
    };
    this.open = function(method, url, async, user, password) {
      this.method = method;
      this.url = url;
      this._async = true;
      this._aborted = false;
      if (arguments.length >= 3) {
        this._async = async;
      }
      if (arguments.length > 3) {
        // user/password support requires a custom Authenticator class
        opera.postError('XMLHttpRequest.open() - user/password not supported');
      }
      this._headers = [];
      this.readyState = 1;
      if (this.onreadystatechange) {
        this.onreadystatechange();
      }
    };
    this.send = function(data) {
      if (!navigator.javaEnabled()) {
        alert("XMLHttpRequest.send() - Java must be installed and enabled.");
        return;
      }
      if (this._async) {
        setTimeout(this._sendasync, 0, this, data);
        // this is not really asynchronous and won't execute until the current
        // execution context ends
      } else {
        this._sendsync(data);
      }
    }
    this._sendasync = function(req, data) {
      if (!req._aborted) {
        req._sendsync(data);
      }
    };
    this._sendsync = function(data) {
      this.readyState = 2;
      if (this.onreadystatechange) {
        this.onreadystatechange();
      }
      // open connection
      var url = new java.net.URL(new java.net.URL(window.location.href), this.url);
      var conn = url.openConnection();
      for (var i = 0; i < this._headers.length; i++) {
        conn.setRequestProperty(this._headers[i].h, this._headers[i].v);
      }
      this._headers = [];
      if (this.method == 'POST') {
        // POST data
        conn.setDoOutput(true);
        var wr = new java.io.OutputStreamWriter(conn.getOutputStream());
        wr.write(data);
        wr.flush();
        wr.close();
      }
      // read response headers
      // NOTE: the getHeaderField() methods always return nulls for me :(
      var gotContentEncoding = false;
      var gotContentLength = false;
      var gotContentType = false;
      var gotDate = false;
      var gotExpiration = false;
      var gotLastModified = false;
      for (var i = 0; ; i++) {
        var hdrName = conn.getHeaderFieldKey(i);
        var hdrValue = conn.getHeaderField(i);
        if (hdrName == null && hdrValue == null) {
          break;
        }
        if (hdrName != null) {
          this._headers[this._headers.length] = {h:hdrName, v:hdrValue};
          switch (hdrName.toLowerCase()) {
            case 'content-encoding': gotContentEncoding = true; break;
            case 'content-length'  : gotContentLength   = true; break;
            case 'content-type'    : gotContentType     = true; break;
            case 'date'            : gotDate            = true; break;
            case 'expires'         : gotExpiration      = true; break;
            case 'last-modified'   : gotLastModified    = true; break;
          }
        }
      }
      // try to fill in any missing header information
      var val;
      val = conn.getContentEncoding();
      if (val != null && !gotContentEncoding) this._headers[this._headers.length] = {h:'Content-encoding', v:val};
      val = conn.getContentLength();
      if (val != -1 && !gotContentLength) this._headers[this._headers.length] = {h:'Content-length', v:val};
      val = conn.getContentType();
      if (val != null && !gotContentType) this._headers[this._headers.length] = {h:'Content-type', v:val};
      val = conn.getDate();
      if (val != 0 && !gotDate) this._headers[this._headers.length] = {h:'Date', v:(new Date(val)).toUTCString()};
      val = conn.getExpiration();
      if (val != 0 && !gotExpiration) this._headers[this._headers.length] = {h:'Expires', v:(new Date(val)).toUTCString()};
      val = conn.getLastModified();
      if (val != 0 && !gotLastModified) this._headers[this._headers.length] = {h:'Last-modified', v:(new Date(val)).toUTCString()};
      // read response data
      var reqdata = '';
      var stream = conn.getInputStream();
      if (stream) {
        var reader = new java.io.BufferedReader(new java.io.InputStreamReader(stream));
        var line;
        while ((line = reader.readLine()) != null) {
          if (this.readyState == 2) {
            this.readyState = 3;
            if (this.onreadystatechange) {
              this.onreadystatechange();
            }
          }
          reqdata += line + '\n';
        }
        reader.close();
        this.status = 200;
        this.statusText = 'OK';
        this.responseText = reqdata;
        this.readyState = 4;
        if (this.onreadystatechange) {
          this.onreadystatechange();
        }
        if (this.onload) {
          this.onload();
        }
      } else {
        // error
        this.status = 404;
        this.statusText = 'Not Found';
        this.responseText = '';
        this.readyState = 4;
        if (this.onreadystatechange) {
          this.onreadystatechange();
        }
        if (this.onerror) {
          this.onerror();
        }
      }
    };
  };
}
// ActiveXObject emulation
if (!window.ActiveXObject && window.XMLHttpRequest) {
  window.ActiveXObject = function(type) {
    switch (type.toLowerCase()) {
      case 'microsoft.xmlhttp':
      case 'msxml2.xmlhttp':
        return new XMLHttpRequest();
    }
    return null;
  };
}


//------------------------------------------------------------------------------
// JSON Support
//------------------------------------------------------------------------------

/*
Copyright (c) 2005 JSON.org
*/
var JSON = function () {
    var m = {
            '\b': '\\b',
            '\t': '\\t',
            '\n': '\\n',
            '\f': '\\f',
            '\r': '\\r',
            '"' : '\\"',
            '\\': '\\\\'
        },
        s = {
            'boolean': function (x) {
                return String(x);
            },
            number: function (x) {
                return isFinite(x) ? String(x) : 'null';
            },
            string: function (x) {
                if (/["\\\x00-\x1f]/.test(x)) {
                    x = x.replace(/([\x00-\x1f\\"])/g, function(a, b) {
                        var c = m[b];
                        if (c) {
                            return c;
                        }
                        c = b.charCodeAt();
                        return '\\u00' +
                            Math.floor(c / 16).toString(16) +
                            (c % 16).toString(16);
                    });
                }
                return '"' + x + '"';
            },
            object: function (x) {
                if (x) {
                    var a = [], b, f, i, l, v;
                    if (x instanceof Array) {
                        a[0] = '[';
                        l = x.length;
                        for (i = 0; i < l; i += 1) {
                            v = x[i];
                            f = s[typeof v];
                            if (f) {
                                v = f(v);
                                if (typeof v == 'string') {
                                    if (b) {
                                        a[a.length] = ',';
                                    }
                                    a[a.length] = v;
                                    b = true;
                                }
                            }
                        }
                        a[a.length] = ']';
                    } else if (x instanceof Object) {
                        a[0] = '{';
                        for (i in x) {
                            v = x[i];
                            f = s[typeof v];
                            if (f) {
                                v = f(v);
                                if (typeof v == 'string') {
                                    if (b) {
                                        a[a.length] = ',';
                                    }
                                    a.push(s.string(i), ':', v);
                                    b = true;
                                }
                            }
                        }
                        a[a.length] = '}';
                    } else {
                        return;
                    }
                    return a.join('');
                }
                return 'null';
            }
        };
    return {
        copyright: '(c)2005 JSON.org',
        license: 'http://www.crockford.com/JSON/license.html',
        stringify: function (v) {
            var f = s[typeof v];
            if (f) {
                v = f(v);
                if (typeof v == 'string') {
                    return v;
                }
            }
            return null;
        },
        parse: function (text) {
            try {
                return !(/[^,:{}\[\]0-9.\-+Eaeflnr-u \n\r\t]/.test(
                        text.replace(/"(\\.|[^"\\])*"/g, ''))) &&
                    eval('(' + text + ')');
            } catch (e) {
                return false;
            }
        }
    };
}();

// ##########################
// File: /storage/www/yur/www/lib/jemplates.js
// ##########################
/*
   This JavaScript code was generated by Jemplate, the JavaScript
   Template Toolkit. Any changes made to this file will be lost the next
   time the templates are compiled.

   Copyright 2006 - Ingy dÃ¶t Net - All rights reserved.
*/

if (typeof(Jemplate) == 'undefined')
    throw('Jemplate.js must be loaded before any Jemplate template files');

Jemplate.templateMap['airtime_kueche_vital.js.html'] = function(context) {
    if (! context) throw('Jemplate function called without context\n');
    var stash = context.stash;
    var output = '';

    try {
//line 1 "airtime_kueche_vital.js.html"
stash.set('air', stash.get('model'));
output += '\n';
//line 2 "airtime_kueche_vital.js.html"
stash.set('item', stash.get(['air', 0, 'optional_queue_item', 0]));
output += '\n';
//line 3 "airtime_kueche_vital.js.html"
stash.set('movie', stash.get(['item', 0, 'movie_', 0]));
output += '\n';
//line 4 "airtime_kueche_vital.js.html"
stash.set('fullscreen', stash.get(['model', 0, 'fullscreen', []]));
output += '\n\n';
//line 29 "airtime_kueche_vital.js.html"
if ((stash.get('item') && stash.get('movie'))) {
output += '\n';
//line 25 "airtime_kueche_vital.js.html"
if ((! stash.get('fullscreen'))) {
output += '\n	<div style="font-family:Arial, Helvetica, sans-serif; font-size:15px; color:#FFFFFF; line-height:17px;">\n		\n		<div id="mitpdf">\n			<div style="position:absolute; left:133px; top:132px; width:200px; height:17px; z-index:18"><span style="font-size:11px; line-height:13px;"><strong>Dieses Rezept als PDF downloaden</strong></span></div>\n			<div style="position:absolute; left:131px; top:156px; width:210px; height:35px; z-index:18"><span style="font-size:11px; line-height:15px;">Hier k&ouml;nnt Ihr Euch das Rezept der heu-<br>tigen Sendung downloaden</span></div>\n			<div style="position:absolute; left:172px; top:189px; z-index:18"><a href="/movies/';
//line 13 "airtime_kueche_vital.js.html"
output += stash.get(['movie', 0, 'path', 0]);
output += '/rezept.pdf" onmouseout="MM_swapImgRestore()" onmouseover="MM_swapImage(\'down\',\'\',\'/pics/kuechevital/btn_download_act.gif\',1)"><img name="down" id="down" src="/pics/kuechevital/btn_download_in.gif" width="134" height="27" border="0" alt="PDF Download"></a></div>\n			<div style="position:absolute; left:0px; top:0px; z-index:16;"><img src="/pics/kuechevital/bg.jpg" border="0"></div>\n		</div>\n			\n 		<div id="ohnepdf" style="display:none; position:absolute; left:0px; top:0px; z-index:16;"><img src="/pics/kuechevital/bgohnepdf.jpg" border="0"></div>\n\n		<div style="position:absolute; left:96px; top:2px; width:195px; height:40px; z-index:18"><strong>Heute in der Sendung:<br><span style="font-size:13px; line-height:15px;">';
//line 19 "airtime_kueche_vital.js.html"
output += stash.get(['movie', 0, 'title', 0]);
output += '</span></strong></div>\n		<div style="position:absolute; left:10px; top:265px; width:158px; height:48px; z-index:18"><span style="font-size:12px; line-height:15px;">Dann lade es jetzt hoch<br>und komme garantiert bei<br>YUR.tv ins Fernsehen!</span></div>\n		<div style="position:absolute; left:0px; top:258px; width:344px; height:59px; z-index:17; background-color:#8C8C8C;">&nbsp;</div>\n		<div style="position:absolute; left:173px; top:274px; z-index:18"><a href="javascript:PopUpWithAllorLogin()" onmouseout="MM_swapImgRestore()" onmouseover="MM_swapImage(\'hoch\',\'\',\'/pics/kuechevital/btn_upload_act.gif\',1)"><img name="hoch" id="hoch" src="/pics/kuechevital/btn_upload_in.gif" width="134" height="25" border="0" alt="zum Upload"></a></div>\n		\n	</div>\n';
}

output += '\n';
//line 28 "airtime_kueche_vital.js.html"
if ((stash.get('fullscreen'))) {
output += '\nsssddd\n';
}

output += '\n';
}

    }
    catch(e) {
        var error = context.set_error(e, output);
        throw(error);
    }

    return output;
}

Jemplate.templateMap['airtime_vote_special.js.html'] = function(context) {
    if (! context) throw('Jemplate function called without context\n');
    var stash = context.stash;
    var output = '';

    try {
output += '\n';
output += '\n';
output += '\n';
//line 4 "airtime_vote_special.js.html"
stash.set('fullscreen', stash.get(['model', 0, 'fullscreen', []]));
output += '\n';
output += '\n\n';
//line 12 "airtime_vote_special.js.html"
if ((! stash.get('fullscreen'))) {
output += '\n<div>\n	<div style="position:absolute; left:0px; top:0px; wi z-index:15;"><img src="/pics/microsite/hansenstaxi.jpg" border="0"></div>\n	<div style="position:absolute; left:110px; top:254px; z-index:19"><a onfocus="this.blur()" href="http://www.amazon.de/Hansens-Taxi-Matthias-Gr%C3%A4ser/dp/B0010DDA5S/ref=pd_bbs_sr_1?ie=UTF8&s=dvd&qid=1197533596&sr=8-1 " onmouseout="MM_swapImgRestore()" onmouseover="MM_swapImage(\'btnmopo\',\'\',\'/pics/microsite/ht_hier_act.jpg\',1)" target="_blank"><img name="btnmopo" id="btnmopo" src="/pics/microsite/ht_hier_in.jpg" width="125" height="29" border="0" alt="hier"></a></div>	\n</div>\n';
}

output += '\n';
    }
    catch(e) {
        var error = context.set_error(e, output);
        throw(error);
    }

    return output;
}

Jemplate.templateMap['charts_first3.js.html'] = function(context) {
    if (! context) throw('Jemplate function called without context\n');
    var stash = context.stash;
    var output = '';

    try {
output += '\n';
//line 2 "charts_first3.js.html"
stash.set('pagination', stash.get(['model', 0, 'pagination', 0]));
output += '\n\n';
//line 45 "charts_first3.js.html"
if ((stash.get(['pagination', 0, 'curr', 0]) == 1)) {
output += '\n	';
//line 44 "charts_first3.js.html"
if ((stash.get(['pagination', 0, 'total_entries', 0]))) {
output += '\n		';
//line 6 "charts_first3.js.html"
stash.set('count', 0);
output += '\n		';
//line 11 "charts_first3.js.html"
if ((stash.get(['pagination', 0, 'first_entry_on_page', 0]) == 1)) {
output += '\n			';
//line 8 "charts_first3.js.html"
stash.set('list', stash.get(['model', 0, 'list', 0]));
output += '\n		';
}
else {
output += '\n			';
//line 10 "charts_first3.js.html"
stash.set('list', stash.get(['model', 0, 'firstthreelist', 0]));
output += '\n		';
}

output += '\n		';
//line 41 "charts_first3.js.html"

// FOREACH 
(function() {
    var list = stash.get('list');
    list = new Jemplate.Iterator(list);
    var retval = list.get_first();
    var value = retval[0];
    var done = retval[1];
    var oldloop;
    try { oldloop = stash.get('loop') } finally {}
    stash.set('loop', list);
    try {
        while (! done) {
            stash.data['p'] = value;
output += '\n		  ';
//line 13 "charts_first3.js.html"
stash.set('platz', stash.get(['pagination', 0, 'first_entry_on_page', 0]) + stash.get('count'));
output += '\n		  ';
//line 14 "charts_first3.js.html"
stash.set('class', '');
output += '\n		  ';
//line 15 "charts_first3.js.html"
stash.set('image', '');
output += '\n		  ';
//line 23 "charts_first3.js.html"
if ((stash.get('platz') == 1)) {
output += '\n		  	<div id="firstpic">';
//line 17 "charts_first3.js.html"
if ((stash.get(['p', 0, 'movie_path', 0]))) {
output += '<div style="background-color:#AFAFAF;"><div style="padding:1px;"><img src="/movies/';
//line 17 "charts_first3.js.html"
output += stash.get(['p', 0, 'movie_path', 0]);
output += '/screen1.jpg" width="157" height="117" /></div></div>';
}

output += '</div>\n			<div id="firsttext">\n				<a href="/user/';
//line 19 "charts_first3.js.html"
output += stash.get(['p', 0, 'alias', 0]);
output += '">';
//line 19 "charts_first3.js.html"
output += stash.get(['p', 0, 'alias', 0]);
output += '</a><br>\n				<div style="overflow:hidden; height:3px;">&nbsp;</div>\n				<strong>';
//line 21 "charts_first3.js.html"
output += stash.get(['p', 0, 'movie_title', 0]);
output += '</strong>\n			</div>\n		  ';
}

output += '\n		  ';
//line 31 "charts_first3.js.html"
if ((stash.get('platz') == 2)) {
output += '\n		  <div id="secondpic">';
//line 25 "charts_first3.js.html"
if ((stash.get(['p', 0, 'movie_path', 0]))) {
output += '<div style="background-color:#AFAFAF;"><div style="padding:1px;"><img src="/movies/';
//line 25 "charts_first3.js.html"
output += stash.get(['p', 0, 'movie_path', 0]);
output += '/screen1.jpg" width="101" height="75" /></div></div>';
}

output += '</div>\n			<div id="secondtext">\n				<a href="/user/';
//line 27 "charts_first3.js.html"
output += stash.get(['p', 0, 'alias', 0]);
output += '">';
//line 27 "charts_first3.js.html"
output += stash.get(['p', 0, 'alias', 0]);
output += '</a><br>\n				<div style="overflow:hidden; height:3px;">&nbsp;</div>\n				<strong>';
//line 29 "charts_first3.js.html"
output += stash.get(['p', 0, 'movie_title', 0]);
output += '</strong>\n			</div>\n		  ';
}

output += '\n		  ';
//line 39 "charts_first3.js.html"
if ((stash.get('platz') == 3)) {
output += '\n		  <div id="thirdpic">';
//line 33 "charts_first3.js.html"
if ((stash.get(['p', 0, 'movie_path', 0]))) {
output += '<div style="background-color:#AFAFAF;"><div style="padding:1px;"><img src="/movies/';
//line 33 "charts_first3.js.html"
output += stash.get(['p', 0, 'movie_path', 0]);
output += '/screen1.jpg" width="101" height="75" /></div></div>';
}

output += '</div>\n			<div id="thirdtext">\n				<a href="/user/';
//line 35 "charts_first3.js.html"
output += stash.get(['p', 0, 'alias', 0]);
output += '">';
//line 35 "charts_first3.js.html"
output += stash.get(['p', 0, 'alias', 0]);
output += '</a><br>\n				<div style="overflow:hidden; height:3px;">&nbsp;</div>\n				<strong>';
//line 37 "charts_first3.js.html"
output += stash.get(['p', 0, 'movie_title', 0]);
output += '</strong>\n			</div>\n		  ';
}

output += '	\n		  ';
//line 40 "charts_first3.js.html"
stash.set('count', stash.get('count') + 1);
output += '\n		';;
            retval = list.get_next();
            value = retval[0];
            done = retval[1];
        }
    }
    catch(e) {
        throw(context.set_error(e, output));
    }
    stash.set('loop', oldloop);
})();

output += '\n	';
}
else {
output += '\n		<!--Zur Zeit befinden sich keine Eintr&auml;ge in der Datenbank.-->\n	';
}

output += '\n';
}

output += '\n	';
    }
    catch(e) {
        var error = context.set_error(e, output);
        throw(error);
    }

    return output;
}

Jemplate.templateMap['charts_list.js.html'] = function(context) {
    if (! context) throw('Jemplate function called without context\n');
    var stash = context.stash;
    var output = '';

    try {
output += '\n';
//line 2 "charts_list.js.html"
stash.set('list', stash.get(['model', 0, 'list', 0]));
output += '\n';
//line 3 "charts_list.js.html"
stash.set('pagination', stash.get(['model', 0, 'pagination', 0]));
output += '\n\n	<table id="resulttable" cellpadding="0" cellspacing="0" border="0">\n	';
//line 86 "charts_list.js.html"
if ((stash.get(['pagination', 0, 'total_entries', 0]))) {
output += '\n		<tr>\n			<th class="left">&nbsp;</th>\n			<th class="bg" width="42"><div>PLATZ</div></th>\n			<th class="bg" width="28"><div><img src="/pics/charts/tendenz.gif" width="16" height="12" border="0" /></div></th>\n			';
//line 16 "charts_list.js.html"
if (stash.get(['pagination', 0, 'curr', 0]) == 1) {
output += '\n			<th class="bg" width="65"><div>&nbsp;</div></th>\n			<th class="bg" width="343"><div>TITEL</div></th>\n			';
}
else {
output += '\n			<th class="bg" colspan="2" width="408"><div>TITEL</div></th>\n			';
}

output += '\n			';
//line 22 "charts_list.js.html"
if (stash.get(['pagination', 0, 'curr', 0]) == 1) {
output += '\n			<th class="bg" width="65"><div>&nbsp;</div></th>\n			<th class="bg" width="120"><div>NAME INTERPRET</div></th>\n			';
}
else {
output += '\n			<th class="bg" colspan="2" width="185"><div>NAME INTERPRET</div></th>\n			';
}

output += '\n			<th class="bg" width="100"><div>CHARTS-PUNKTE</div></th>\n			<th class="right">&nbsp;</th>\n		</tr>\n		\n		';
//line 27 "charts_list.js.html"
stash.set('count', 0);
output += '\n		';
//line 68 "charts_list.js.html"

// FOREACH 
(function() {
    var list = stash.get('list');
    list = new Jemplate.Iterator(list);
    var retval = list.get_first();
    var value = retval[0];
    var done = retval[1];
    var oldloop;
    try { oldloop = stash.get('loop') } finally {}
    stash.set('loop', list);
    try {
        while (! done) {
            stash.data['p'] = value;
output += '\n		  ';
//line 29 "charts_list.js.html"
stash.set('platz', stash.get(['pagination', 0, 'first_entry_on_page', 0]) + stash.get('count'));
output += '\n		  ';
//line 30 "charts_list.js.html"
stash.set('class', '');
output += '\n		  \n		  ';
//line 32 "charts_list.js.html"
if ((stash.get('platz') > 0 && stash.get('platz') <= 10)) {
//line 32 "charts_list.js.html"
stash.set('class', 'first10');
}

output += '\n		  ';
//line 33 "charts_list.js.html"
if ((stash.get('platz') > 10)) {
//line 33 "charts_list.js.html"
stash.set('class', 'rest');
}

output += '\n		  ';
//line 34 "charts_list.js.html"
if ((stash.get('platz') <= 10 && ! (stash.get('count') % 2))) {
//line 34 "charts_list.js.html"
stash.set('class', stash.get('class')  + ' dunkel1');
}

output += '\n		  ';
//line 35 "charts_list.js.html"
if ((stash.get('platz') > 10 && ! (stash.get('count') % 2))) {
//line 35 "charts_list.js.html"
stash.set('class', stash.get('class')  + ' dunkel2');
}

output += '\n		  ';
//line 36 "charts_list.js.html"
if ((stash.get(['model', 0, 'person', 0]) && stash.get(['p', 0, 'person', 0]) == stash.get(['model', 0, 'person', 0]))) {
//line 36 "charts_list.js.html"
stash.set('class', stash.get('class')  + ' treffer');
}

output += '\n		  \n		  ';
//line 38 "charts_list.js.html"
stash.set('tendenz', '');
output += '\n		  ';
//line 39 "charts_list.js.html"
if ((stash.get('platz') > stash.get(['p', 0, 'position_befor', 0]))) {
//line 39 "charts_list.js.html"
stash.set('tendenz', 'runter');
}

output += '\n		  ';
//line 40 "charts_list.js.html"
if ((stash.get('platz') < stash.get(['p', 0, 'position_befor', 0]))) {
//line 40 "charts_list.js.html"
stash.set('tendenz', 'hoch');
}

output += '\n		  ';
//line 41 "charts_list.js.html"
if ((stash.get('platz') == stash.get(['p', 0, 'position_befor', 0]))) {
//line 41 "charts_list.js.html"
stash.set('tendenz', 'gleich');
}

output += '\n		  ';
//line 42 "charts_list.js.html"
if ((stash.get(['p', 0, 'position_befor', 0]) == 0)) {
//line 42 "charts_list.js.html"
stash.set('tendenz', 'neu');
}

output += '\n		  \n		  ';
//line 66 "charts_list.js.html"
if ((stash.get('platz') <= 10)) {
output += '\n		  <tr>\n		  	<td class="';
//line 46 "charts_list.js.html"
output += stash.get('class');
output += '">&nbsp;</td>\n			<td class="';
//line 47 "charts_list.js.html"
output += stash.get('class');
output += '" align="center"><div><img src="/pics/charts/';
//line 47 "charts_list.js.html"
output += stash.get('platz');
output += '.gif" width="22" height="20" border="0" /></div></td>\n			<td class="';
//line 48 "charts_list.js.html"
output += stash.get('class');
output += '" align="center">';
//line 48 "charts_list.js.html"
if (stash.get(['p', 0, 'timing', 0]) > 0) {
output += '<img src="/pics/charts/tendenz_';
//line 48 "charts_list.js.html"
output += stash.get('tendenz');
output += '.gif" width="';
//line 48 "charts_list.js.html"
if (stash.get('tendenz') == 'neu') {
output += '23';
}
else {
output += '13';
}

output += '" height="';
//line 48 "charts_list.js.html"
if (stash.get('tendenz') == 'neu') {
output += '10';
}
else {
output += '13';
}

output += '" border="0" />';
}

output += '</td>\n			<td class="';
//line 49 "charts_list.js.html"
output += stash.get('class');
output += '" align="center" width="65"><div style="padding-right:5px;">';
//line 49 "charts_list.js.html"
if ((stash.get(['p', 0, 'movie_path', 0]))) {
output += '<img src="/movies/';
//line 49 "charts_list.js.html"
output += stash.get(['p', 0, 'movie_path', 0]);
output += '/screen1.jpg" width="57" height="42" />';
}

output += '</div></td>\n			<td class="';
//line 50 "charts_list.js.html"
output += stash.get('class');
output += '"><div>';
//line 50 "charts_list.js.html"
output += stash.get(['p', 0, 'movie_title', 0]);
output += '</div></td>\n			<td class="';
//line 51 "charts_list.js.html"
output += stash.get('class');
output += '" align="center"><div style="padding-right:5px;">';
//line 51 "charts_list.js.html"
if ((stash.get(['p', 0, 'image_html_topten', 0]))) {
output += '<table cellpadding="0" cellspacing="0" border="0"><tr><td valign="middle" align="center" width="57" height="42" style="background-color:#000000;"><a href="/user/';
//line 51 "charts_list.js.html"
output += stash.get(['p', 0, 'alias', 0]);
output += '">';
//line 51 "charts_list.js.html"
output += stash.get(['p', 0, 'image_html_topten', 0]);
output += '</a></td></tr></table>';
}

output += '</div></td>\n			<td class="';
//line 52 "charts_list.js.html"
output += stash.get('class');
output += '"><div><span class="alias"><div style="overflow:hidden; width:100px;"><a href="/user/';
//line 52 "charts_list.js.html"
output += stash.get(['p', 0, 'alias', 0]);
output += '">';
//line 52 "charts_list.js.html"
output += stash.get(['p', 0, 'alias', 0]);
output += '</a></div></span></div></td>\n			<td class="';
//line 53 "charts_list.js.html"
output += stash.get('class');
output += '" align="right"><div style="padding-right:10px">';
//line 53 "charts_list.js.html"
output += stash.get(['p', 0, 'points', 0]) / 100;
output += '</div></td>\n			<td class="';
//line 54 "charts_list.js.html"
output += stash.get('class');
output += '">&nbsp;</td>\n		  </tr>\n		  ';
}
else {
output += '\n		  <tr>\n		  	<td class="';
//line 58 "charts_list.js.html"
output += stash.get('class');
output += ' border_left">&nbsp;</td>\n			<td class="';
//line 59 "charts_list.js.html"
output += stash.get('class');
output += '" align="center"><div>';
//line 59 "charts_list.js.html"
output += stash.get('platz');
output += '</div></td>\n			<td class="';
//line 60 "charts_list.js.html"
output += stash.get('class');
output += '" align="center">';
//line 60 "charts_list.js.html"
if (stash.get(['p', 0, 'timing', 0]) > 0) {
output += '<img src="/pics/charts/tendenz2_';
//line 60 "charts_list.js.html"
output += stash.get('tendenz');
output += '.gif" width="';
//line 60 "charts_list.js.html"
if (stash.get('tendenz') == 'neu') {
output += '23';
}
else {
output += '13';
}

output += '" height="';
//line 60 "charts_list.js.html"
if (stash.get('tendenz') == 'neu') {
output += '10';
}
else {
output += '13';
}

output += '" border="0" />';
}
else {
output += '&nbsp;';
}

output += '</td>\n			<td colspan="2" class="';
//line 61 "charts_list.js.html"
output += stash.get('class');
output += '"><div>';
//line 61 "charts_list.js.html"
output += stash.get(['p', 0, 'movie_title', 0]);
output += '</div></td>\n			<td colspan="2" class="';
//line 62 "charts_list.js.html"
output += stash.get('class');
output += '"><div><span class="alias"><div style="overflow:hidden; width:100px;"><a href="/user/';
//line 62 "charts_list.js.html"
output += stash.get(['p', 0, 'alias', 0]);
output += '">';
//line 62 "charts_list.js.html"
output += stash.get(['p', 0, 'alias', 0]);
output += '</a></div></span></div></td>\n			<td class="';
//line 63 "charts_list.js.html"
output += stash.get('class');
output += '" align="right"><div style="padding-right:10px">';
//line 63 "charts_list.js.html"
output += stash.get(['p', 0, 'points', 0]) / 100;
output += '</div></td>\n			<td class="';
//line 64 "charts_list.js.html"
output += stash.get('class');
output += ' border_right">&nbsp;</td>\n		  </tr>\n		  ';
}

output += '\n		  ';
//line 67 "charts_list.js.html"
stash.set('count', stash.get('count') + 1);
output += '\n		';;
            retval = list.get_next();
            value = retval[0];
            done = retval[1];
        }
    }
    catch(e) {
        throw(context.set_error(e, output));
    }
    stash.set('loop', oldloop);
})();

output += '\n\n	\n		<tr>\n			<td colspan="9">\n				<table id="footer" cellspacing="0" cellpadding="0" border="0" width="100%">\n					<tr>\n						<td class="left">&nbsp;</td>\n						<td class="bg " width="110"><strong>Seite ';
//line 76 "charts_list.js.html"
output += stash.get(['pagination', 0, 'curr', 0]);
output += ' von ';
//line 76 "charts_list.js.html"
output += stash.get(['pagination', 0, 'last', 0]);
output += '</strong></td>\n						<td class="bg">';
//line 77 "charts_list.js.html"
if ((stash.get(['pagination', 0, 'pages', 0]) > 1)) {
//line 77 "charts_list.js.html"
output += context.include('charts_pagination.js.html');
}
else {
output += '&nbsp;';
}

output += '</td>\n						<td class="bg" align="right" width="180">Gehe zur Seite <input id="seite" type="text" style="width:20px" maxlength="3">&nbsp;&nbsp;<input id="LosButton" type="button" value="Los" onclick="__Yur.charts.getPageForm(\'seite\')">&nbsp;&nbsp;&nbsp;</td>\n						<td class="right">&nbsp;</td>\n					</tr>\n				</table>\n			</td>\n		</tr>\n	';
}
else {
output += '\n		<tr><td align="center"><br>Zurzeit gibt es noch keine Charts f&uuml;r diesen Zeitraum.<br><br></td></tr>\n	';
}

output += '\n	</table>\n	';
    }
    catch(e) {
        var error = context.set_error(e, output);
        throw(error);
    }

    return output;
}

Jemplate.templateMap['charts_pagination.js.html'] = function(context) {
    if (! context) throw('Jemplate function called without context\n');
    var stash = context.stash;
    var output = '';

    try {
output += '	';
//line 1 "charts_pagination.js.html"
stash.set('pagination', '');
output += '\n	';
//line 2 "charts_pagination.js.html"
stash.set('span', '');
output += '\n	';
//line 3 "charts_pagination.js.html"
stash.set('pa', stash.get(['model', 0, 'pagination', 0]));
output += '\n	';
//line 4 "charts_pagination.js.html"
if ((stash.get(['pa', 0, 'first', 0]) >= 5 || stash.get(['pa', 0, 'last', 0]) >= 1)) {
//line 4 "charts_pagination.js.html"
stash.set('pagination', 'paginationPlatzSparen');
}

output += '\n	';
//line 5 "charts_pagination.js.html"
if ((stash.get(['pa', 0, 'first', 0]) >= 50 || stash.get(['pa', 0, 'last', 0]) >= 1)) {
//line 5 "charts_pagination.js.html"
stash.set('span', 'spanPlatzSparen');
}

output += '\n	<div class="paginationContainerRanking">\n	  <div class="pagination ';
//line 7 "charts_pagination.js.html"
output += stash.get('pagination');
output += '">\n		<!--div class="rechts">\n			<span class="cursor';
//line 9 "charts_pagination.js.html"
if ((! stash.get(['pa', 0, 'forward', 0]))) {
output += ' disabled';
}

output += '" onclick="__Yur.ranking.getPage(';
//line 9 "charts_pagination.js.html"
output += stash.get(['pa', 0, 'last', 0]);
output += ')">\n				&gt;&gt;\n			</span>\n		</div-->\n		<!--div class="links">\n			<span class="cursor';
//line 14 "charts_pagination.js.html"
if ((! stash.get(['pa', 0, 'back', 0]))) {
output += ' disabled';
}

output += '" onclick="__Yur.ranking.getPage(';
//line 14 "charts_pagination.js.html"
output += stash.get(['pa', 0, 'first', 0]);
output += ')">\n				&lt;&lt;\n			</span>\n		</div-->\n		';
//line 18 "charts_pagination.js.html"
stash.set('count', 0);
output += '\n		<div class="mitte">\n			<span class="cursor';
//line 20 "charts_pagination.js.html"
if ((! stash.get(['pa', 0, 'back', 0]))) {
output += ' disabled';
}

output += '" onclick="__Yur.charts.getPage(';
//line 20 "charts_pagination.js.html"
output += stash.get(['pa', 0, 'back', 0]);
output += ')">\n				&lt;&nbsp;zur&uuml;ck\n			</span>&nbsp;\n		';
//line 27 "charts_pagination.js.html"

// FOREACH 
(function() {
    var list = stash.get(['pa', 0, 'steps', 0]);
    list = new Jemplate.Iterator(list);
    var retval = list.get_first();
    var value = retval[0];
    var done = retval[1];
    var oldloop;
    try { oldloop = stash.get('loop') } finally {}
    stash.set('loop', list);
    try {
        while (! done) {
            stash.data['step'] = value;
output += '\n			';
//line 24 "charts_pagination.js.html"
if ((stash.get('count'))) {
output += '|';
}

output += '\n			';
//line 25 "charts_pagination.js.html"
if ((stash.get(['pa', 0, 'curr', 0]) != stash.get('step'))) {
output += '<span class="cursor ';
//line 25 "charts_pagination.js.html"
output += stash.get('span');
output += '" onclick="__Yur.charts.getPage(';
//line 25 "charts_pagination.js.html"
output += stash.get('step');
output += ')">';
}
else {
output += '<span class="act ';
//line 25 "charts_pagination.js.html"
output += stash.get('span');
output += '">';
}

//line 25 "charts_pagination.js.html"
output += stash.get(['tool', 0, 'format_ranking_pagination_steps_with_first', [ stash.get('step'), stash.get(['pa', 0, 'entries_per_page', 0]), stash.get(['pa', 0, 'total_entries', 0]), stash.get(['pa', 0, 'first_site_entries', 0]) ]]);
output += '</span>\n			';
//line 26 "charts_pagination.js.html"
stash.set('count', stash.get('count') + 1);
output += '\n		';;
            retval = list.get_next();
            value = retval[0];
            done = retval[1];
        }
    }
    catch(e) {
        throw(context.set_error(e, output));
    }
    stash.set('loop', oldloop);
})();

output += '\n			&nbsp;<span class="cursor';
//line 28 "charts_pagination.js.html"
if ((! stash.get(['pa', 0, 'forward', 0]))) {
output += ' disabled';
}

output += '" onclick="__Yur.charts.getPage(';
//line 28 "charts_pagination.js.html"
output += stash.get(['pa', 0, 'forward', 0]);
output += ')">\n				weiter&nbsp;&gt;\n			</span>\n		</div>\n	  </div>\n	</div>';
    }
    catch(e) {
        var error = context.set_error(e, output);
        throw(error);
    }

    return output;
}

Jemplate.templateMap['current.js.html'] = function(context) {
    if (! context) throw('Jemplate function called without context\n');
    var stash = context.stash;
    var output = '';

    try {
//line 1 "current.js.html"
stash.set('air', stash.get('model'));
output += '\n';
//line 2 "current.js.html"
stash.set('item', stash.get(['air', 0, 'optional_queue_item', 0]));
output += '\n';
//line 3 "current.js.html"
stash.set('movie', stash.get(['item', 0, 'movie_', 0]));
output += '\n\n';
//line 63 "current.js.html"
if ((stash.get('item') && stash.get('movie'))) {
output += '\n\n	';
//line 62 "current.js.html"
if (stash.get(['air', 0, 'yur_sitename', 0]) == 'remote') {
output += '\n		<div style="position:absolute; left:146px; top:13px; z-index:999999;">';
//line 8 "current.js.html"
output += stash.get(['movie', 0, 'uploader_', 0, 'alias', 0]);
output += '</div>\n		<div style="float:left;"><a href="http://www.yur.tv" target="_blank"><img src="/pics/shared/t.gif"  width="147" height="64" /></a></div>\n		<div style="float:left; padding-left:5px; padding-top:19px;">\n			<table cellpadding="0" cellspacing="0" border="0" style="font-size:12px;">\n				<tr>\n					<td width="45"><strong>Clip:</strong></td>\n					<td><div title="';
//line 14 "current.js.html"
output += stash.get(['movie', 0, 'title', 0]);
output += '" style="width:235px; height:12px; overflow:hidden">';
//line 14 "current.js.html"
output += stash.get(['movie', 0, 'title', 0]);
output += '</div></td>\n				</tr>\n				<tr>\n					<td colspan="2" height="3"></td>\n				</tr>\n				<tr>\n					<td width="45"><strong>L&auml;nge:</strong></td>\n					<td>';
//line 21 "current.js.html"
output += stash.get(['tool', 0, 'format_time_period', [ stash.get(['air', 0, 'time_remaining', 0]) ]]);
output += '</td>\n				</tr>\n			</table>\n		</div>\n		<div clear="all"></div>\n	';
}
else {
output += '\n								<div class="boxbg_hell">\n									<div class="abstand">\n										<div class="cur_titel" style="width:170px; overflow:hidden">';
//line 29 "current.js.html"
output += stash.get(['movie', 0, 'title', 0]);
output += '</div>\n										<div class="trenner" style="height:3px"><img src="/pics/shared/t.gif" border="0" width="1" height="1"></div>\n										<div class="cur_details">';
//line 31 "current.js.html"
output += stash.get(['tool', 0, 'format_time_period', [ stash.get(['air', 0, 'time_remaining', 0]) ]]);
output += ' | ';
//line 31 "current.js.html"
output += stash.get(['air', 0, 'points', 0]) / 100;
output += ' Punkte (';
//line 31 "current.js.html"
output += stash.get(['movie', 0, 'uploader_', 0, 'shares', 0]);
output += ' Aktien)</div>\n									</div>\n								</div>\n								<div class="trenner"><div class="dunkel"><img src="/pics/shared/t.gif" border="0" width="1" height="1"></div></div>\n								<div class="trenner"><div class="hell"><img src="/pics/shared/t.gif" border="0" width="1" height="1"></div></div>			\n								<div class="boxbg_dunkel">\n									\n									<div style="width:190px; height:68px;">\n										<div style="padding-left:6px; padding-top:5px;">\n											';
//line 42 "current.js.html"
if ((stash.get(['movie', 0, 'uploader_', 0, 'image', 0]))) {
output += '\n											<div style="float:left; width:48px; height:58px; background-color:#797979;"><div style="padding-left:1px; padding-top:1px;"><a href="/user/';
//line 41 "current.js.html"
output += stash.get(['movie', 0, 'uploader_', 0, 'alias', 0]);
output += '">';
//line 41 "current.js.html"
output += context.process('image_center_box.js.html', { 'color': '000000', 'width': '46', 'height': '56', 'image': stash.get(['movie', 0, 'uploader_', 0, 'image_small', 0]) });
output += '</a></div></div>\n											';
}

output += '\n											<div class="aktuellerclip_text1" style="width:125px; height:32px; float:left;">\n												<div style="padding-left:4px; padding-top:2px;">\n													<div>Ein Clip von User:</div>\n													<div class="aktuellerclip_text2"><a href="/channel/';
//line 46 "current.js.html"
output += stash.get(['movie', 0, 'uploader_', 0, 'alias', 0]);
output += '"><strong>';
//line 46 "current.js.html"
output += stash.get(['movie', 0, 'uploader_', 0, 'alias', 0]);
output += '<span style="font-size:11px;"> (';
//line 46 "current.js.html"
output += stash.get(['movie', 0, 'uploader_', 0, 'shares', 0]);
output += ')</span></strong></a></div>\n													\n													\n													\n													<div style="padding-top:3px;" class="small">\n														<div class="btnbox2 cursor">\n															<div class="in" onmouseover="switchClassTo(this,\'act\')" onmouseout="switchClassTo(this,\'in\')">\n																<div class="abstand"><a href="/channel/';
//line 53 "current.js.html"
output += stash.get(['movie', 0, 'uploader_', 0, 'alias', 0]);
output += '">Zum Channel</a></div>\n															</div>\n														</div>\n													</div>\n												</div>\n											</div>\n										</div>\n									</div>\n								</div>\n	';
}

output += '\n';
}

    }
    catch(e) {
        var error = context.set_error(e, output);
        throw(error);
    }

    return output;
}

Jemplate.templateMap['current_transition.js.html'] = function(context) {
    if (! context) throw('Jemplate function called without context\n');
    var stash = context.stash;
    var output = '';

    try {
//line 1 "current_transition.js.html"
stash.set('air', stash.get('model'));
output += '\n';
//line 2 "current_transition.js.html"
stash.set('item', stash.get(['air', 0, 'optional_queue_item', 0]));
output += '\n';
//line 3 "current_transition.js.html"
stash.set('movie', stash.get(['item', 0, 'movie_', 0]));
output += '\n\n<div class="titel film_text"><strong id="curTitle">Spannung f&uuml;r ';
//line 5 "current_transition.js.html"
output += stash.get(['tool', 0, 'format_time_period', [ stash.get(['air', 0, 'time_remaining', 0]) ]]);
output += ' Sekunden</strong></div>\n<div class="art film_text">\n  <span id="curTags"></span>\n</div>\n<div class="underground"><img src="pics/main_underground.gif" width="448" height="23" /></div>';
    }
    catch(e) {
        var error = context.set_error(e, output);
        throw(error);
    }

    return output;
}

Jemplate.templateMap['friends.js.html'] = function(context) {
    if (! context) throw('Jemplate function called without context\n');
    var stash = context.stash;
    var output = '';

    try {
//line 1 "friends.js.html"
stash.set('list', stash.get(['model', 0, 'list', 0]));
output += '\n';
//line 2 "friends.js.html"
stash.set('alias', stash.get(['model', 0, 'alias', 0]));
output += '\n';
//line 3 "friends.js.html"
stash.set('gesamt', stash.get(['model', 0, 'gesamt', 0]));
output += '\n';
//line 4 "friends.js.html"
stash.set('pagination', stash.get(['model', 0, 'pagination', 0]));
output += '\n\n';
//line 6 "friends.js.html"
stash.set('k_counter', 0);
output += '\n\n\n\n						<div class="std_boxbgcolor">\n							<div><img src="/pics/shared/box_top_schatten_teaser.png" width="190" height="3" alt="" /></div>';
//line 26 "friends.js.html"

// FOREACH 
(function() {
    var list = stash.get('list');
    list = new Jemplate.Iterator(list);
    var retval = list.get_first();
    var value = retval[0];
    var done = retval[1];
    var oldloop;
    try { oldloop = stash.get('loop') } finally {}
    stash.set('loop', list);
    try {
        while (! done) {
            stash.data['eintrag'] = value;
output += '\n								<div class="abstand2">\n									';
//line 20 "friends.js.html"
if ((stash.get(['eintrag', 0, 'person', 0, 'image', 0]))) {
output += '\n									<div style="float:left; width:50px;">	\n										<div style="width:47px; height:53px; background-color:#8C8C8C;">\n											<div style="padding-left:1px; padding-top:1px;">';
//line 17 "friends.js.html"
output += context.process('image_center_box.js.html', { 'color': '000000', 'image': stash.get(['eintrag', 0, 'person', 0, 'image_friends_box', 0]), 'width': '45', 'height': '51' });
output += '</div>\n										</div>\n									</div>\n									';
}

output += '\n									<div class="std_boxtext_u" ';
//line 21 "friends.js.html"
if ((stash.get(['eintrag', 0, 'person', 0, 'image', 0]))) {
output += 'style="float:right; width:130px; overflow:hidden"';
}

output += '>\n										<div><strong><a href="/channel/';
//line 22 "friends.js.html"
output += stash.get(['eintrag', 0, 'person', 0, 'alias', 0]);
output += '">';
//line 22 "friends.js.html"
output += stash.get(['eintrag', 0, 'person', 0, 'alias', 0]);
output += '</a></strong> <span style="font-size:10px;">(';
//line 22 "friends.js.html"
output += stash.get(['eintrag', 0, 'person', 0, 'shares', 0]);
output += ' Aktien)</span></div>\n										<div>';
//line 23 "friends.js.html"
if ((stash.get(['eintrag', 0, 'person', 0, 'beschreibung', 0]))) {
//line 23 "friends.js.html"
output += stash.get(['eintrag', 0, 'person_short_text', 0]);
}

output += '</div>\n									</div>';
//line 24 "friends.js.html"
if ((stash.get(['eintrag', 0, 'person', 0, 'image', 0]))) {
output += '<div style="clear:both"></div>';
}

output += '\n								</div><div class="btnbox2 cursor" style="height:20px; overflow:hidden"><div onclick="location.href=\'/channel/';
//line 25 "friends.js.html"
output += stash.get(['eintrag', 0, 'person', 0, 'alias', 0]);
output += '\'" class="in" onmouseover="switchClassTo(this,\'act\')" onmouseout="switchClassTo(this,\'in\')"><div class="abstand">Zum Channel</div></div>\n								</div>';;
            retval = list.get_next();
            value = retval[0];
            done = retval[1];
        }
    }
    catch(e) {
        throw(context.set_error(e, output));
    }
    stash.set('loop', oldloop);
})();

output += '<div class="freundeboxbottombg">\n								<div><img src="/pics/shared/box_top_schatten_teaser.png" width="190" height="3" alt="';
//line 27 "friends.js.html"
output += stash.get('alt_text');
output += '" /></div>\n								<div style="padding-left:8px; padding-bottom:6px; padding-top:6px;" class="std_boxtext_u"><strong>... ';
//line 28 "friends.js.html"
if (stash.get('gesamt') > 0) {
//line 28 "friends.js.html"
output += stash.get('gesamt');
output += ' Freund';
//line 28 "friends.js.html"
if (stash.get('gesamt') > 1) {
output += 'e';
}

output += ' insgesamt.';
}
else {
output += 'noch keine Freunde';
}

output += '</strong></div>';
//line 33 "friends.js.html"
if (stash.get(['pagination', 0, 'pages', 0]) > 1) {
output += '\n								<div style="padding-bottom:8px; padding-left:8px;">\n									<a href="javascript:__Yur.friends.fetchFriends(\'';
//line 31 "friends.js.html"
output += stash.get('alias');
output += '\',\'';
//line 31 "friends.js.html"
if ((stash.get(['pagination', 0, 'forward', 0]))) {
//line 31 "friends.js.html"
output += stash.get(['pagination', 0, 'forward', 0]);
}
else {
//line 31 "friends.js.html"
output += 1;
}

output += '\');" onmouseout="MM_swapImgRestore()" onmouseover="MM_swapImage(\'weitereanzeigenbtn\',\'\',\'/pics/shared/buttons/weitereanzeigen_act.gif\',1)"><img src="/pics/shared/buttons/weitereanzeigen_in.gif" alt="Weitere anzeigen" name="weitereanzeigenbtn" width="174" height="20" border="0" id="weitereanzeigenbtn" /></a>\n								</div>\n								';
}

output += '\n							</div>\n							<div class="trenner"><div class="hell"><img src="/pics/shared/t.gif" border="0" width="1" height="1"></div></div>\n						</div>\n';
    }
    catch(e) {
        var error = context.set_error(e, output);
        throw(error);
    }

    return output;
}

Jemplate.templateMap['image_center_box.js.html'] = function(context) {
    if (! context) throw('Jemplate function called without context\n');
    var stash = context.stash;
    var output = '';

    try {
output += '<table cellpadding="0" cellspacing="0" border="0" bgcolor="#';
//line 1 "image_center_box.js.html"
output += stash.get('color');
output += '"><tr><td width="';
//line 1 "image_center_box.js.html"
output += stash.get('width');
output += '" height="';
//line 1 "image_center_box.js.html"
output += stash.get('height');
output += '" valign="middle" align="center">';
//line 1 "image_center_box.js.html"
output += stash.get('image');
output += '</td></tr></table>';
    }
    catch(e) {
        var error = context.set_error(e, output);
        throw(error);
    }

    return output;
}

Jemplate.templateMap['last_kommentar.js.html'] = function(context) {
    if (! context) throw('Jemplate function called without context\n');
    var stash = context.stash;
    var output = '';

    try {
//line 1 "last_kommentar.js.html"
stash.set('list', stash.get(['model', 0, 'list', 0]));
output += '\n';
//line 2 "last_kommentar.js.html"
stash.set('mid', stash.get(['model', 0, 'movie_id', 0]));
output += '\n\n';
//line 4 "last_kommentar.js.html"
stash.set('k_counter', 0);
output += '\n\n<table cellspacing="0" cellpadding="0" border="0" width="100%">\n	<tr>\n		<td colspan="3"><div style="padding-top:3px; padding-bottom:5px;"><div class="line1"><img src="/pics/shared/t.gif" border="0" height="1" width="1"></div></div></td>\n	</tr>\n	<tr>\n		<td class="kommentarheader" width="180"><div style="padding-left:10px"><strong>Kommentare zu diesem Clip</strong></div></td>\n		<td width="190"><a href="javascript:__Yur.lastkommentar.showkommentaertextbox(';
//line 12 "last_kommentar.js.html"
output += stash.get('mid');
output += ')" onmouseout="MM_swapImgRestore()" onmouseover="MM_swapImage(\'schreibenbtn';
//line 12 "last_kommentar.js.html"
output += stash.get('mid');
output += '\',\'\',\'/pics/shared/buttons/kommentar_schreiben_act.gif\',1)"><img src="/pics/shared/buttons/kommentar_schreiben_in.gif" alt="Kommentar schreiben" name="schreibenbtn';
//line 12 "last_kommentar.js.html"
output += stash.get('mid');
output += '" width="157" height="17" border="0" id="schreibenbtn';
//line 12 "last_kommentar.js.html"
output += stash.get('mid');
output += '" /></a></td>\n		<td align="right">\n			';
//line 14 "last_kommentar.js.html"
stash.set('pa', stash.get(['model', 0, 'pagination', 0]));
output += '\n			<div style="padding-right:6px;" class="headertext2">';
//line 16 "last_kommentar.js.html"
if (stash.get(['pa', 0, 'back', 0])) {
output += '<a href="javascript:__Yur.lastkommentar.fetchKommentar(';
//line 16 "last_kommentar.js.html"
output += stash.get('mid');
output += ',';
//line 16 "last_kommentar.js.html"
output += stash.get(['pa', 0, 'back', 0]);
output += ');">Zur&uuml;ck</a>&nbsp;&nbsp;';
}

//line 16 "last_kommentar.js.html"
stash.set('count', 0);
output += '<span class="headertext3">';
//line 16 "last_kommentar.js.html"

// FOREACH 
(function() {
    var list = stash.get(['pa', 0, 'steps', 0]);
    list = new Jemplate.Iterator(list);
    var retval = list.get_first();
    var value = retval[0];
    var done = retval[1];
    var oldloop;
    try { oldloop = stash.get('loop') } finally {}
    stash.set('loop', list);
    try {
        while (! done) {
            stash.data['step'] = value;
//line 16 "last_kommentar.js.html"
if ((stash.get('count') == 0) && (stash.get('step') != stash.get(['pa', 0, 'first', 0]))) {
output += '..&nbsp;&nbsp;';
}

//line 16 "last_kommentar.js.html"
if ((stash.get('count'))) {
output += '|&nbsp;&nbsp;';
}

//line 16 "last_kommentar.js.html"
if ((stash.get(['pa', 0, 'curr', 0]) != stash.get('step'))) {
output += '<a href="javascript:__Yur.lastkommentar.fetchKommentar(';
//line 16 "last_kommentar.js.html"
output += stash.get('mid');
output += ',';
//line 16 "last_kommentar.js.html"
output += stash.get('step');
output += ');">';
//line 16 "last_kommentar.js.html"
output += stash.get('step');
output += '</a>';
}
else {
output += '<span class="currenttext2">';
//line 16 "last_kommentar.js.html"
output += stash.get('step');
output += '</span>';
}

output += '&nbsp;&nbsp;';
//line 16 "last_kommentar.js.html"
if ((stash.get('count') == 4) && (stash.get('step') != stash.get(['pa', 0, 'last', 0]))) {
output += '..&nbsp;&nbsp;';
}

//line 16 "last_kommentar.js.html"
stash.set('count', stash.get('count') + 1);;
            retval = list.get_next();
            value = retval[0];
            done = retval[1];
        }
    }
    catch(e) {
        throw(context.set_error(e, output));
    }
    stash.set('loop', oldloop);
})();

output += '</span>';
//line 16 "last_kommentar.js.html"
if (stash.get(['pa', 0, 'forward', 0])) {
output += '<a href="javascript:__Yur.lastkommentar.fetchKommentar(';
//line 16 "last_kommentar.js.html"
output += stash.get('mid');
output += ',';
//line 16 "last_kommentar.js.html"
output += stash.get(['pa', 0, 'forward', 0]);
output += ');">Weiter</a>';
}

output += '\n			</div>\n		</td>\n	</tr>\n</table>\n\n<table cellspacing="0" cellpadding="0" border="0" width="100%" class="list1" id="newkommentarschreiben';
//line 22 "last_kommentar.js.html"
output += stash.get('mid');
output += '" style="display:none">\n	<tr>\n		<td colspan="2"><div style="padding-top:5px;"><div class="line1"><img src="/pics/shared/t.gif" border="0" height="1" width="1"></div></div></td>\n	</tr>\n	<tr>\n		<td colspan="2" height="5"><img src="/pics/shared/t.gif" border="0" height="1" width="1"></td>\n	</tr>\n	<tr>\n		<td width="380"><div style="padding-left:10px;"><textarea class="inputfield" id="new_kommentar_text_';
//line 30 "last_kommentar.js.html"
output += stash.get('mid');
output += '" onkeyup="kontrolle(this,\'zeichenuebrig';
//line 30 "last_kommentar.js.html"
output += stash.get('mid');
output += '\')" style="width:335px; height:80px;" wrap="physical"></textarea></div></td>\n		<td valign="bottom" class="contenttext">\n			<div>Noch <strong><span id="zeichenuebrig';
//line 32 "last_kommentar.js.html"
output += stash.get('mid');
output += '">500</span></strong> Zeichen erlaubt </div>\n			<div style="padding-top:6px;"><a href="javascript:__Yur.lastkommentar.hidekommentaertextbox(';
//line 33 "last_kommentar.js.html"
output += stash.get('mid');
output += ')" onmouseout="MM_swapImgRestore()" onmouseover="MM_swapImage(\'newabbrechenbtn';
//line 33 "last_kommentar.js.html"
output += stash.get('mid');
output += '\',\'\',\'/pics/shared/buttons/abbrechen_act.gif\',1)"><img src="/pics/shared/buttons/abbrechen_in.gif" alt="" name="newabbrechenbtn';
//line 33 "last_kommentar.js.html"
output += stash.get('mid');
output += '" width="157" height="16" border="0" id="newabbrechenbtn';
//line 33 "last_kommentar.js.html"
output += stash.get('mid');
output += '" /></a></div>\n			<div style="padding-top:6px;"><a href="javascript:__Yur.lastkommentar.sendnew(';
//line 34 "last_kommentar.js.html"
output += stash.get('mid');
output += ')" onmouseout="MM_swapImgRestore()" onmouseover="MM_swapImage(\'newpostenbtn';
//line 34 "last_kommentar.js.html"
output += stash.get('mid');
output += '\',\'\',\'/pics/shared/buttons/kommentar_posten_act.gif\',1)"><img src="/pics/shared/buttons/kommentar_posten_in.gif" alt="" name="newpostenbtn';
//line 34 "last_kommentar.js.html"
output += stash.get('mid');
output += '" width="157" height="17" border="0" id="newpostenbtn';
//line 34 "last_kommentar.js.html"
output += stash.get('mid');
output += '" /></a></div>\n		</td>\n	</tr>\n	<tr>\n		<td colspan="2" height="5"><img src="/pics/shared/t.gif" border="0" height="1" width="1"></td>\n	</tr>\n</table>\n\n<table cellspacing="0" cellpadding="0" border="0" width="100%" class="list1" id="newkommentarerfolgreich';
//line 42 "last_kommentar.js.html"
output += stash.get('mid');
output += '" style="display:none">\n	<tr>\n		<td><div style="padding-top:5px;"><div class="line1"><img src="/pics/shared/t.gif" border="0" height="1" width="1"></div></div></td>\n	</tr>\n	<tr>\n		<td height="5"><img src="/pics/shared/t.gif" border="0" height="1" width="1"></td>\n	</tr>\n	<tr>\n		<td class="contenttext" style="padding-left:10px;">Kommentar erfolgreich gepostet</td>\n	</tr>\n</table>\n\n\n';
//line 166 "last_kommentar.js.html"

// FOREACH 
(function() {
    var list = stash.get('list');
    list = new Jemplate.Iterator(list);
    var retval = list.get_first();
    var value = retval[0];
    var done = retval[1];
    var oldloop;
    try { oldloop = stash.get('loop') } finally {}
    stash.set('loop', list);
    try {
        while (! done) {
            stash.data['obj'] = value;
output += '\n';
//line 56 "last_kommentar.js.html"
stash.set('k_counter', stash.get('k_counter') + 1);
output += '\n';
//line 57 "last_kommentar.js.html"
stash.set('answerlist', stash.get(['obj', 0, 'answerlist', 0]));
output += '\n\n';
//line 59 "last_kommentar.js.html"
stash.set('k', stash.get(['obj', 0, 'kommentar', 0]));
output += '\n';
//line 60 "last_kommentar.js.html"
stash.set('p', stash.get(['obj', 0, 'person', 0]));
output += '\n\n';
//line 165 "last_kommentar.js.html"
if ((stash.get('k') && stash.get('p'))) {
output += '\n<table cellspacing="0" cellpadding="0" border="0" width="100%" class="list1">\n	<tr>\n		<td colspan="7"><div style="padding-top:5px;"><div class="line1"><img src="/pics/shared/t.gif" border="0" height="1" width="1"></div></div></td>\n	</tr>\n	<tr>\n		<td colspan="7" height="5"><img src="/pics/shared/t.gif" border="0" height="1" width="1"></td>\n	</tr>\n	<tr>\n		<td width="75" valign="top" align="left" style="padding-top:4px; padding-bottom:4px;"><div style="padding-left:10px;"><div style="width:57px; height:57px; background-color:#8C8C8C;"><div style="padding:1px;"><div style="width:55px; height:55px; background-color:#000000" align="center">';
//line 71 "last_kommentar.js.html"
output += stash.get(['p', 0, 'image_kommentar', 0]);
output += '</div></div></div></div></td>\n		<td valign="top">\n			<div style="padding-top:4px;">\n				<div class="contenttext" style="float:left; width:300px;"><strong>';
//line 74 "last_kommentar.js.html"
output += stash.get(['p', 0, 'alias', 0]);
output += ':</strong>&nbsp;(vor ';
//line 74 "last_kommentar.js.html"
output += stash.get(['k', 0, 'time_difference', 0]);
output += ')</div>\n				<div class="contenttext" align="right" style="float:right; width:78px;"><a href="javascript:__Yur.ReportSpamKommentar(';
//line 75 "last_kommentar.js.html"
output += stash.get(['k', 0, 'id', 0]);
output += ')">Report Spam&nbsp;&nbsp;<img src="/pics/shared/pfeil.gif" border="0"></a></div><div style="clear:both"></div>\n				<div class="contenttext">';
//line 76 "last_kommentar.js.html"
output += stash.get(['k', 0, 'text', 0]);
output += '</div>\n				<div style="padding-top:10px;"><a href="javascript:__Yur.lastkommentar.showantworttextbox(';
//line 77 "last_kommentar.js.html"
output += stash.get(['k', 0, 'id', 0]);
output += ')" onmouseout="MM_swapImgRestore()" onmouseover="MM_swapImage(\'antwortenbtn';
//line 77 "last_kommentar.js.html"
output += stash.get(['k', 0, 'id', 0]);
output += '\',\'\',\'/pics/shared/buttons/antworten_act.gif\',1)"><img src="/pics/shared/buttons/antworten_in.gif" alt="" name="antwortenbtn';
//line 77 "last_kommentar.js.html"
output += stash.get(['k', 0, 'id', 0]);
output += '" width="115" height="17" border="0" id="antwortenbtn';
//line 77 "last_kommentar.js.html"
output += stash.get(['k', 0, 'id', 0]);
output += '" /></a></div>\n			</div>\n		</td>\n		<td width="2%"><img src="/pics/shared/t.gif" border="0" height="1" width="1"></td>\n		<td width="1" align="center" style="background-color:#505050;"><img src="/pics/shared/t.gif" border="0" height="1" width="1"></td>\n		<td width="2%"><img src="/pics/shared/t.gif" border="0" height="1" width="1"></td>\n		<td width="70" class="contenttext" valign="top" style="padding-top:4px;" align="center">\n			<div align="left" style="padding-bottom:5px; width:63px;">Bewerte den<br>Kommentar</div>\n			<div><a href="javascript:__Yur.lastkommentar.BewertungPositiv(';
//line 85 "last_kommentar.js.html"
output += stash.get(['k', 0, 'id', 0]);
output += ')" onmouseout="MM_swapImgRestore()" onmouseover="MM_swapImage(\'plusbtn';
//line 85 "last_kommentar.js.html"
output += stash.get(['k', 0, 'id', 0]);
output += '\',\'\',\'/pics/shared/buttons/plus_act.gif\',1)"><img src="/pics/shared/buttons/plus_in.gif" alt="" name="plusbtn';
//line 85 "last_kommentar.js.html"
output += stash.get(['k', 0, 'id', 0]);
output += '" width="30" height="20" border="0" id="plusbtn';
//line 85 "last_kommentar.js.html"
output += stash.get(['k', 0, 'id', 0]);
output += '" /></a><a href="javascript:__Yur.lastkommentar.BewertungNegativ(';
//line 85 "last_kommentar.js.html"
output += stash.get(['k', 0, 'id', 0]);
output += ')" onmouseout="MM_swapImgRestore()" onmouseover="MM_swapImage(\'minusbtn';
//line 85 "last_kommentar.js.html"
output += stash.get(['k', 0, 'id', 0]);
output += '\',\'\',\'/pics/shared/buttons/minus_act.gif\',1)"><img src="/pics/shared/buttons/minus_in.gif" alt="" name="minusbtn';
//line 85 "last_kommentar.js.html"
output += stash.get(['k', 0, 'id', 0]);
output += '" width="30" height="20" border="0" id="minusbtn';
//line 85 "last_kommentar.js.html"
output += stash.get(['k', 0, 'id', 0]);
output += '" /></a></div>\n			<div id="kommentarbewertungsresult';
//line 86 "last_kommentar.js.html"
output += stash.get(['k', 0, 'id', 0]);
output += '" class="kommentarbewertungsresulttext" style="padding-top:4px; padding-right:6px;" align="center">';
//line 86 "last_kommentar.js.html"
if ((stash.get(['k', 0, 'kommentar_bewertung_result', 0]) > 0)) {
output += '+';
//line 86 "last_kommentar.js.html"
output += stash.get(['k', 0, 'kommentar_bewertung_result', 0]);
}
else {
//line 86 "last_kommentar.js.html"
output += stash.get(['k', 0, 'kommentar_bewertung_result', 0]);
}

output += '</div>\n		</td>\n		<td width="2%"><img src="/pics/shared/t.gif" border="0" height="1" width="1"></td>\n	</tr>\n	<tr>\n		<td colspan="7" height="5"><img src="/pics/shared/t.gif" border="0" height="1" width="1"></td>\n	</tr>\n</table>\n<table cellspacing="0" cellpadding="0" border="0" width="100%" class="list1" id="antwortschreiben';
//line 94 "last_kommentar.js.html"
output += stash.get(['k', 0, 'id', 0]);
output += '" style="display:none">\n	<tr>\n		<td width="21" valign="top" align="left" style="padding-top:4px; padding-bottom:4px;"><div style="padding-left:10px;"><img src="/pics/shared/buttons/antwort_pfeil.gif" width="11" height="23"></div></td>\n		<td width="380"><div style="padding-left:10px;"><textarea class="inputfield" onkeyup="kontrolle(this,\'zeichenuebrig2';
//line 97 "last_kommentar.js.html"
output += stash.get(['k', 0, 'id', 0]);
output += '\')" id="antwort_text_';
//line 97 "last_kommentar.js.html"
output += stash.get(['k', 0, 'id', 0]);
output += '" style="width:335px; height:80px;" wrap="physical"></textarea></div></td>\n		<td valign="bottom" class="contenttext">\n			<div>Noch <strong><span id="zeichenuebrig2';
//line 99 "last_kommentar.js.html"
output += stash.get(['k', 0, 'id', 0]);
output += '">500</span></strong> Zeichen erlaubt </div>\n			<div style="padding-top:6px;"><a href="javascript:__Yur.lastkommentar.hideantworttextbox(';
//line 100 "last_kommentar.js.html"
output += stash.get(['k', 0, 'id', 0]);
output += ')" onmouseout="MM_swapImgRestore()" onmouseover="MM_swapImage(\'abbrechenbtn';
//line 100 "last_kommentar.js.html"
output += stash.get(['k', 0, 'id', 0]);
output += '\',\'\',\'/pics/shared/buttons/abbrechen_act.gif\',1)"><img src="/pics/shared/buttons/abbrechen_in.gif" alt="" name="abbrechenbtn';
//line 100 "last_kommentar.js.html"
output += stash.get(['k', 0, 'id', 0]);
output += '" width="157" height="16" border="0" id="abbrechenbtn';
//line 100 "last_kommentar.js.html"
output += stash.get(['k', 0, 'id', 0]);
output += '" /></a></div>\n			<div style="padding-top:6px;"><a href="javascript:__Yur.lastkommentar.sendantwort(';
//line 101 "last_kommentar.js.html"
output += stash.get(['k', 0, 'id', 0]);
output += ',';
//line 101 "last_kommentar.js.html"
output += stash.get('mid');
output += ')" onmouseout="MM_swapImgRestore()" onmouseover="MM_swapImage(\'postenbtn';
//line 101 "last_kommentar.js.html"
output += stash.get(['k', 0, 'id', 0]);
output += '\',\'\',\'/pics/shared/buttons/kommentar_posten_act.gif\',1)"><img src="/pics/shared/buttons/kommentar_posten_in.gif" alt="" name="postenbtn';
//line 101 "last_kommentar.js.html"
output += stash.get(['k', 0, 'id', 0]);
output += '" width="157" height="17" border="0" id="postenbtn';
//line 101 "last_kommentar.js.html"
output += stash.get(['k', 0, 'id', 0]);
output += '" /></a></div>\n		</td>\n	</tr>\n	<tr>\n		<td colspan="3" height="5"><img src="/pics/shared/t.gif" border="0" height="1" width="1"></td>\n	</tr>\n</table>\n<table cellspacing="0" cellpadding="0" border="0" width="100%" class="list1" id="antworterfolgreich';
//line 108 "last_kommentar.js.html"
output += stash.get(['k', 0, 'id', 0]);
output += '" style="display:none">\n	<tr>\n		<td width="21" valign="top" align="left" style="padding-top:4px; padding-bottom:4px;">\n			<div style="padding-left:10px;"><img src="/pics/shared/buttons/antwort_pfeil.gif" width="11" height="23"></div>\n		</td>\n		<td class="contenttext" style="padding-left:10px;">Antwort erfolgreich gepostet</td>\n	</tr>\n</table>\n\n';
//line 154 "last_kommentar.js.html"

// FOREACH 
(function() {
    var list = stash.get('answerlist');
    list = new Jemplate.Iterator(list);
    var retval = list.get_first();
    var value = retval[0];
    var done = retval[1];
    var oldloop;
    try { oldloop = stash.get('loop') } finally {}
    stash.set('loop', list);
    try {
        while (! done) {
            stash.data['answerobj'] = value;
output += '\n\n';
//line 119 "last_kommentar.js.html"
stash.set('k', stash.get(['answerobj', 0, 'kommentar', 0]));
output += '\n';
//line 120 "last_kommentar.js.html"
stash.set('p', stash.get(['answerobj', 0, 'person', 0]));
output += '\n\n';
//line 153 "last_kommentar.js.html"
if ((stash.get('k') && stash.get('p'))) {
output += '\n<table cellspacing="0" cellpadding="0" border="0" width="100%" class="list1">\n	<tr>\n		<td colspan="8" height="5"><img src="/pics/shared/t.gif" border="0" height="1" width="1"></td>\n	</tr>\n	<tr>\n		<td width="21" valign="top" align="left" style="padding-top:4px; padding-bottom:4px;">\n			<div style="padding-left:10px;"><img src="/pics/shared/buttons/antwort_pfeil.gif" width="11" height="23"></div>\n		</td>\n		<td width="70" valign="top" align="left" style="padding-top:4px; padding-bottom:4px;"><div style="padding-left:5px;"><div style="width:57px; height:57px; background-color:#8C8C8C;"><div style="padding:1px;"><div style="width:55px; height:55px; background-color:#000000" align="center">';
//line 131 "last_kommentar.js.html"
output += stash.get(['p', 0, 'image_kommentar', 0]);
output += '</div></div></div></div></td>\n		<td valign="top">\n			<div style="padding-top:4px;">\n				<div class="contenttext" style="float:left; width:300px;"><strong>';
//line 134 "last_kommentar.js.html"
output += stash.get(['p', 0, 'alias', 0]);
output += ':</strong>&nbsp;(vor ';
//line 134 "last_kommentar.js.html"
output += stash.get(['k', 0, 'time_difference', 0]);
output += ')</div>\n				<div class="contenttext" align="right" style="float:right; width:78px;"><a href="javascript:__Yur.ReportSpamKommentar(';
//line 135 "last_kommentar.js.html"
output += stash.get(['k', 0, 'id', 0]);
output += ')">Report Spam&nbsp;&nbsp;<img src="/pics/shared/pfeil.gif" border="0"></a></div><div style="clear:both"></div>\n				<div class="contenttext">';
//line 136 "last_kommentar.js.html"
output += stash.get(['k', 0, 'text', 0]);
output += '</div>\n			</div>\n		</td>\n		<td width="2%"><img src="/pics/shared/t.gif" border="0" height="1" width="1"></td>\n		<td width="1" align="center" style="background-color:#505050;"><img src="/pics/shared/t.gif" border="0" height="1" width="1"></td>\n		<td width="2%"><img src="/pics/shared/t.gif" border="0" height="1" width="1"></td>\n		<td width="70" class="contenttext" valign="top" style="padding-top:4px;" align="center">\n			<div align="left" style="padding-bottom:5px; width:63px;">Bewerte den<br>Kommentar</div>\n			<div><a href="javascript:__Yur.lastkommentar.BewertungPositiv(';
//line 144 "last_kommentar.js.html"
output += stash.get(['k', 0, 'id', 0]);
output += ')" onmouseout="MM_swapImgRestore()" onmouseover="MM_swapImage(\'plusbtn';
//line 144 "last_kommentar.js.html"
output += stash.get(['k', 0, 'id', 0]);
output += '\',\'\',\'/pics/shared/buttons/plus_act.gif\',1)"><img src="/pics/shared/buttons/plus_in.gif" alt="" name="plusbtn';
//line 144 "last_kommentar.js.html"
output += stash.get(['k', 0, 'id', 0]);
output += '" width="30" height="20" border="0" id="plusbtn';
//line 144 "last_kommentar.js.html"
output += stash.get(['k', 0, 'id', 0]);
output += '" /></a><a href="javascript:__Yur.lastkommentar.BewertungNegativ(';
//line 144 "last_kommentar.js.html"
output += stash.get(['k', 0, 'id', 0]);
output += ')" onmouseout="MM_swapImgRestore()" onmouseover="MM_swapImage(\'minusbtn';
//line 144 "last_kommentar.js.html"
output += stash.get(['k', 0, 'id', 0]);
output += '\',\'\',\'/pics/shared/buttons/minus_act.gif\',1)"><img src="/pics/shared/buttons/minus_in.gif" alt="" name="minusbtn';
//line 144 "last_kommentar.js.html"
output += stash.get(['k', 0, 'id', 0]);
output += '" width="30" height="20" border="0" id="minusbtn';
//line 144 "last_kommentar.js.html"
output += stash.get(['k', 0, 'id', 0]);
output += '" /></a></div>\n			<div id="kommentarbewertungsresult';
//line 145 "last_kommentar.js.html"
output += stash.get(['k', 0, 'id', 0]);
output += '" class="kommentarbewertungsresulttext" style="padding-top:4px; padding-right:6px;" align="center">';
//line 145 "last_kommentar.js.html"
if ((stash.get(['k', 0, 'kommentar_bewertung_result', 0]) > 0)) {
output += '+';
//line 145 "last_kommentar.js.html"
output += stash.get(['k', 0, 'kommentar_bewertung_result', 0]);
}
else {
//line 145 "last_kommentar.js.html"
output += stash.get(['k', 0, 'kommentar_bewertung_result', 0]);
}

output += '</div>\n		</td>\n		<td width="2%"><img src="/pics/shared/t.gif" border="0" height="1" width="1"></td>\n	</tr>\n	<tr>\n		<td colspan="8" height="5"><img src="/pics/shared/t.gif" border="0" height="1" width="1"></td>\n	</tr>\n</table>\n';
}

output += '\n';;
            retval = list.get_next();
            value = retval[0];
            done = retval[1];
        }
    }
    catch(e) {
        throw(context.set_error(e, output));
    }
    stash.set('loop', oldloop);
})();

output += '\n\n';
}
else {
output += '\n<table cellspacing="0" cellpadding="0" border="0" width="100%" class="list1">\n	<tr>\n		<td><div style="padding-top:5px;"><div class="line1"><img src="/pics/shared/t.gif" border="0" height="1" width="1"></div></div></td>\n	</tr>\n	<tr>\n		<td height="25" valign="middle" style="padding-left:10px;" class="contenttext">kein Kommentar vorhanden</td>\n	</tr>\n</table>\n';
}

output += '\n';;
            retval = list.get_next();
            value = retval[0];
            done = retval[1];
        }
    }
    catch(e) {
        throw(context.set_error(e, output));
    }
    stash.set('loop', oldloop);
})();

output += '\n\n';
//line 177 "last_kommentar.js.html"
if ((stash.get('k_counter') == 0)) {
output += '\n<table cellspacing="0" cellpadding="0" border="0" width="100%" class="list1">\n	<tr>\n		<td><div style="padding-top:5px;"><div class="line1"><img src="/pics/shared/t.gif" border="0" height="1" width="1"></div></div></td>\n	</tr>\n	<tr>\n		<td height="25" valign="middle" style="padding-left:10px;" class="contenttext">kein Kommentar vorhanden</td>\n	</tr>\n</table>\n';
}

output += '\n\n\n';
    }
    catch(e) {
        var error = context.set_error(e, output);
        throw(error);
    }

    return output;
}

Jemplate.templateMap['login.js.html'] = function(context) {
    if (! context) throw('Jemplate function called without context\n');
    var stash = context.stash;
    var output = '';

    try {
//line 1 "login.js.html"
stash.set('p', stash.get('model'));
output += '\n				<div style="position:absolute; left:9px; top:9px;" class="text1"><strong>Dein User</strong></div>\n				<div style="position:absolute; left:65px; top:30px; width:124px; height:22px; overflow:hidden;" class="text3"><strong>';
//line 3 "login.js.html"
output += stash.get(['p', 0, 'alias', 0]);
output += '</strong></div>\n				<div style="position:absolute; left:65px; top:48px; width:124px; height:16px; overflow:hidden;" class="text4"><strong>Du hast ';
//line 4 "login.js.html"
output += stash.get(['p', 0, 'shares', 0]);
output += ' Aktie';
//line 4 "login.js.html"
if ((stash.get(['p', 0, 'shares', 0]) != 1)) {
output += 'n';
}

output += '</strong></div>\n				<div style="position:absolute; left:65px; top:76px;" class="text5"><a href="/my">Channel-Admin</a></div>\n				<div style="position:absolute; left:65px; top:63px;" class="text5"><a href="';
//line 6 "login.js.html"
if (stash.get(['p', 0, 'rank', 0])) {
output += '/channel/';
//line 6 "login.js.html"
output += stash.get(['p', 0, 'alias', 0]);
}
else {
output += '/mein_channel';
}

output += '">Mein Channel</a></div>\n				<div style="position:absolute; left:139px; top:10px;" class="text2"><a href="javascript:__Yur.session.logout()">Ausloggen</a></div>\n				<div style="position:absolute; left:9px; top:30px; width:48px; height:58px; background-color:#797979;">\n					<div style="padding-left:1px; padding-top:1px;">\n						<!--table cellpadding="0" cellspacing="0" border="0" bgcolor="#000000"><tr><td width="46" height="56" valign="middle" align="center">';
//line 10 "login.js.html"
output += stash.get(['p', 0, 'image_small', 0]);
output += '</td></tr></table-->\n						';
//line 13 "login.js.html"
if (stash.get(['p', 0, 'image_small', 0])) {
output += '\n						<a href="/channel/';
//line 12 "login.js.html"
output += stash.get(['p', 0, 'alias', 0]);
output += '">';
//line 12 "login.js.html"
output += context.process('image_center_box.js.html', { 'color': '000000', 'width': '46', 'height': '56', 'image': stash.get(['p', 0, 'image_small', 0]) });
output += '</a>\n						';
}

output += '\n					</div>\n				</div>';
    }
    catch(e) {
        var error = context.set_error(e, output);
        throw(error);
    }

    return output;
}

Jemplate.templateMap['mein_yur_change.js.html'] = function(context) {
    if (! context) throw('Jemplate function called without context\n');
    var stash = context.stash;
    var output = '';

    try {
output += '<table cellpadding="0" cellspacing="0" border="0">\n	<tr>\n		<td id="sichtbar" class="header"><div>F&Uuml;R ANDERE SICHTBAR</div></td>\n		<td width="7"><img src="/pics/t.gif" width="1" height="1" border="0" /></td>\n		<td colspan="2" id="daten" class="header" width="468">PERS&Ouml;NLICHE DATEN</td>\n	</tr>\n	<tr>\n		<td class="chkbox"><div><input type="checkbox" checked="checked" id="aliasbox" disabled="disabled"></div></td>\n		<td width="7">&nbsp;</td>\n		<td class="persdaten">\n			<table class="eintrag hell" cellpadding="0" cellspacing="0" border="0" width="100%">\n				<tr>\n					<td valign="middle" class="feldname"><div>Username';
output += ':</div></td>\n					<td valign="middle">';
//line 14 "mein_yur_change.js.html"
output += stash.get(['person', 0, 'alias', 0]);
output += '</td>\n				</tr>\n			</table>\n		</td>\n		<td rowspan="11" valign="top" style="padding-left:3px; padding-top:1px;">\n			<div class="avatarContainer" align="center">\n				';
//line 20 "mein_yur_change.js.html"
if ((stash.get(['person', 0, 'image', 0]))) {
//line 20 "mein_yur_change.js.html"
stash.set('img', stash.get(['person', 0, 'image_', 0, 'make', [ 100, 60 ]]));
//line 20 "mein_yur_change.js.html"
stash.set('min_height', stash.get(['img', 0, 'real_height', 0]) + 6);
}
else {
//line 20 "mein_yur_change.js.html"
stash.set('min_height', 66);
}

output += '\n				<div class="img">';
//line 21 "mein_yur_change.js.html"
if ((stash.get(['person', 0, 'image', 0]))) {
//line 21 "mein_yur_change.js.html"
output += stash.get(['img', 0, 'as_element', [], 'as_HTML', 0]);
}
else {
output += '<img src="/pics/avatar.gif" width="100" height="60">';
}

output += '</div>\n			</div>\n			<div id="beschreibungContainer">\n				<textarea name="beschreibung" id="beschreibung" rows="5" class="beschreibung';
//line 24 "mein_yur_change.js.html"
if ((stash.get(['fehler', 0, 'beschreibung', 0]))) {
output += ' fehler';
}

output += '">';
//line 24 "mein_yur_change.js.html"
output += stash.get(['stats', 0, 'param_for_textarea', [ 'beschreibung' ]]);
output += '</textarea>\n			</div>\n		</td>\n	</tr>									\n	<tr>\n		<td class="chkbox"><div><input type="checkbox" id="vornamebox"></div></td>\n		<td width="7">&nbsp;</td>\n		<td class="persdaten">\n			<table class="eintrag dunkel" cellpadding="0" cellspacing="0" border="0" width="100%">\n				<tr>\n					<td valign="middle" class="feldname"><div>';
//line 34 "mein_yur_change.js.html"
output += context.include('fieldname', { 'name': 'vorname' });
output += '*:</div></td>\n					<td valign="middle">';
//line 35 "mein_yur_change.js.html"
output += context.include('input', { 'name': 'vorname', 'class': 'textfeldLang' });
output += '</td>\n				</tr>\n			</table>\n		</td>\n	</tr>\n	<tr>\n		<td class="chkbox"><div><input type="checkbox" id="namebox"></div></td>\n		<td width="7">&nbsp;</td>\n		<td class="persdaten">\n			<table class="eintrag hell" cellpadding="0" cellspacing="0" border="0" width="100%">\n				<tr>\n					<td valign="middle" class="feldname"><div>';
//line 46 "mein_yur_change.js.html"
output += context.include('fieldname', { 'name': 'name' });
output += '*:</div></td>\n					<td valign="middle">';
//line 47 "mein_yur_change.js.html"
output += context.include('input', { 'name': 'name', 'class': 'textfeldLang' });
output += '</td>\n				</tr>\n			</table>\n		</td>\n	</tr>\n	<tr>\n		<td class="chkbox"><div><input type="checkbox" id="strassebox"></div></td>\n		<td width="7">&nbsp;</td>\n		<td class="persdaten">\n			<table class="eintrag dunkel" cellpadding="0" cellspacing="0" border="0" width="100%">\n				<tr>\n					<td valign="middle" class="feldname"><div>';
//line 58 "mein_yur_change.js.html"
output += context.include('fieldname', { 'name': 'strasse' });
output += '*:</div></td>\n					<td valign="middle">';
//line 59 "mein_yur_change.js.html"
output += context.include('input', { 'name': 'strasse', 'class': 'textfeldLang' });
output += '</td>\n				</tr>\n			</table>\n		</td>\n	</tr>\n	<tr>\n		<td class="chkbox"><div><input type="checkbox" id="strassebox"></div></td>\n		<td width="7">&nbsp;</td>\n		<td class="persdaten">\n			<table class="eintrag hell" cellpadding="0" cellspacing="0" border="0" width="100%">\n				<tr>\n					<td valign="middle" class="feldname"><div>';
//line 70 "mein_yur_change.js.html"
output += context.include('fieldname', { 'name': 'plz' });
output += '/';
//line 70 "mein_yur_change.js.html"
output += context.include('fieldname', { 'name': 'ort' });
output += '*:&nbsp;</div></td>\n					<td valign="middle">\n						<table border="0" cellpadding="0" cellspacing="0" width="100%">\n							<tr>\n								<td valign="middle">';
//line 74 "mein_yur_change.js.html"
output += context.include('input', { 'name': 'plz', 'class': 'textfeldPLZ' });
output += '</td>\n								<td align="right" valign="middle">';
//line 75 "mein_yur_change.js.html"
output += context.include('input', { 'name': 'ort', 'class': 'textfeldOrt' });
output += '</td>\n							</tr>\n						</table>\n					</td>\n				</tr>\n			</table>\n		</td>\n	</tr>\n	<tr>\n		<td class="chkbox"><div><input type="checkbox" id="emailbox"></div></td>\n		<td width="7">&nbsp;</td>\n		<td class="persdaten">\n			<table class="eintrag dunkel" cellpadding="0" cellspacing="0" border="0" width="100%">\n				<tr>\n					<td valign="middle" class="feldname"><div>';
//line 89 "mein_yur_change.js.html"
output += context.include('fieldname', { 'name': 'email' });
output += '*:';
//line 89 "mein_yur_change.js.html"
if ((! stash.get(['person', 0, 'email_confirmed', 0]) && stash.get(['person', 0, 'email', 0]))) {
output += '<span class="notConfirmed"><br>(unbest&auml;tigt)</span>';
}

output += '</div></td>\n					<td valign="middle">';
//line 90 "mein_yur_change.js.html"
output += context.include('input', { 'name': 'email', 'class': 'textfeldLang' });
output += '</td>\n				</tr>\n			</table>\n		</td>\n	</tr>\n	<tr>\n		<td class="chkbox"><div><input type="checkbox" id="handybox"></div></td>\n		<td width="7">&nbsp;</td>\n		<td class="persdaten">\n			<table class="eintrag hell" cellpadding="0" cellspacing="0" border="0" width="100%">\n				<tr>\n					<td valign="middle" class="feldname"><div>';
//line 101 "mein_yur_change.js.html"
output += context.include('fieldname', { 'name': 'handy' });
output += ':';
//line 101 "mein_yur_change.js.html"
if ((! stash.get(['person', 0, 'handy_confirmed', 0]) && stash.get(['person', 0, 'handy', 0]))) {
output += '<span class="notConfirmed"><br>(unbest&auml;tigt)</span>';
}

output += '</div></td>\n					<td valign="middle">';
//line 102 "mein_yur_change.js.html"
output += context.include('input', { 'name': 'handy', 'class': 'textfeldLang' });
output += '</td>\n				</tr>\n			</table>\n		</td>\n	</tr>\n	<tr>\n		<td class="chkbox"><div><input type="checkbox"  disabled="disabled" checked="checked"></div></td>\n		<td width="7">&nbsp;</td>\n		<td class="persdaten">\n			<table class="eintrag dunkel" cellpadding="0" cellspacing="0" border="0" width="100%">\n				<tr>\n					<td valign="middle" class="feldname"><div>Mitglied seit:</div></td>\n					<td valign="middle">';
//line 114 "mein_yur_change.js.html"
output += stash.get(['tool', 0, 'as_datetime_object', [ stash.get(['person', 0, 'registriert_seit', 0]) ], 'german', 0]);
output += '</td>\n				</tr>\n			</table>\n		</td>\n	</tr>\n	<tr>\n		<td class="chkbox"><div><input type="checkbox"  disabled="disabled"  checked="checked"></div></td>\n		<td width="7">&nbsp;</td>\n		<td class="persdaten">\n			<table class="eintrag hell" cellpadding="0" cellspacing="0" border="0" width="100%">\n				<tr>\n					<td valign="middle" class="feldname"><div>Ranking</div></td>\n					<td valign="middle">';
//line 126 "mein_yur_change.js.html"
if ((stash.get(['person', 0, 'rank', 0]))) {
output += 'Platz ';
//line 126 "mein_yur_change.js.html"
output += stash.get(['person', 0, 'rank', 0]);
}
else {
output += 'Du nimmst erst am Ranking teil, wenn du eine On-Air-Zeit und eine Bewertung hast.';
}

output += '</td>\n				</tr>\n			</table>\n		</td>\n	</tr>\n	<tr>\n		<td class="chkbox"><div><input type="checkbox"  disabled="disabled"  checked="checked"></div></td>\n		<td width="7">&nbsp;</td>\n		<td class="persdaten">\n			<table class="eintrag dunkel" cellpadding="0" cellspacing="0" border="0" width="100%">\n				<tr>\n					<td valign="middle" class="feldname"><div>Anzahl Videos:</div></td>\n					<td valign="middle">';
//line 138 "mein_yur_change.js.html"
output += stash.get(['person', 0, 'anzahl_videos', 0]);
output += '</td>\n				</tr>\n			</table>\n		</td>\n	</tr>\n	<tr>\n		<td class="chkbox"><div><input type="checkbox" disabled="disabled"  checked="checked"></div></td>\n		<td width="7">&nbsp;</td>\n		<td class="persdaten">\n			<table class="eintrag hell" cellpadding="0" cellspacing="0" border="0" width="100%">\n				<tr>\n					<td valign="middle" class="feldname"><div>Gesamte Laufzeit:</div></td>\n					<td valign="middle">';
//line 150 "mein_yur_change.js.html"
output += stash.get(['person', 0, 'airtime_seconds', 0]);
output += ' Sekunde';
//line 150 "mein_yur_change.js.html"
if ((stash.get(['person', 0, 'airtime_seconds', 0]) != 1)) {
output += 'n';
}

output += '</td>\n				</tr>\n			</table>\n		</td>\n	</tr>\n</table>\n\n';
    }
    catch(e) {
        var error = context.set_error(e, output);
        throw(error);
    }

    return output;
}

Jemplate.templateMap['meinyurtv_edit.js.html'] = function(context) {
    if (! context) throw('Jemplate function called without context\n');
    var stash = context.stash;
    var output = '';

    try {
output += '<div id="MeinYURtv">\n<div id="change">\n\n<table cellpadding="0" cellspacing="0" border="0" id="EditTable">\n	<tr>\n		<td class="header" colspan="2"><div>PERS&Ouml;NLICHE DATEN</div></td>\n		<td>&nbsp;</td>\n		<td class="header" colspan="2"><div>&Ouml;FFENTLICH SICHTBAR</div></td>\n	</tr>\n	<tr class="hell">\n		<td class="name"><div>Usename</div></td>\n		<td class="wert"><% person.alias %></td>\n		<td class="trenner">&nbsp;</td>\n		<td class="checkbox"><input type="checkbox" id="aliasbox"></td>\n		<td class="pic" rowspan="18">\n			<div class="avatarContainer">\n				<% IF (person.image) %><% img = person.image_.make(160,119) %><% min_height = img.real_height + 6 %><% ELSE %><% min_height = 119 %><% END %>\n				<div class="img"><% IF (person.image) %><% img.as_element().as_HTML %><% ELSE %><img src="/pics/avatar.gif" width="160" height="119"><% END %></div>\n			</div>\n			<div id="EditbeschreibungContainer">\n				<textarea name="beschreibung" id="beschreibung" rows="5" class="beschreibung<% IF (fehler.beschreibung) %> fehler<% END %>"><% stats.param_for_textarea(\'beschreibung\') %></textarea>\n			</div>\n		</td>\n	</tr>\n	\n	<tr class="dunkel">\n		<td class="name"><div>Geschlecht</div></td>\n		<td class="wert">\n			<select name="anrede" id="anrede" class="<% IF (fehler.anrede) %>fehler<% ELSE %>selectBoxLang<% END %>">\n				<option value=""<% IF (stats.param(\'anrede\') == \'\') %> selected="selected"<% END %>>W&auml;hle ....</option>\n				<% stats.print_option(\'anrede\', \'Herr\', \'M&auml;nnlich\') %>\n				<% stats.print_option(\'anrede\', \'Frau\', \'Weiblich\') %>\n			</select>\n		</td>\n		<td class="trenner">&nbsp;</td>\n		<td class="checkbox"><input type="checkbox" id="anredebox"></td>\n	</tr>\n	\n	<tr class="dunkel">\n		<td class="name"><div><% INCLUDE fieldname	name="vorname" %>*:</div></td>\n		<td class="wert"><% INCLUDE input name=\'vorname\' class=\'textfeldLang\' %></td>\n		<td class="trenner">&nbsp;</td>\n		<td class="checkbox"><input type="checkbox" id="vornamebox"></td>\n	</tr>\n	\n	<tr class="dunkel">\n		<td class="name"><div><% INCLUDE fieldname	name="name" %>*:</div></td>\n		<td class="wert"><% INCLUDE input name=\'name\' class=\'textfeldLang\' %></td>\n		<td class="trenner">&nbsp;</td>\n		<td class="checkbox"><input type="checkbox" id="namebox"></td>\n	</tr>\n	\n	<tr class="dunkel">\n		<td class="name"><div><% INCLUDE fieldname	name="strasse" %>*:</div></td>\n		<td class="wert"><% INCLUDE input name=\'strasse\' class=\'textfeldLang\' %></td>\n		<td class="trenner">&nbsp;</td>\n		<td class="checkbox"><input type="checkbox" id="strassebox"></td>\n	</tr>\n	\n	<tr class="dunkel">\n		<td class="name"><div><% INCLUDE fieldname	name="plz" %>/<% INCLUDE fieldname	name="ort" %>*:</div></td>\n		<td class="wert">\n			<table border="0" cellpadding="0" cellspacing="0" width="100%">\n				<tr>\n					<td valign="middle"><% INCLUDE input name=\'plz\' class=\'textfeldPLZ\' %></td>\n					<td align="right" valign="middle"><% INCLUDE input name=\'ort\' class=\'textfeldOrt\' %></td>\n				</tr>\n			</table>\n		</td>\n		<td class="trenner">&nbsp;</td>\n		<td class="checkbox"><input type="checkbox" id="plzbox"></td>\n	</tr>\n	\n	<tr class="dunkel">\n		<td class="name"><div><% INCLUDE fieldname	name="geburtstag" %>*:</div></td>\n		<td class="wert"><% INCLUDE input name=\'geburtstag\' class=\'textfeldLang\' %></td>\n		<td class="trenner">&nbsp;</td>\n		<td class="checkbox"><input type="checkbox" id="geburtstagbox"></td>\n	</tr>\n	\n	<tr class="dunkel">\n		<td class="name"><div><% INCLUDE fieldname	name="email" %>*:</div></td>\n		<td class="wert"><% INCLUDE input name=\'email\' class=\'textfeldLang\' %></td>\n		<td class="trenner">&nbsp;</td>\n		<td class="checkbox"><input type="checkbox" id="emailbox"></td>\n	</tr>\n\n	<tr class="dunkel">\n		<td class="name"><div><% INCLUDE fieldname	name="handy" %>*:</div></td>\n		<td class="wert"><% INCLUDE input name=\'handy\' class=\'textfeldLang\' %></td>\n		<td class="trenner">&nbsp;</td>\n		<td class="checkbox"><input type="checkbox" id="handybox"></td>\n	</tr>	\n\n	<tr class="dunkel">\n		<td class="name"><div><% INCLUDE fieldname	name="password" %>*:</div></td>\n		<td class="wert"><% INCLUDE input name=\'password\' class=\'textfeldLang\' input_type=\'password\' empty=\'1\' %></td>\n		<td class="trenner">&nbsp;</td>\n		<td class="checkbox"><input type="checkbox" id="passwordbox" disabled="disabled"></td>\n	</tr>		\n\n	<tr class="dunkel">\n		<td class="name"><div><% INCLUDE fieldname	name="wiederholung" %>*:</div></td>\n		<td class="wert"><% INCLUDE input name=\'wiederholung\' class=\'textfeldLang\' input_type=\'password\' empty=\'1\' %></td>\n		<td class="trenner">&nbsp;</td>\n		<td class="checkbox"><input type="checkbox" id="wiederholungbox" disabled="disabled"></td>\n	</tr>\n\n	<tr class="dunkel">\n		<td class="name"><div><% INCLUDE fieldname	name="passwd" %>*:</div></td>\n		<td class="wert"><% INCLUDE input name=\'passwd\' class=\'textfeldLang\' input_type=\'password\' empty=\'1\' %></td>\n		<td class="trenner">&nbsp;</td>\n		<td class="checkbox"><input type="checkbox" id="passwdbox" disabled="disabled"></td>\n	</tr>	\n	\n	<tr class="dunkel">\n		<td class="name"><div>Mitglied seid:</div></td>\n		<td class="wert"><% tool.as_datetime_object(person.registriert_seit).german %></td>\n		<td class="trenner">&nbsp;</td>\n		<td class="checkbox"><input type="checkbox" disabled="disabled"></td>\n	</tr>\n	\n	<tr class="dunkel">\n		<td class="name"><div>Ranking:</div></td>\n		<td class="wert"><% IF (person.rank) %>Platz <% person.rank %><% ELSE %>Du nimmst erst am Ranking teil, wenn du eine On-Air-Zeit und eine Bewertung hast.<% END %></td>\n		<td class="trenner">&nbsp;</td>\n		<td class="checkbox"><input type="checkbox" disabled="disabled"></td>\n	</tr>	\n\n	<tr class="dunkel">\n		<td class="name"><div>Anzahl Videos:</div></td>\n		<td class="wert"><% person.anzahl_videos %></td>\n		<td class="trenner">&nbsp;</td>\n		<td class="checkbox"><input type="checkbox" disabled="disabled"></td>\n	</tr>	\n	\n	<tr class="dunkel">\n		<td class="name"><div>Gesamte Laufzeit:</div></td>\n		<td class="wert"><% person.airtime_seconds %> Sekunde<% IF (person.airtime_seconds != 1) %>n<% END %></td>\n		<td class="trenner">&nbsp;</td>\n		<td class="checkbox"><input type="checkbox" disabled="disabled"></td>\n	</tr>		\n\n	<tr class="dunkel">\n		<td class="name" colspan="2"><div><% INCLUDE fieldname	name="image" %>:</div></td>\n		<td class="trenner">&nbsp;</td>\n		<td class="checkbox"><input type="checkbox" disabled="disabled"></td>\n	</tr>	\n	\n	<tr class="dunkel">\n		<td class="wert" colspan="2"><% INCLUDE input name=\'image\' class=\'fileBox\' input_type=\'file\' empty=\'1\' %></td>\n		<td class="trenner">&nbsp;</td>\n		<td class="checkbox">&nbsp;</td>\n	</tr>		\n			\n</table>\n\n</div>\n</div>';
    }
    catch(e) {
        var error = context.set_error(e, output);
        throw(error);
    }

    return output;
}

Jemplate.templateMap['meinyurtv_movies.js.html'] = function(context) {
    if (! context) throw('Jemplate function called without context\n');
    var stash = context.stash;
    var output = '';

    try {
//line 1 "meinyurtv_movies.js.html"
stash.set('movies', stash.get(['model', 0, 'data', 0, 'list', 0]));
output += '\n';
//line 2 "meinyurtv_movies.js.html"
stash.set('person', stash.get(['model', 0, 'data', 0, 'person', 0]));
output += '\n';
//line 3 "meinyurtv_movies.js.html"
stash.set('pagination', stash.get(['model', 0, 'data', 0, 'pagination', 0]));
output += '\n';
//line 4 "meinyurtv_movies.js.html"
stash.set('archiv', stash.get(['model', 0, 'data', 0, 'archiv', 0]));
output += '\n';
//line 5 "meinyurtv_movies.js.html"
stash.set('owner', stash.get(['model', 0, 'data', 0, 'owner', 0]));
output += '\n\n';
//line 300 "meinyurtv_movies.js.html"
if ((stash.get(['model', 0, 'data', 0, 'anzahl_videos', 0]) > 0)) {
output += '\n	<div id="Container" style="position:relative">\n		\n	<div id="Blende"></div>\n	\n	<div id="messageBox">\n		<div id="oben"><img src="pics/t.gif" border="0" height="1" width="1"></div>\n		<div id="inhalt">\n			<div id="messageText"></div>\n			<div id="messageBtn"><input type="button" value="OK" onclick="__Yur.meinyurtv.hideMessage()"></div>\n			<div id="messageBtnReload"><input type="button" value="OK" onclick="__Yur.meinyurtv.hideMessageWithReload()"></div>\n		</div>\n		<div id="unten"><img src="pics/t.gif" border="0" height="1" width="1"></div>\n	</div>\n	\n	\n	\n	<div id="MeineClips"><div><strong>MEINE CLIPS</strong></div></div>\n	<div><img src="/pics/t.gif" width="1" height="1" border="0" /></div>\n	<table cellspacing="0" cellpadding="0" border="0" id="movies">\n		<tr>\n			<th class="pfeilspalte">&nbsp;</th>\n			<th width="30">Nr</th>\n			<th width="225">Name</th>\n			<th width="100">eingestellt am</th>\n			<th width="115">Laufzeit</th>\n			<th width="100">bisher gesendet</th>\n			<th width="100">erreichte Punkte</th>\n			<th class="punktespalte"><div>Wert in Aktien</div></th>\n		</tr>\n\n	';
//line 38 "meinyurtv_movies.js.html"
stash.set('index', stash.get(['model', 0, 'data', 0, 'pagination', 0, 'first_entry_on_page', 0]));
output += '\n	';
//line 39 "meinyurtv_movies.js.html"
stash.set('ges_duration', 0);
output += '\n	';
//line 40 "meinyurtv_movies.js.html"
stash.set('ges_airtime_seconds', 0);
output += '\n	';
//line 41 "meinyurtv_movies.js.html"
stash.set('ges_stock_points', 0);
output += '\n	';
//line 269 "meinyurtv_movies.js.html"

// FOREACH 
(function() {
    var list = stash.get('movies');
    list = new Jemplate.Iterator(list);
    var retval = list.get_first();
    var value = retval[0];
    var done = retval[1];
    var oldloop;
    try { oldloop = stash.get('loop') } finally {}
    stash.set('loop', list);
    try {
        while (! done) {
            stash.data['m'] = value;
output += '\n		';
//line 43 "meinyurtv_movies.js.html"
stash.set('ges_duration', stash.get('ges_duration') + stash.get(['m', 0, 'duration', 0]) * 1);
output += '\n		';
//line 44 "meinyurtv_movies.js.html"
stash.set('ges_airtime_seconds', stash.get('ges_airtime_seconds') + stash.get(['m', 0, 'total_airtime', 0]) * 1);
output += '\n		';
//line 48 "meinyurtv_movies.js.html"
if ((stash.get(['m', 0, 'stock_points', 0]) != stash.get('null'))) {
output += '\n			';
//line 46 "meinyurtv_movies.js.html"
stash.set('ges_stock_points', stash.get('ges_stock_points') + stash.get(['m', 0, 'stock_points', 0]) * 1);
output += '\n			';
//line 47 "meinyurtv_movies.js.html"
stash.set('ges_stock_points_aktien', stash.get(['m', 0, 'stock_points', 0]) / 100 / stash.get(['model', 0, 'data', 0, 'AktienPoints_Punkte_Pro_Aktie', 0]));
output += '\n		';
}

output += '	\n		<tr id="movie';
//line 49 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += '" class="';
//line 49 "meinyurtv_movies.js.html"
if ((stash.get(['m', 0, 'status', 0]) == 1 || stash.get(['m', 0, 'status', 0]) == 2)) {
output += 'detailsclose';
}
else {
output += 'hide';
}

output += ' cursor" onclick="toogledetails(\'';
//line 49 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += '\');">\n			<td class="border_left border_bottom pfeilspalte" align="center"><img class="close cursor" src="/pics/meinyurtv/pfeil_rechts.gif" border="0" ><img class="open cursor" src="/pics/meinyurtv/pfeil_unten.gif" border="0"></td>\n			<td width="30" class="border_bottom tdtext">';
//line 51 "meinyurtv_movies.js.html"
output += stash.get('index');
output += '</td>\n			<td width="225" class="border_bottom tdtext movietitle"><div>';
//line 52 "meinyurtv_movies.js.html"
if ((stash.get(['m', 0, 'title', 0]))) {
//line 52 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'title', 0]);
}
else {
output += '&nbsp;';
}

output += '</div></td>\n			<td width="100" class="border_bottom tdtext">';
//line 53 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'upload_time_german', 0]);
output += '</td>\n			<td width="115" class="border_bottom tdtext">';
//line 54 "meinyurtv_movies.js.html"
output += stash.get(['tool', 0, 'format_hours_time_period', [ stash.get(['m', 0, 'duration', 0]) ]]);
output += '</td>\n			<td width="100" class="border_bottom tdtext">';
//line 55 "meinyurtv_movies.js.html"
output += stash.get(['tool', 0, 'format_hours_time_period', [ stash.get(['m', 0, 'total_airtime', 0]) ]]);
output += '</td>\n			<td width="100" class="border_bottom tdtext" align="center">';
//line 56 "meinyurtv_movies.js.html"
if ((stash.get(['m', 0, 'stock_points', 0]) == stash.get('null'))) {
output += '0';
}
else {
//line 56 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'stock_points', 0]) / 100;
}

output += '</td>\n			<td class="border_right border_bottom punktespalte tdtext" align="right"><div>';
//line 57 "meinyurtv_movies.js.html"
if ((stash.get(['m', 0, 'stock_points', 0]) == stash.get('null'))) {
output += '0';
}
else {
//line 57 "meinyurtv_movies.js.html"
output += stash.get(['tool', 0, 'format_wert_in_aktien', [ stash.get('ges_stock_points_aktien') ]]);
}

output += '</div></td>\n		</tr>\n		<tr id="moviein';
//line 59 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += '" class="';
//line 59 "meinyurtv_movies.js.html"
if ((stash.get(['m', 0, 'status', 0]) == 1 || stash.get(['m', 0, 'status', 0]) == 2)) {
output += 'hide';
}
else {
output += 'detailsinactiv';
}

output += ' tdtext">\n			<td class="border_left border_bottom tdtext" align="center"> <img src="/pics/meinyurtv/pfeil_inactiv.gif" border="0"></td>\n			<td class="border_bottom tdtext">';
//line 61 "meinyurtv_movies.js.html"
output += stash.get('index');
output += '</td>\n			<td class="border_bottom movietitle tdtext"><div>';
//line 62 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'title', 0]);
output += '</div></td>\n			<td colspan="3" class="border_bottom clipinactiv tdtext">\n				\n				<table cellpadding="0" cellspacing="0" border="0">\n				<tr valign="middle">	\n				<td class="reason"><strong>Clip wurde deaktiviert!</strong></td>\n				<td width="8">&nbsp;</td>\n				';
//line 84 "meinyurtv_movies.js.html"
if ((stash.get(['m', 0, 'status', 0]) != 1 && stash.get(['m', 0, 'status', 0]) != 20)) {
output += '\n					<!--a href="javascript:__Yur.meinyurtv.statusMessage(\'';
//line 70 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += '\')">warum?</a-->\n				<td>\n					<div id="warum';
//line 72 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += '" class="btn1inactiv">\n						<table border="0" cellpadding="0" cellspacing="0">\n							<tr>\n								<td onmousemove="switchClass(\'warum';
//line 75 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += '\',\'btn1activ\')" onmouseout="switchClass(\'warum';
//line 75 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += '\',\'btn1inactiv\')" onclick="__Yur.meinyurtv.statusMessage(\'';
//line 75 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += '\')" class="left"></td>\n								<td onmousemove="switchClass(\'warum';
//line 76 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += '\',\'btn1activ\')" onmouseout="switchClass(\'warum';
//line 76 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += '\',\'btn1inactiv\')" onclick="__Yur.meinyurtv.statusMessage(\'';
//line 76 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += '\')" class="mitte"><div>warum?</div></td>\n								<!--td onmousemove="switchClass(\'warum';
//line 77 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += '\',\'btn1activ\')" onmouseout="switchClass(\'warum';
//line 77 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += '\',\'btn1inactiv\')" onclick="__Yur.meinyurtv.statusMessage(\'';
//line 77 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += '\')" class="right"></td-->\n								<td class="leer"></td>\n							</tr>\n						</table>\n					</div>\n				</td>\n				\n				';
}

output += '\n				';
//line 99 "meinyurtv_movies.js.html"
if ((stash.get(['m', 0, 'status', 0]) == 1 || stash.get(['m', 0, 'status', 0]) == 20)) {
output += '\n					<!--a href="javascript:__Yur.meinyurtv.activateClip(';
//line 86 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += ')">aktivieren</a-->\n				<td>\n					<div id="aktivieren';
//line 88 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += '" class="btn1inactiv">\n						<table border="0" cellpadding="0" cellspacing="0">\n							<tr>\n								<td onmousemove="switchClass(\'aktivieren';
//line 91 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += '\',\'btn1activ\')" onmouseout="switchClass(\'aktivieren';
//line 91 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += '\',\'btn1inactiv\')" onclick="__Yur.meinyurtv.activateClip(\'';
//line 91 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += '\')" class="left"></td>\n								<td onmousemove="switchClass(\'aktivieren';
//line 92 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += '\',\'btn1activ\')" onmouseout="switchClass(\'aktivieren';
//line 92 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += '\',\'btn1inactiv\')" onclick="__Yur.meinyurtv.activateClip(\'';
//line 92 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += '\')" class="mitte"><div>aktivieren</div></td>\n								<!--td onmousemove="switchClass(\'aktivieren';
//line 93 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += '\',\'btn1activ\')" onmouseout="switchClass(\'aktivieren';
//line 93 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += '\',\'btn1inactiv\')" onclick="__Yur.meinyurtv.activateClip(\'';
//line 93 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += '\')" class="right"></td-->\n								<td class="leer"></td>\n							</tr>\n						</table>\n					</div>\n				</td>\n				';
}

output += '\n				';
//line 115 "meinyurtv_movies.js.html"
if (((stash.get(['m', 0, 'status', 0]) == 1 || stash.get(['m', 0, 'status', 0]) == 20 || stash.get(['m', 0, 'status', 0]) == 150) && stash.get(['m', 0, 'archiv', 0]) != 1)) {
output += '\n					<!--a href="javascript:__Yur.meinyurtv.ClipToArchiv(';
//line 101 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += ')">Clip ins Archiv</a-->\n				<td>\n					<div id="Archiv';
//line 103 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += '" class="btn1inactiv">\n						<table border="0" cellpadding="0" cellspacing="0">\n							<tr>\n								<td class="trenner"></td>\n								<td class="leer"></td>\n								<!--td onmousemove="switchClass(\'Archiv';
//line 108 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += '\',\'btn1activ\')" onmouseout="switchClass(\'Archiv';
//line 108 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += '\',\'btn1inactiv\')" onclick="__Yur.meinyurtv.ClipToArchiv(\'';
//line 108 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += '\')" class="left"></td-->\n								<td onmousemove="switchClass(\'Archiv';
//line 109 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += '\',\'btn1activ\')" onmouseout="switchClass(\'Archiv';
//line 109 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += '\',\'btn1inactiv\')" onclick="__Yur.meinyurtv.ClipToArchiv(\'';
//line 109 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += '\')" class="mitte"><div>ins Archiv</div></td>\n								<td onmousemove="switchClass(\'Archiv';
//line 110 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += '\',\'btn1activ\')" onmouseout="switchClass(\'Archiv';
//line 110 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += '\',\'btn1inactiv\')" onclick="__Yur.meinyurtv.ClipToArchiv(\'';
//line 110 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += '\')" class="right"></td>\n							</tr>\n						</table>\n					</div>\n					</td>\n				';
}

output += '\n				';
//line 132 "meinyurtv_movies.js.html"
if (((stash.get(['m', 0, 'status', 0]) == 1 || stash.get(['m', 0, 'status', 0]) == 20 || stash.get(['m', 0, 'status', 0]) == 150) && stash.get(['m', 0, 'archiv', 0]) == 1)) {
output += '\n					<!--a href="javascript:__Yur.meinyurtv.ClipToList(';
//line 117 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += ')">Clip zur Normalansicht</a-->\n				<td>\n					<div id="Normalansicht';
//line 119 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += '" class="btn1inactiv">\n						<table border="0" cellpadding="0" cellspacing="0">\n							<tr>\n								<td class="trenner"></td>\n								<td class="leer"></td>\n								<!--td onmousemove="switchClass(\'Normalansicht';
//line 124 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += '\',\'btn1activ\')" onmouseout="switchClass(\'Normalansicht';
//line 124 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += '\',\'btn1inactiv\')" onclick="__Yur.meinyurtv.ClipToList(\'';
//line 124 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += '\')" class="left"></td-->\n								<td onmousemove="switchClass(\'Normalansicht';
//line 125 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += '\',\'btn1activ\')" onmouseout="switchClass(\'Normalansicht';
//line 125 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += '\',\'btn1inactiv\')" onclick="__Yur.meinyurtv.ClipToList(\'';
//line 125 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += '\')" class="mitte"><div>zur Normalansicht</div></td>\n								<td onmousemove="switchClass(\'Normalansicht';
//line 126 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += '\',\'btn1activ\')" onmouseout="switchClass(\'Normalansicht';
//line 126 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += '\',\'btn1inactiv\')" onclick="__Yur.meinyurtv.ClipToList(\'';
//line 126 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += '\')" class="right"></td>\n								\n							</tr>\n						</table>\n					</div>\n					</td>\n				';
}

output += '\n				</tr>\n				</table>\n			</td>\n			<td class="border_bottom tdtext" align="center">';
//line 136 "meinyurtv_movies.js.html"
if ((stash.get(['m', 0, 'stock_points', 0]) == stash.get('null'))) {
output += '0';
}
else {
//line 136 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'stock_points', 0]) / 100;
}

output += '</td>\n			<td class="border_right border_bottom punktespalte tdtext" align="right"><div>';
//line 137 "meinyurtv_movies.js.html"
if ((stash.get(['m', 0, 'stock_points', 0]) == stash.get('null'))) {
output += '0';
}
else {
//line 137 "meinyurtv_movies.js.html"
output += stash.get(['tool', 0, 'format_wert_in_aktien', [ stash.get('ges_stock_points_aktien') ]]);
}

output += '</div></td>\n		</tr>\n		<tr id="details';
//line 139 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += '" style="display:none" class="tdtext">\n			<td colspan="8" align="center" style="background-color:#B2B2B2;">\n\n				<div class="detailsBox">\n					<div class="movieBox">\n						<div class="clip">\n						<object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" codebase="http://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=8,0,0,0" width="240" height="215" id="flv_thumb_player" align="middle">\n							<param name="allowScriptAccess" value="sameDomain" />\n							<param name="movie"\n							value="/flv_thumb_player2.swf?video_url=';
//line 148 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'path', 0]);
output += '/thumb.flv" /><param name="quality" value="high" /><param name="bgcolor" value="#ffffff" />\n							<embed\n							src="/flv_thumb_player2.swf?video_url=';
//line 150 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'path', 0]);
output += '/thumb.flv" quality="high" bgcolor="#ffffff" width="240" height="180" name="flv_thumb_player" align="middle" allowScriptAccess="sameDomain" type="application/x-shockwave-flash" pluginspage="http://www.macromedia.com/go/getflashplayer" />\n						</object>\n						\n						</div>\n						<div class="info">\n							<table cellpadding="0" cellspacing="0" border="0">\n								<tr>\n									<td colspan="2" class="big"><div id="titleBox"><strong>';
//line 157 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'title', 0]);
output += '</strong></div></td>\n								</tr>\n								<tr>\n									<td width="170" class="abstand" style="vertical-align:top;">Beschreibung:</td><td class="beschreibungstext"><div id="beschreibungsBox"><strong>';
//line 160 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'description', 0]);
output += '</strong></div></td>\n								</tr>\n								<tr>\n									<td class="abstand">Zuletzt gesendet:</td><td><strong>';
//line 163 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'last_send_by_movie', 0]);
output += '</strong></td>\n								</tr>\n								<tr>	\n									<td class="abstand">Punkte der letzten Sendezeit:</td><td><strong>';
//line 166 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'last_stock_points_by_movie', 0]) / 100;
output += '</strong></td>\n								</tr>\n								<tr>\n									<td class="abstand">Maximal erreichte Punkte:</td><td><strong>';
//line 169 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'highest_stock_points_by_movie', 0]) / 100;
output += '</strong></td>\n								</tr>\n								<tr>\n									<td class="abstand">Anzahl der Wiederholungen:</td><td><strong>';
//line 172 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'repetitions_by_movie', 0]);
output += '</strong></td>\n								</tr>\n								';
//line 178 "meinyurtv_movies.js.html"
if ((stash.get('owner') == 1)) {
output += '\n								<tr>\n									<td colspan="2" class="abstand"><table cellspacing="0" cellpadding="0" border="0"><tr valign="middle"><td align="left"><input type="checkbox" ';
//line 176 "meinyurtv_movies.js.html"
if ((stash.get(['m', 0, 'gema', 0]) == 1)) {
output += 'checked="checked"';
}

output += ' value="1" onClick="toggleGEMA(this, \'';
//line 176 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += '\')"></td><td>&nbsp;Dieser Clip beinhaltet GEMA-pflichtiges Musikmaterial</td></tr></table></td>\n								</tr>\n								';
}

output += '\n							</table>\n						</div>\n							\n						<!--div class="play"><img src="/pics/meinyurtv/play.gif" border="0" onclick="alert(\'Funzt noch nicht!!\');"></div-->\n						';
//line 262 "meinyurtv_movies.js.html"
if ((stash.get('owner') == 1)) {
output += '\n						<div class="clipnavi">\n							<!--img src="/pics/meinyurtv/navi.gif" border="0" onclick="alert(\'Funzt noch nicht!!\');"-->\n							<table cellpadding="0" cellspacing="0" border="0">\n								<tr>\n								';
//line 218 "meinyurtv_movies.js.html"
if ((stash.get('archiv') != 1)) {
output += '\n									<td>\n										<div id="ClipToArchiv';
//line 190 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += '" class="btn1inactiv">\n											<table border="0" cellpadding="0" cellspacing="0">\n												<tr>\n													<td onmousemove="switchClass(\'ClipToArchiv';
//line 193 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += '\',\'btn1activ\')" onmouseout="switchClass(\'ClipToArchiv';
//line 193 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += '\',\'btn1inactiv\')" onclick="__Yur.meinyurtv.ClipToArchiv(';
//line 193 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += ')" class="left"></td>\n													<td onmousemove="switchClass(\'ClipToArchiv';
//line 194 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += '\',\'btn1activ\')" onmouseout="switchClass(\'ClipToArchiv';
//line 194 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += '\',\'btn1inactiv\')" onclick="__Yur.meinyurtv.ClipToArchiv(';
//line 194 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += ')" class="mitte"><div>Clip ins Archiv legen</div></td>\n													<!--td onmousemove="switchClass(\'ClipToArchiv';
//line 195 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += '\',\'btn1activ\')" onmouseout="switchClass(\'ClipToArchiv';
//line 195 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += '\',\'btn1inactiv\')" onclick="__Yur.meinyurtv.ClipToArchiv(';
//line 195 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += ')" class="right"></td-->\n													<td class="leer"></td>\n													<td class="trenner"></td>\n												</tr>\n											</table>\n										</div>\n										<!--a id="ClipToArchiv" href="javascript:__Yur.meinyurtv.ClipToArchiv(';
//line 201 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += ')">Clip ins Archiv legen</a-->\n									</td>\n								';
}
else {
output += '\n									<td>\n										<div id="ClipToList';
//line 205 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += '" class="btn1inactiv">\n											<table border="0" cellpadding="0" cellspacing="0">\n												<tr>\n													<td onmousemove="switchClass(\'ClipToList';
//line 208 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += '\',\'btn1activ\')" onmouseout="switchClass(\'ClipToList';
//line 208 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += '\',\'btn1inactiv\')" onclick="__Yur.meinyurtv.ClipToList(';
//line 208 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += ')" class="left"></td>\n													<td onmousemove="switchClass(\'ClipToList';
//line 209 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += '\',\'btn1activ\')" onmouseout="switchClass(\'ClipToList';
//line 209 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += '\',\'btn1inactiv\')" onclick="__Yur.meinyurtv.ClipToList(';
//line 209 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += ')" class="mitte"><div>Clip zur Normalansicht</div></td>\n													<!--td onmousemove="switchClass(\'ClipToList';
//line 210 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += '\',\'btn1activ\')" onmouseout="switchClass(\'ClipToList';
//line 210 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += '\',\'btn1inactiv\')" onclick="__Yur.meinyurtv.ClipToList(';
//line 210 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += ')" class="right"></td-->\n													<td class="leer"></td>\n													<td class="trenner"></td>\n												</tr>\n											</table>\n										</div>\n										<!--a id="ClipToList" href="javascript:__Yur.meinyurtv.ClipToList(';
//line 216 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += ')">Clip zur Normalansicht</a-->\n									</td>\n								';
}

output += '\n									<td>\n										<div id="deactivateClip';
//line 220 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += '" class="btn1inactiv">\n											<table border="0" cellpadding="0" cellspacing="0">\n												<tr>\n													<td class="leer"></td>\n													<!--td onmousemove="switchClass(\'deactivateClip';
//line 224 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += '\',\'btn1activ\')" onmouseout="switchClass(\'deactivateClip';
//line 224 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += '\',\'btn1inactiv\')" onclick="__Yur.meinyurtv.deactivateClip(';
//line 224 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += ')" class="left"></td-->\n													<td onmousemove="switchClass(\'deactivateClip';
//line 225 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += '\',\'btn1activ\')" onmouseout="switchClass(\'deactivateClip';
//line 225 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += '\',\'btn1inactiv\')" onclick="__Yur.meinyurtv.deactivateClip(';
//line 225 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += ')" class="mitte"><div>Clip vom Sender nehmen</div></td>\n													<!--td onmousemove="switchClass(\'deactivateClip';
//line 226 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += '\',\'btn1activ\')" onmouseout="switchClass(\'deactivateClip';
//line 226 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += '\',\'btn1inactiv\')" onclick="__Yur.meinyurtv.deactivateClip(';
//line 226 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += ')" class="right"></td-->\n													<td onmousemove="switchClass(\'deactivateClip';
//line 227 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += '\',\'btn1activ\')" onmouseout="switchClass(\'deactivateClip';
//line 227 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += '\',\'btn1inactiv\')" onclick="__Yur.meinyurtv.deactivateClip(';
//line 227 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += ')" class="right"></td>\n												</tr>\n											</table>\n										</div>\n										<!--&nbsp;<a href="javascript:__Yur.meinyurtv.deactivateClip(';
//line 231 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += ')">Clip vom Sender nehmen</a>-->\n									\n									</td>\n									<!--td>\n										<div id="gema';
//line 235 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += '" class="btn1inactiv">\n											<table border="0" cellpadding="0" cellspacing="0">\n												<tr>\n													<td class="trenner"></td>\n													<td class="leer"></td>\n													<!--td onmousemove="switchClass(\'gema';
//line 240 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += '\',\'btn1activ\')" onmouseout="switchClass(\'gema';
//line 240 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += '\',\'btn1inactiv\')" onclick="" class="left"></td-->\n													<!--td onmousemove="switchClass(\'gema';
//line 241 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += '\',\'btn1activ\')" onmouseout="switchClass(\'gema';
//line 241 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += '\',\'btn1inactiv\')" onclick="" class="mitte"><div>GEMA-Einstellungen editieren</div></td>\n													<td onmousemove="switchClass(\'gema';
//line 242 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += '\',\'btn1activ\')" onmouseout="switchClass(\'gema';
//line 242 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += '\',\'btn1inactiv\')" onclick="" class="right"></td>\n												</tr>\n											</table>\n										</div>\n									</td-->\n								</tr>\n							</table>\n						</div>\n						';
}
else {
output += '\n						<div class="verstoss">\n							<div id="verstossmelden';
//line 252 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += '" class="btn1inactiv">\n								<table border="0" cellpadding="0" cellspacing="0">\n									<tr>\n										<td onmousemove="switchClass(\'verstossmelden';
//line 255 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += '\',\'btn1activ\')" onmouseout="switchClass(\'verstossmelden';
//line 255 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += '\',\'btn1inactiv\')" onclick="VerstossPopUp(';
//line 255 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += ')" class="left"></td>\n										<td onmousemove="switchClass(\'verstossmelden';
//line 256 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += '\',\'btn1activ\')" onmouseout="switchClass(\'verstossmelden';
//line 256 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += '\',\'btn1inactiv\')" onclick="VerstossPopUp(';
//line 256 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += ')" class="mitte"><div>Versto&szlig; melden</div></td>\n										<td onmousemove="switchClass(\'verstossmelden';
//line 257 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += '\',\'btn1activ\')" onmouseout="switchClass(\'verstossmelden';
//line 257 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += '\',\'btn1inactiv\')" onclick="VerstossPopUp(';
//line 257 "meinyurtv_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += ')" class="right"></td>\n									</tr>\n								</table>\n							</div>\n						</div>\n						';
}

output += '\n						<div class="bgbox"><img src="/pics/t.gif" border="0" width="1" height="1"></div>\n					</div>\n				</div>\n			</td>\n		</tr>\n      ';
//line 268 "meinyurtv_movies.js.html"
stash.set('index', stash.get('index') + 1);
output += '\n	';;
            retval = list.get_next();
            value = retval[0];
            done = retval[1];
        }
    }
    catch(e) {
        throw(context.set_error(e, output));
    }
    stash.set('loop', oldloop);
})();

output += '\n		<tr class="gesamt tdtext">\n			<td class="" align="center">&nbsp;</td>\n			<td class="">&nbsp;</td>\n			<td class=""><strong>Gesamt';
//line 273 "meinyurtv_movies.js.html"
if ((stash.get(['pagination', 0, 'pages', 0]) > 1)) {
output += ' (Seite)';
}

output += ':</strong></td>\n			<td class="">&nbsp;</td>\n			<td class=""><strong>';
//line 275 "meinyurtv_movies.js.html"
output += stash.get(['tool', 0, 'format_hours_time_period', [ stash.get('ges_duration') ]]);
output += '</strong></td>\n			<td class=""><strong>';
//line 276 "meinyurtv_movies.js.html"
output += stash.get(['tool', 0, 'format_hours_time_period', [ stash.get('ges_airtime_seconds') ]]);
output += '</strong></td>\n			<td class="" align="center"><strong>';
//line 277 "meinyurtv_movies.js.html"
output += stash.get('ges_stock_points') / 100;
output += '</strong></td>\n			';
//line 278 "meinyurtv_movies.js.html"
stash.set('ges_stock_points_aktien', stash.get('ges_stock_points') / 100 / stash.get(['model', 0, 'data', 0, 'AktienPoints_Punkte_Pro_Aktie', 0]));
output += '\n			<td class="punktespalte" align="right"><div><strong>';
//line 279 "meinyurtv_movies.js.html"
output += stash.get(['tool', 0, 'format_wert_in_aktien', [ stash.get('ges_stock_points_aktien') ]]);
output += '</strong></div></td>\n		</tr>\n		<tr>\n			<td colspan="8" style="padding:0px;">\n				<table id="footermovie" cellspacing="0" cellpadding="0" border="0" width="100%">\n					<tr>\n						<td class="left">&nbsp;</td>\n						<td class="bg" width="155"><strong>Seite ';
//line 286 "meinyurtv_movies.js.html"
output += stash.get(['pagination', 0, 'curr', 0]);
output += ' von ';
//line 286 "meinyurtv_movies.js.html"
output += stash.get(['pagination', 0, 'last', 0]);
output += '</strong></td>\n						<td class="bg">';
//line 287 "meinyurtv_movies.js.html"
if ((stash.get(['pagination', 0, 'pages', 0]) > 1)) {
//line 287 "meinyurtv_movies.js.html"
output += context.include('meinyurtv_movies_pagination.js.html');
}
else {
output += '&nbsp;';
}

output += '</td>\n						<td class="bg" align="right" width="280" valign="middle"><!--Gehe zur Seite <input id="seite" type="text" style="width:20px" maxlength="3">&nbsp;&nbsp;<input id="LosButton" type="button" value="Los" onclick="__Yur.gcontent.getPageForm(\'seite\',';
//line 288 "meinyurtv_movies.js.html"
output += stash.get(['person', 0, 'id', 0]);
output += ')">&nbsp;&nbsp;&nbsp;-->\n							';
//line 289 "meinyurtv_movies.js.html"
if ((stash.get('archiv') != 1)) {
output += '<a id="showArchiv" href="javascript:__Yur.meinyurtv.showArchiv()">zum Archiv</a>';
}
else {
output += '<a id="showList" href="javascript:__Yur.meinyurtv.showList()">zur Normalansicht</a>';
}

output += '\n						</td>\n						<td class="right">&nbsp;</td>\n					</tr>\n				</table>\n			</td>\n		</tr>\n	</table>\n	</div>\n';
}
else {
output += '\n	<div style="padding:20px;"><div class="infoText">';
//line 299 "meinyurtv_movies.js.html"
if ((stash.get('archiv') != 1)) {
output += 'Es befinden sich zurzeit keine Videos in der Normalansicht.<br><a id="showList" href="javascript:__Yur.meinyurtv.showArchiv()">zum Archiv</a>';
}
else {
output += 'Es befinden sich zurzeit keine Videos im Archiv.<br><a id="showList" href="javascript:__Yur.meinyurtv.showList()">zur Normalansicht</a>';
}

output += '</div></div>\n';
}

output += '\n';
    }
    catch(e) {
        var error = context.set_error(e, output);
        throw(error);
    }

    return output;
}

Jemplate.templateMap['meinyurtv_movies_pagination.js.html'] = function(context) {
    if (! context) throw('Jemplate function called without context\n');
    var stash = context.stash;
    var output = '';

    try {
output += '	';
//line 1 "meinyurtv_movies_pagination.js.html"
stash.set('pagination', '');
output += '\n	\n	';
//line 3 "meinyurtv_movies_pagination.js.html"
stash.set('pa', stash.get(['model', 0, 'data', 0, 'pagination', 0]));
output += '\n\n\n	<div class="paginationContainerMovie">\n	  <div class="pagination ';
//line 7 "meinyurtv_movies_pagination.js.html"
output += stash.get('pagination');
output += '">\n		';
//line 8 "meinyurtv_movies_pagination.js.html"
stash.set('count', 0);
output += '\n		<div class="mitte">\n			<span class="cursor';
//line 10 "meinyurtv_movies_pagination.js.html"
if ((! stash.get(['pa', 0, 'back', 0]))) {
output += ' disabled';
}

output += '" onclick="__Yur.gcontent.loadMeinYURtvMovies(';
//line 10 "meinyurtv_movies_pagination.js.html"
output += stash.get(['person', 0, 'id', 0]);
output += ', ';
//line 10 "meinyurtv_movies_pagination.js.html"
output += stash.get(['pa', 0, 'back', 0]);
output += ')">\n				&lt;&nbsp;zur&uuml;ck\n			</span>&nbsp;\n		';
//line 17 "meinyurtv_movies_pagination.js.html"

// FOREACH 
(function() {
    var list = stash.get(['pa', 0, 'steps', 0]);
    list = new Jemplate.Iterator(list);
    var retval = list.get_first();
    var value = retval[0];
    var done = retval[1];
    var oldloop;
    try { oldloop = stash.get('loop') } finally {}
    stash.set('loop', list);
    try {
        while (! done) {
            stash.data['step'] = value;
output += '\n			';
//line 14 "meinyurtv_movies_pagination.js.html"
if ((stash.get('count'))) {
output += '|';
}

output += '\n			';
//line 15 "meinyurtv_movies_pagination.js.html"
if ((stash.get(['pa', 0, 'curr', 0]) != stash.get('step'))) {
output += '<span class="cursor" onclick="__Yur.gcontent.loadMeinYURtvMovies(';
//line 15 "meinyurtv_movies_pagination.js.html"
output += stash.get(['person', 0, 'id', 0]);
output += ', ';
//line 15 "meinyurtv_movies_pagination.js.html"
output += stash.get('step');
output += ')">';
}
else {
output += '<span class="act">';
}

//line 15 "meinyurtv_movies_pagination.js.html"
output += stash.get('step');
output += '</span>\n			';
//line 16 "meinyurtv_movies_pagination.js.html"
stash.set('count', stash.get('count') + 1);
output += '\n		';;
            retval = list.get_next();
            value = retval[0];
            done = retval[1];
        }
    }
    catch(e) {
        throw(context.set_error(e, output));
    }
    stash.set('loop', oldloop);
})();

output += '\n			&nbsp;<span class="cursor ';
//line 18 "meinyurtv_movies_pagination.js.html"
if ((! stash.get(['pa', 0, 'forward', 0]))) {
output += 'disabled';
}

output += '" onclick="__Yur.gcontent.loadMeinYURtvMovies(';
//line 18 "meinyurtv_movies_pagination.js.html"
output += stash.get(['person', 0, 'id', 0]);
output += ', ';
//line 18 "meinyurtv_movies_pagination.js.html"
output += stash.get(['pa', 0, 'forward', 0]);
output += ')">\n				weiter&nbsp;&gt;\n			</span>\n		</div>\n	  </div>\n	</div>';
    }
    catch(e) {
        var error = context.set_error(e, output);
        throw(error);
    }

    return output;
}

Jemplate.templateMap['movie_preview.js.html'] = function(context) {
    if (! context) throw('Jemplate function called without context\n');
    var stash = context.stash;
    var output = '';

    try {
//line 1 "movie_preview.js.html"
stash.set('movie', stash.get(['model', 0, 'movie', 0]));
output += '\n\n';
//line 93 "movie_preview.js.html"
if ((! stash.get(['model', 0, 'requesting', 0]))) {
output += '\n	';
//line 89 "movie_preview.js.html"
if ((stash.get('movie') != stash.get('null'))) {
output += '\n	\n		';
//line 6 "movie_preview.js.html"
stash.set('person', stash.get(['movie', 0, 'uploader_', 0]));
output += '\n		<div class="content">\n			<strong>\n			';
//line 17 "movie_preview.js.html"
if ((stash.get(['model', 0, 'preview_from', 0]) == 'person_movies')) {
output += '\n				<span onclick="__Yur.gcontent.show()" class="cursor linkstyle">zur&uuml;ck</span>\n			';
}
else {
output += '\n				';
//line 16 "movie_preview.js.html"
if ((stash.get(['model', 0, 'preview_from', 0]) == 'my_movies')) {
output += '\n					<span onclick="__Yur.myTV.show()" class="cursor linkstyle">zur&uuml;ck</span>\n				';
}
else {
output += '\n					<span onclick="__Yur.queue.show()" class="cursor linkstyle">zur&uuml;ck</span>\n				';
}

output += '\n			';
}

output += '</strong>\n		\n			<div class="name">Title:</div>\n			<div class="value">';
//line 20 "movie_preview.js.html"
output += stash.get(['movie', 0, 'title', 0]);
output += '</div>\n\n			<div class="name">Uploader:</div>\n			<div class="value"><span onclick="location.href=\'/user/';
//line 23 "movie_preview.js.html"
output += stash.get(['person', 0, 'alias', 0]);
output += '\'" class="alias cursor linkstyle">';
//line 23 "movie_preview.js.html"
output += stash.get(['person', 0, 'alias', 0]);
output += '</span></div>\n	\n			<div class="name">Uploaded:</div>\n			<div class="value">';
//line 26 "movie_preview.js.html"
output += stash.get(['movie', 0, 'upload_time_german', 0]);
output += ' Uhr</div>\n			\n			<div class="name">Laufzeit:</div>\n			<div class="value">';
//line 29 "movie_preview.js.html"
output += stash.get(['tool', 0, 'format_advanced_time_period', [ stash.get(['movie', 0, 'duration', 0]) ]]);
output += '</div>\n\n			<div class="name">On-Air-Zeit:</div>\n			<div class="value">';
//line 32 "movie_preview.js.html"
if ((stash.get(['movie', 0, 'total_airtime', 0]))) {
//line 32 "movie_preview.js.html"
output += stash.get(['tool', 0, 'format_advanced_time_period', [ stash.get(['movie', 0, 'total_airtime', 0]) ]]);
}
else {
output += '0s';
}

output += '</div>\n			\n			<div class="name">Aktien:</div>\n			<div class="value">';
//line 35 "movie_preview.js.html"
output += stash.get(['movie', 0, 'stock_points', 0]) / 100;
output += ' Punkt';
//line 35 "movie_preview.js.html"
if ((stash.get(['movie', 0, 'stock_points', 0]) != 100 && stash.get(['movie', 0, 'stock_points', 0]) != -100)) {
output += 'e';
}

output += '</div>\n	\n			<div class="name">Bewertung:</div>\n			<div class="value">';
//line 38 "movie_preview.js.html"
output += stash.get(['tool', 0, 'format_durchschnitt', [ stash.get(['movie', 0, 'voting', 0, 'result', 0]) ]]);
output += ' bei ';
//line 38 "movie_preview.js.html"
output += stash.get(['movie', 0, 'voting', 0, 'count', 0]);
output += ' Bewertung';
//line 38 "movie_preview.js.html"
if ((stash.get(['movie', 0, 'voitng', 0, 'count', 0]) != 1)) {
output += 'en';
}

output += '</div>\n\n<!--			<div id="itemVotePreview" class="vote" onmouseover="__Yur.moviePreview.movie.voting.open()" onmouseout="__Yur.moviePreview.movie.voting.close()">\n				<div class="text" id="votePreviewText">';
//line 41 "movie_preview.js.html"
output += stash.get(['movie', 0, 'voting', 0, 'count', 0]);
output += ' Vote';
//line 41 "movie_preview.js.html"
if ((stash.get(['movie', 0, 'voting', 0, 'count', 0]) != 1)) {
output += 's';
}

output += '</div>\n		\n				<div id="votePreviewEdit" style="display:none;">\n					<div class="regler" id="votePreviewRegler"></div>\n					<div class="touchPad" onclick="__Yur.moviePreview.movie.voting.bar_click(event,this)" onmousemove="__Yur.moviePreview.movie.voting.bar_mousemove(event)"></div>\n				</div>\n		\n				<div id="votePreviewAnzeige" style="">\n					<div class="zeiger" id="votePreviewZeiger" style="left:';
//line 49 "movie_preview.js.html"
output += stash.get(['movie', 0, 'voting', 0, 'zeiger_position_queue', 0]);
output += 'px"></div>\n				</div>\n		\n				<div class="textFlop">flop</div>\n				<div class="textTop">top</div>\n			</div>\n-->\n			<br>\n			<div id="ThumbPlayerContainer"><object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" codebase="http://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=8,0,0,0" width="240" height="220" id="flv_thumb_player" align="middle">\n				<param name="allowScriptAccess" value="sameDomain" />\n				<param name="movie"\n				value="/flv_thumb_player2.swf?video_url=';
//line 60 "movie_preview.js.html"
output += stash.get(['movie', 0, 'path', 0]);
output += '/thumb.flv" /><param name="quality" value="high" /><param name="bgcolor" value="#ffffff" />\n				<embed\n				src="/flv_thumb_player2.swf?video_url=';
//line 62 "movie_preview.js.html"
output += stash.get(['movie', 0, 'path', 0]);
output += '/thumb.flv" quality="high" bgcolor="#ffffff" width="240" height="220" name="flv_thumb_player" align="middle" allowScriptAccess="sameDomain" type="application/x-shockwave-flash" pluginspage="http://www.macromedia.com/go/getflashplayer" />\n			</object></div>\n			<div class="">';
//line 64 "movie_preview.js.html"
output += stash.get(['movie', 0, 'description', 0]);
output += '</div>\n			<br>\n			<strong>\n			';
//line 75 "movie_preview.js.html"
if ((stash.get(['model', 0, 'preview_from', 0]) == 'person_movies')) {
output += '\n				<span onclick="__Yur.gcontent.show()" class="cursor linkstyle">zur&uuml;ck</span>\n			';
}
else {
output += '\n				';
//line 74 "movie_preview.js.html"
if ((stash.get(['model', 0, 'preview_from', 0]) == 'my_movies')) {
output += '\n					<span onclick="__Yur.myTV.show()" class="cursor linkstyle">zur&uuml;ck</span>\n				';
}
else {
output += '\n					<span onclick="__Yur.queue.show()" class="cursor linkstyle">zur&uuml;ck</span>\n				';
}

output += '\n			';
}

output += '</strong>\n		</div>\n	';
}
else {
output += '\n		<div class="content">Movie konnte nicht geladen werden...</div>\n		<strong>\n		';
//line 88 "movie_preview.js.html"
if ((stash.get(['model', 0, 'preview_from', 0]) == 'person_movies')) {
output += '\n			<span onclick="__Yur.gcontent.show()" class="cursor linkstyle">zur&uuml;ck</span>\n		';
}
else {
output += '\n			';
//line 87 "movie_preview.js.html"
if ((stash.get(['model', 0, 'preview_from', 0]) == 'my_movies')) {
output += '\n				<span onclick="__Yur.myTV.show()" class="cursor linkstyle">zur&uuml;ck</span>\n			';
}
else {
output += '\n				<span onclick="__Yur.queue.show()" class="cursor linkstyle">zur&uuml;ck</span>\n			';
}

output += '\n		';
}

output += '</strong>\n	';
}

output += '\n	\n';
}
else {
output += '\n		 	<div class="loading"><img src="/pics/loading_grey.gif" border="0"></div>\n';
}

output += '\n';
    }
    catch(e) {
        var error = context.set_error(e, output);
        throw(error);
    }

    return output;
}

Jemplate.templateMap['nextqueue.js.html'] = function(context) {
    if (! context) throw('Jemplate function called without context\n');
    var stash = context.stash;
    var output = '';

    try {
//line 1 "nextqueue.js.html"
stash.set('nextqueue', stash.get('model'));
output += '\n						<div id="PreviewQueueBanner">\n							<div style="background-image:url(/pics/banner/queue/';
//line 3 "nextqueue.js.html"
output += stash.get(['nextqueue', 0, 'meta', 0]);
output += '.jpg); background-repeat:no-repeat">';
//line 3 "nextqueue.js.html"
if (stash.get(['nextqueue', 0, 'href', 0])) {
output += '<a href="';
//line 3 "nextqueue.js.html"
output += stash.get(['nextqueue', 0, 'href', 0]);
output += '">';
}

output += '<img src="/pics/shared/box_top_schatten_teaser.png" width="190" height="3" alt="" /><img src="/pics/shared/t.gif" width="190" height="47" alt="" />';
//line 3 "nextqueue.js.html"
if (stash.get(['nextqueue', 0, 'href', 0])) {
output += '</a>';
}

output += '</div>\n						</div>\n						\n						<div id="QueueText">';
//line 6 "nextqueue.js.html"
if ((stash.get(['nextqueue', 0, 'description', 0]))) {
//line 6 "nextqueue.js.html"
output += stash.get(['nextqueue', 0, 'description', 0]);
}
else {
//line 6 "nextqueue.js.html"
output += stash.get(['nextqueue', 0, 'name', 0]);
}

output += ' (ab ';
//line 6 "nextqueue.js.html"
output += stash.get(['tool', 0, 'format_sql_datetime_to_german_time', [ stash.get(['nextqueue', 0, 'start', 0]) ]]);
output += ' Uhr)</div>\n						\n						<div class="btnbox1 cursor">\n							<div class="in" onmouseover="switchClassTo(this,\'act\')" onmouseout="switchClassTo(this,\'in\')" onclick="showUploadBox(';
//line 9 "nextqueue.js.html"
output += stash.get(['nextqueue', 0, 'meta', 0]);
output += ')">\n								<div class="abstand">Eigenes Video uploaden</div>\n							</div>\n						</div>';
    }
    catch(e) {
        var error = context.set_error(e, output);
        throw(error);
    }

    return output;
}

Jemplate.templateMap['person_details.js.html'] = function(context) {
    if (! context) throw('Jemplate function called without context\n');
    var stash = context.stash;
    var output = '';

    try {
//line 1 "person_details.js.html"
stash.set('p', stash.get(['model', 0, 'person', 0]));
output += '\n\n     <div class="top"><div><div><div class="cursor" onclick="__Yur.personDetails.hide()">X</div>';
//line 3 "person_details.js.html"
output += stash.get(['p', 0, 'alias', 0]);
output += '</div></div></div>\n	 \n	 <div class="line"></div>\n	 <div class="content hellerbg">\n	 	<div class="name">Mitglied:</div>\n		<div class="value">seit dem ';
//line 8 "person_details.js.html"
output += stash.get(['p', 0, 'registriert_seit_german', 0]);
output += ' Uhr</div>\n		\n		<div class="name">Ranking:</div>\n		<div class="value">';
//line 11 "person_details.js.html"
if ((stash.get(['p', 0, 'rank', 0]))) {
output += 'Platz ';
//line 11 "person_details.js.html"
output += stash.get(['p', 0, 'rank', 0]);
}
else {
output += 'Nimmt erst am Ranking teil, wenn er/sie eine On-Air-Zeit hat.';
}

output += '</div>\n\n	 	<div class="name">On-Air-Zeit:</div>\n		<div class="value">';
//line 14 "person_details.js.html"
if ((stash.get(['p', 0, 'airtime_seconds', 0]))) {
//line 14 "person_details.js.html"
output += stash.get(['tool', 0, 'format_advanced_time_period', [ stash.get(['p', 0, 'airtime_seconds', 0]) ]]);
}
else {
output += '0s';
}

output += '</div>\n		\n		<div class="name">Aktien:</div>';
//line 16 "person_details.js.html"
stash.set('points', stash.get(['p', 0, 'stock_points', 0]) / 100);
output += '\n		<div class="value">';
//line 17 "person_details.js.html"
output += stash.get('points');
output += ' Punkt';
//line 17 "person_details.js.html"
if ((stash.get('points') != 1 && stash.get('points') != -1)) {
output += 'e';
}

output += '</div>\n\n	 	<div class="name">Bewertung:</div>\n		<div class="value">';
//line 20 "person_details.js.html"
output += stash.get(['tool', 0, 'format_durchschnitt', [ stash.get(['p', 0, 'bewertung', 0, 'result', 0]) ]]);
output += ' bei ';
//line 20 "person_details.js.html"
output += stash.get(['p', 0, 'bewertung', 0, 'count', 0]);
output += ' Bewertung';
//line 20 "person_details.js.html"
if ((stash.get(['p', 0, 'bewertung', 0, 'count', 0]) != 1)) {
output += 'en';
}

output += '</div>\n		\n	 	<div class="name';
//line 22 "person_details.js.html"
if ((stash.get(['p', 0, 'anzahl_videos', 0]) > 0)) {
output += ' cursor linkstyle" onclick="__Yur.gcontent.loadPersonMovies(';
//line 22 "person_details.js.html"
output += stash.get(['p', 0, 'id', 0]);
output += ',1)"';
}
else {
output += '"';
}

output += '>Videos:</div>\n		<div class="value';
//line 23 "person_details.js.html"
if ((stash.get(['p', 0, 'anzahl_videos', 0]) > 0)) {
output += ' cursor linkstyle" onclick="__Yur.gcontent.loadPersonMovies(';
//line 23 "person_details.js.html"
output += stash.get(['p', 0, 'id', 0]);
output += ',1)"';
}
else {
output += '"';
}

output += '>';
//line 23 "person_details.js.html"
output += stash.get(['p', 0, 'anzahl_videos', 0]);
output += '</div>\n	 </div>\n	 <div class="line"></div>\n	 <div class="beschreibung">\n	 	';
//line 27 "person_details.js.html"
if ((stash.get(['p', 0, 'image', 0]))) {
output += '<div class="avatarContainer"><div class="imgBorder">';
//line 27 "person_details.js.html"
output += stash.get(['p', 0, 'image_html', 0]);
output += '</div></div>';
}

output += '\n	 	';
//line 31 "person_details.js.html"
if ((stash.get(['p', 0, 'beschreibung', 0]))) {
output += '\n	 		<div class="strong">Kurzbeschreibung</div>\n			<div>';
//line 30 "person_details.js.html"
output += stash.get(['p', 0, 'beschreibung', 0]);
output += '</div>\n		';
}

output += '\n		<div class="clear"></div>\n	 </div>\n	 \n     <div class="bottom"><div><div></div></div></div>\n';
    }
    catch(e) {
        var error = context.set_error(e, output);
        throw(error);
    }

    return output;
}

Jemplate.templateMap['person_movies.js.html'] = function(context) {
    if (! context) throw('Jemplate function called without context\n');
    var stash = context.stash;
    var output = '';

    try {
//line 1 "person_movies.js.html"
stash.set('movies', stash.get(['model', 0, 'data', 0, 'list', 0]));
output += '\n';
//line 2 "person_movies.js.html"
stash.set('person', stash.get(['model', 0, 'data', 0, 'person', 0]));
output += '\n';
//line 3 "person_movies.js.html"
stash.set('pagination', stash.get(['model', 0, 'data', 0, 'pagination', 0]));
output += '\n\n';
//line 73 "person_movies.js.html"
if ((stash.get(['person', 0, 'anzahl_videos', 0]) > 0)) {
output += '\n	\n	';
//line 7 "person_movies.js.html"
if ((stash.get(['pagination', 0, 'pages', 0]) > 1)) {
output += '<div style="padding-bottom:1px;">';
//line 7 "person_movies.js.html"
output += context.include('person_movies_pagination.js.html');
output += '</div>';
}

output += '\n\n	';
//line 39 "person_movies.js.html"
if ((stash.get(['pagination', 0, 'curr', 0]) == 1)) {
output += '\n	   <div class="personDetails">\n		 <div class="content hell">\n		 	<div class="name">Alias:</div>\n			<div class="value">';
//line 13 "person_movies.js.html"
output += stash.get(['person', 0, 'alias', 0]);
output += '</div>\n	\n		 	<div class="name">Mitglied:</div>\n			<div class="value">seit dem ';
//line 16 "person_movies.js.html"
output += stash.get(['person', 0, 'registriert_seit_german', 0]);
output += ' Uhr</div>\n			\n		 	<div class="name">On-Air-Zeit:</div>\n			<div class="value">';
//line 19 "person_movies.js.html"
if ((stash.get(['person', 0, 'airtime_seconds', 0]))) {
//line 19 "person_movies.js.html"
output += stash.get(['tool', 0, 'format_advanced_time_period', [ stash.get(['person', 0, 'airtime_seconds', 0]) ]]);
}
else {
output += '0s';
}

output += '</div>\n			\n		 	<div class="name">Karma:</div>\n			<div class="value">';
//line 22 "person_movies.js.html"
output += stash.get(['tool', 0, 'format_karma', [ stash.get(['person', 0, 'bewertung', 0, 'karma', 0]) ]]);
output += ' Punkt';
//line 22 "person_movies.js.html"
if ((stash.get(['person', 0, 'bewertung', 0, 'karma', 0]) != 1 && stash.get(['person', 0, 'bewertung', 0, 'karma', 0]) != -1)) {
output += 'e';
}

output += '</div>\n	\n		 	<div class="name">Bewertung:</div>\n			<div class="value">';
//line 25 "person_movies.js.html"
output += stash.get(['tool', 0, 'format_durchschnitt', [ stash.get(['person', 0, 'bewertung', 0, 'result', 0]) ]]);
output += ' bei ';
//line 25 "person_movies.js.html"
output += stash.get(['person', 0, 'bewertung', 0, 'count', 0]);
output += ' Bewertung';
//line 25 "person_movies.js.html"
if ((stash.get(['p', 0, 'bewertung', 0, 'count', 0]) != 1)) {
output += 'en';
}

output += '</div>\n			\n		 	<div class="name">Videos:</div>\n			<div class="value">';
//line 28 "person_movies.js.html"
output += stash.get(['person', 0, 'anzahl_videos', 0]);
output += '</div>\n		 </div>\n		 <div class="beschreibung">\n		 	';
//line 31 "person_movies.js.html"
if ((stash.get(['person', 0, 'image', 0]))) {
output += '<div class="avatarContainer"><div class="imgBorder">';
//line 31 "person_movies.js.html"
output += stash.get(['person', 0, 'image_html', 0]);
output += '</div></div>';
}

output += '\n		 	';
//line 35 "person_movies.js.html"
if ((stash.get(['person', 0, 'beschreibung', 0]))) {
output += '\n		 		<div class="strong">Kurzbeschreibung</div>\n				<div>';
//line 34 "person_movies.js.html"
output += stash.get(['person', 0, 'beschreibung', 0]);
output += '</div>\n			';
}

output += '\n			<div class="clear"></div>\n		 </div>\n	   </div>\n	';
}

output += '\n	\n	';
//line 41 "person_movies.js.html"
stash.set('index', stash.get(['model', 0, 'data', 0, 'pagination', 0, 'first_entry_on_page', 0]));
output += '\n	';
//line 67 "person_movies.js.html"

// FOREACH 
(function() {
    var list = stash.get('movies');
    list = new Jemplate.Iterator(list);
    var retval = list.get_first();
    var value = retval[0];
    var done = retval[1];
    var oldloop;
    try { oldloop = stash.get('loop') } finally {}
    stash.set('loop', list);
    try {
        while (! done) {
            stash.data['m'] = value;
output += '\n	      <div class="movieDetails ';
//line 43 "person_movies.js.html"
if ((stash.get('index') % 2)) {
output += 'dunkel';
}
else {
output += 'hell';
}

output += '">\n		\n		    <div class="thumbContainer">\n	          <div class="imgBorder"><a href="javascript:__Yur.moviePreview.show(';
//line 46 "person_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += ', \'person_movies\', ';
//line 46 "person_movies.js.html"
output += stash.get(['m', 0, 'uploader', 0]);
output += ')"><img src="/movies/';
//line 46 "person_movies.js.html"
output += stash.get(['m', 0, 'path', 0]);
output += '/screen1.jpg" width="94" height="70" border="0" /></a></div>\n	        </div>\n	\n	        <div class="programmtext">\n	          <div class="nr">';
//line 50 "person_movies.js.html"
output += stash.get('index');
output += '</div>\n	          <div class="titel">';
//line 51 "person_movies.js.html"
output += stash.get(['m', 0, 'title', 0]);
output += '</div>\n	          ';
//line 52 "person_movies.js.html"
output += stash.get(['m', 0, 'description', 0]);
output += '\n		    </div>\n	        <div class="tags"><span id="movieTags';
//line 54 "person_movies.js.html"
output += stash.get(['m', 0, 'id', 0]);
output += '" >';
//line 54 "person_movies.js.html"
output += stash.get(['m', 0, 'tags_as_string', 0]);
output += '</span></div>\n			\n			<div class="line"><img src="/pics/t.gif" height="1" width="1"></div>\n			<div class="info">\n	    	    <div class="rechts"><span id="movieDuration<% movie.id %>">Laufzeit: ';
//line 58 "person_movies.js.html"
output += stash.get(['tool', 0, 'format_advanced_time_period', [ stash.get(['m', 0, 'duration', 0]) ]]);
output += '</span></div>\n				';
//line 59 "person_movies.js.html"
stash.set('voting', stash.get(['m', 0, 'voting', 0]));
output += '\n				<div>Hochgeladen: ';
//line 60 "person_movies.js.html"
output += stash.get(['m', 0, 'upload_time_german', 0]);
output += '</div>\n				<div>Bewertungen: ';
//line 61 "person_movies.js.html"
output += stash.get(['voting', 0, 'count', 0]);
//line 61 "person_movies.js.html"
if ((stash.get(['voting', 0, 'count', 0]) > 0)) {
output += '&nbsp;&nbsp;&nbsp;&Oslash;: ';
//line 61 "person_movies.js.html"
output += stash.get(['tool', 0, 'format_durchschnitt', [ stash.get(['voting', 0, 'result', 0]) ]]);
}

output += '</div>\n				<div>On-Air-Time: ';
//line 62 "person_movies.js.html"
output += stash.get(['tool', 0, 'format_advanced_time_period', [ stash.get(['m', 0, 'total_airtime', 0]) ]]);
output += '</div>\n			</div>\n			<div style="height:1px; clear:both"><img src="/pics/t.gif" height="1" width="1"></div>\n	      </div>\n	      ';
//line 66 "person_movies.js.html"
stash.set('index', stash.get('index') + 1);
output += '\n	';;
            retval = list.get_next();
            value = retval[0];
            done = retval[1];
        }
    }
    catch(e) {
        throw(context.set_error(e, output));
    }
    stash.set('loop', oldloop);
})();

output += '\n\n	';
//line 69 "person_movies.js.html"
if ((stash.get(['pagination', 0, 'pages', 0]) > 1)) {
output += '<div style="padding-top:1px;">';
//line 69 "person_movies.js.html"
output += context.include('person_movies_pagination.js.html');
}

output += '</div>\n\n';
}
else {
output += '\n	<div class="infoText">Dieser User hat noch keine eigenen Videos.</div>\n';
}

output += '\n\n';
    }
    catch(e) {
        var error = context.set_error(e, output);
        throw(error);
    }

    return output;
}

Jemplate.templateMap['person_movies_pagination.js.html'] = function(context) {
    if (! context) throw('Jemplate function called without context\n');
    var stash = context.stash;
    var output = '';

    try {
output += '	';
//line 1 "person_movies_pagination.js.html"
stash.set('pagination', '');
output += '\n	';
//line 2 "person_movies_pagination.js.html"
stash.set('span', '');
output += '\n	';
//line 3 "person_movies_pagination.js.html"
stash.set('pa', stash.get(['model', 0, 'data', 0, 'pagination', 0]));
output += '\n	';
//line 4 "person_movies_pagination.js.html"
if ((stash.get(['pa', 0, 'first', 0]) >= 5 || stash.get(['pa', 0, 'last', 0]) >= 1)) {
//line 4 "person_movies_pagination.js.html"
stash.set('pagination', 'paginationPlatzSparen');
}

output += '\n	';
//line 5 "person_movies_pagination.js.html"
if ((stash.get(['pa', 0, 'first', 0]) >= 50 || stash.get(['pa', 0, 'last', 0]) >= 1)) {
//line 5 "person_movies_pagination.js.html"
stash.set('span', 'spanPlatzSparen');
}

output += '\n	<div class="paginationContainer hell">\n	  <div class="pagination ';
//line 7 "person_movies_pagination.js.html"
output += stash.get('pagination');
output += '">\n		<div class="rechts">\n			<span class="cursor';
//line 9 "person_movies_pagination.js.html"
if ((! stash.get(['pa', 0, 'forward', 0]))) {
output += ' disabled';
}

output += '" onclick="__Yur.gcontent.loadPersonMovies(';
//line 9 "person_movies_pagination.js.html"
output += stash.get(['person', 0, 'id', 0]);
output += ', ';
//line 9 "person_movies_pagination.js.html"
output += stash.get(['pa', 0, 'last', 0]);
output += ')">\n				&gt;&gt;\n			</span>\n		</div>\n		<div class="links">\n			<span class="cursor';
//line 14 "person_movies_pagination.js.html"
if ((! stash.get(['pa', 0, 'back', 0]))) {
output += ' disabled';
}

output += '" onclick="__Yur.gcontent.loadPersonMovies(';
//line 14 "person_movies_pagination.js.html"
output += stash.get(['person', 0, 'id', 0]);
output += ', ';
//line 14 "person_movies_pagination.js.html"
output += stash.get(['pa', 0, 'first', 0]);
output += ')">\n				&lt;&lt;\n			</span>\n		</div>\n		';
//line 18 "person_movies_pagination.js.html"
stash.set('count', 0);
output += '\n		<div class="mitte">\n		<span class="cursor ';
//line 20 "person_movies_pagination.js.html"
output += stash.get('span');
output += ' ';
//line 20 "person_movies_pagination.js.html"
if ((! stash.get(['pa', 0, 'back', 0]))) {
output += 'disabled';
}

output += '" onclick="__Yur.gcontent.loadPersonMovies(';
//line 20 "person_movies_pagination.js.html"
output += stash.get(['person', 0, 'id', 0]);
output += ', ';
//line 20 "person_movies_pagination.js.html"
output += stash.get(['pa', 0, 'back', 0]);
output += ')">&lt;</span>&nbsp;\n		';
//line 25 "person_movies_pagination.js.html"

// FOREACH 
(function() {
    var list = stash.get(['pa', 0, 'steps', 0]);
    list = new Jemplate.Iterator(list);
    var retval = list.get_first();
    var value = retval[0];
    var done = retval[1];
    var oldloop;
    try { oldloop = stash.get('loop') } finally {}
    stash.set('loop', list);
    try {
        while (! done) {
            stash.data['step'] = value;
output += '\n			';
//line 22 "person_movies_pagination.js.html"
if ((stash.get('count'))) {
output += '|';
}

output += '\n			';
//line 23 "person_movies_pagination.js.html"
if ((stash.get(['pa', 0, 'curr', 0]) != stash.get('step'))) {
output += '<span class="cursor ';
//line 23 "person_movies_pagination.js.html"
output += stash.get('span');
output += '" onclick="__Yur.gcontent.loadPersonMovies(';
//line 23 "person_movies_pagination.js.html"
output += stash.get(['person', 0, 'id', 0]);
output += ', ';
//line 23 "person_movies_pagination.js.html"
output += stash.get('step');
output += ')">';
}
else {
output += '<span class="act ';
//line 23 "person_movies_pagination.js.html"
output += stash.get('span');
output += '">';
}

//line 23 "person_movies_pagination.js.html"
output += stash.get('step');
output += '</span>\n			';
//line 24 "person_movies_pagination.js.html"
stash.set('count', stash.get('count') + 1);
output += '\n		';;
            retval = list.get_next();
            value = retval[0];
            done = retval[1];
        }
    }
    catch(e) {
        throw(context.set_error(e, output));
    }
    stash.set('loop', oldloop);
})();

output += '&nbsp;<span class="cursor ';
//line 25 "person_movies_pagination.js.html"
output += stash.get('span');
output += ' ';
//line 25 "person_movies_pagination.js.html"
if ((! stash.get(['pa', 0, 'forward', 0]))) {
output += 'disabled';
}

output += '" onclick="__Yur.gcontent.loadPersonMovies(';
//line 25 "person_movies_pagination.js.html"
output += stash.get(['person', 0, 'id', 0]);
output += ', ';
//line 25 "person_movies_pagination.js.html"
output += stash.get(['pa', 0, 'forward', 0]);
output += ')">&gt;</span>\n		</div>\n	  </div>\n	</div>';
    }
    catch(e) {
        var error = context.set_error(e, output);
        throw(error);
    }

    return output;
}

Jemplate.templateMap['preise_ranking_list.js.html'] = function(context) {
    if (! context) throw('Jemplate function called without context\n');
    var stash = context.stash;
    var output = '';

    try {
output += '\n';
//line 2 "preise_ranking_list.js.html"
stash.set('list', stash.get(['model', 0, 'list', 0]));
output += '\n';
//line 3 "preise_ranking_list.js.html"
stash.set('queue', stash.get(['model', 0, 'queue', 0]));
output += '\n\n';
//line 5 "preise_ranking_list.js.html"
if ((stash.get('queue') == 74)) {
//line 5 "preise_ranking_list.js.html"
stash.set('anzahl_preise', 5);
}

output += '\n';
//line 6 "preise_ranking_list.js.html"
if ((stash.get('queue') == 75 || stash.get('queue') == 78)) {
//line 6 "preise_ranking_list.js.html"
stash.set('anzahl_preise', 3);
}

output += '\n';
//line 7 "preise_ranking_list.js.html"
if ((stash.get('queue') == 76)) {
//line 7 "preise_ranking_list.js.html"
stash.set('anzahl_preise', 6);
}

output += '\n';
//line 8 "preise_ranking_list.js.html"
if ((stash.get('queue') == 77)) {
//line 8 "preise_ranking_list.js.html"
stash.set('anzahl_preise', 4);
}

output += '\n\n';
//line 10 "preise_ranking_list.js.html"
stash.set('pagination', stash.get(['model', 0, 'pagination', 0]));
output += '\n\n	<table id="resulttable" cellpadding="0" cellspacing="0" border="0">\n	';
//line 100 "preise_ranking_list.js.html"
if ((stash.get(['pagination', 0, 'total_entries', 0]))) {
output += '\n		<tr>\n			<th class="left">&nbsp;</th>\n			<th class="bg" align="center"><div>PLATZ</div></th>\n			<th class="bg" width="70"><div>GEWINN</div></th>\n			<th class="bg" width="180"><div>&nbsp;</div></th>\n			<th class="bg" width="290"><div>FILM</div></th>\n			<th class="bg"><div>USER</div></th>\n			<th class="right">&nbsp;</th>\n		</tr>\n		\n		';
//line 24 "preise_ranking_list.js.html"
stash.set('count', 0);
output += '\n		';
//line 97 "preise_ranking_list.js.html"

// FOREACH 
(function() {
    var list = stash.get('list');
    list = new Jemplate.Iterator(list);
    var retval = list.get_first();
    var value = retval[0];
    var done = retval[1];
    var oldloop;
    try { oldloop = stash.get('loop') } finally {}
    stash.set('loop', list);
    try {
        while (! done) {
            stash.data['p'] = value;
output += '\n		  ';
//line 26 "preise_ranking_list.js.html"
stash.set('platz', stash.get(['pagination', 0, 'first_entry_on_page', 0]) + stash.get('count'));
output += '\n		  ';
//line 27 "preise_ranking_list.js.html"
stash.set('class', '');
output += '\n		  \n		  ';
//line 29 "preise_ranking_list.js.html"
if ((stash.get('platz') > 0 && stash.get('platz') <= stash.get('anzahl_preise'))) {
//line 29 "preise_ranking_list.js.html"
stash.set('class', 'first10');
}

output += '\n		  ';
//line 30 "preise_ranking_list.js.html"
if ((stash.get('platz') > stash.get('anzahl_preise'))) {
//line 30 "preise_ranking_list.js.html"
stash.set('class', 'rest');
}

output += '\n		  ';
//line 31 "preise_ranking_list.js.html"
if ((stash.get('platz') <= stash.get('anzahl_preise') && ! (stash.get('count') % 2))) {
//line 31 "preise_ranking_list.js.html"
stash.set('class', stash.get('class')  + ' dunkel1');
}

output += '\n		  ';
//line 32 "preise_ranking_list.js.html"
if ((stash.get('platz') > stash.get('anzahl_preise') && ! (stash.get('count') % 2))) {
//line 32 "preise_ranking_list.js.html"
stash.set('class', stash.get('class')  + ' dunkel2');
}

output += '\n		  ';
//line 33 "preise_ranking_list.js.html"
if ((stash.get(['model', 0, 'person', 0]) && stash.get(['p', 0, 'person', 0]) == stash.get(['model', 0, 'person', 0]))) {
//line 33 "preise_ranking_list.js.html"
stash.set('class', stash.get('class')  + ' treffer');
}

output += '\n		  ';
//line 95 "preise_ranking_list.js.html"
if ((stash.get('platz') <= stash.get('anzahl_preise'))) {
output += '\n		  <tr>\n		  	<td class="';
//line 36 "preise_ranking_list.js.html"
output += stash.get('class');
output += '">&nbsp;</td>\n			<td class="';
//line 37 "preise_ranking_list.js.html"
output += stash.get('class');
output += '" align="center"><div>';
//line 37 "preise_ranking_list.js.html"
output += stash.get('count') + 1 + (stash.get(['pagination', 0, 'entries_per_page', 0]) * (stash.get(['pagination', 0, 'curr', 0]) - 1));
output += '</div></td>\n			\n			';
//line 42 "preise_ranking_list.js.html"
if ((stash.get('platz') == 1 && stash.get('queue') == 74)) {
output += '\n			<td class="';
//line 40 "preise_ranking_list.js.html"
output += stash.get('class');
output += '" align="left" valign="middle"><div><img src="/pics/microsite/moposportschau/t1p1.jpg" ></div></td>\n			<td class="';
//line 41 "preise_ranking_list.js.html"
output += stash.get('class');
output += '" align="left" valign="middle"><div>Bowling Abend mit 5 Spielern<br>der Hamburg Blue Devils</div></td>\n			';
}

output += '\n			';
//line 46 "preise_ranking_list.js.html"
if (((stash.get('platz') == 2 || stash.get('platz') == 3) && stash.get('queue') == 74)) {
output += '\n			<td class="';
//line 44 "preise_ranking_list.js.html"
output += stash.get('class');
output += '" align="left" valign="middle"><div><img src="/pics/microsite/moposportschau/t1p2_3.jpg" ></div></td>\n			<td class="';
//line 45 "preise_ranking_list.js.html"
output += stash.get('class');
output += '" align="left" valign="middle"><div>1 signiertes Trikot<br>des 1. FC St. Pauli</div></td>\n			';
}

output += '\n			';
//line 50 "preise_ranking_list.js.html"
if (((stash.get('platz') == 4 && stash.get('queue') == 74) || (stash.get('platz') == 2 && stash.get('queue') == 75) || (stash.get('platz') == 5 && stash.get('queue') == 76) || (stash.get('platz') == 3 && stash.get('queue') == 77))) {
output += '\n			<td class="';
//line 48 "preise_ranking_list.js.html"
output += stash.get('class');
output += '" align="left" valign="middle"><div><img src="/pics/microsite/moposportschau/t_alle_cam.jpg" ></div></td>\n			<td class="';
//line 49 "preise_ranking_list.js.html"
output += stash.get('class');
output += '" align="left" valign="middle"><div>eine YUR.tv<br>Digitalkamera</div></td>\n			';
}

output += '\n			';
//line 54 "preise_ranking_list.js.html"
if (((stash.get('platz') == 5 && stash.get('queue') == 74) || (stash.get('platz') == 3 && stash.get('queue') == 75) || (stash.get('platz') == 6 && stash.get('queue') == 76) || (stash.get('platz') == 4 && stash.get('queue') == 77) || (stash.get('platz') == 3 && stash.get('queue') == 78))) {
output += '\n			<td class="';
//line 52 "preise_ranking_list.js.html"
output += stash.get('class');
output += '" align="left" valign="middle"><div><img src="/pics/microsite/moposportschau/t_alle_aktie.jpg" ></div></td>\n			<td class="';
//line 53 "preise_ranking_list.js.html"
output += stash.get('class');
output += '" align="left" valign="middle"><div>10 Aktien der<br>YUR.tv AG</div></td>\n			';
}

output += '\n			\n			';
//line 59 "preise_ranking_list.js.html"
if ((stash.get('platz') == 1 && stash.get('queue') == 75)) {
output += '\n			<td class="';
//line 57 "preise_ranking_list.js.html"
output += stash.get('class');
output += '" align="left" valign="middle"><div><img src="/pics/microsite/moposportschau/t2p1.jpg" ></div></td>\n			<td class="';
//line 58 "preise_ranking_list.js.html"
output += stash.get('class');
output += '" align="left" valign="middle"><div>ein 300 Euro Freibier-Gut-<br>schein in der Kneipe &quot;Ente&quot;<br>von Holli und Toddi</div></td>\n			';
}

output += '\n			\n			';
//line 64 "preise_ranking_list.js.html"
if ((stash.get('platz') == 1 && stash.get('queue') == 76)) {
output += '\n			<td class="';
//line 62 "preise_ranking_list.js.html"
output += stash.get('class');
output += '" align="left" valign="middle"><div><img src="/pics/microsite/moposportschau/t3p1.jpg" ></div></td>\n			<td class="';
//line 63 "preise_ranking_list.js.html"
output += stash.get('class');
output += '" align="left" valign="middle"><div>1 signiertes Trikot und 1<br>signierter Ball des HSV<br>Handballs</div></td>\n			';
}

output += '\n			';
//line 68 "preise_ranking_list.js.html"
if (((stash.get('platz') == 2 || stash.get('platz') == 3 || stash.get('platz') == 4) && stash.get('queue') == 76)) {
output += '\n			<td class="';
//line 66 "preise_ranking_list.js.html"
output += stash.get('class');
output += '" align="left" valign="middle"><div><img src="/pics/microsite/moposportschau/t3p2_4.jpg" ></div></td>\n			<td class="';
//line 67 "preise_ranking_list.js.html"
output += stash.get('class');
output += '" align="left" valign="middle"><div>2 Freikarten f&uuml;r das Champ-<br>ionsleague Spiel des HSV<br>Handball am 25.11.2007</div></td>\n			';
}

output += '\n			';
//line 72 "preise_ranking_list.js.html"
if (((stash.get('platz') == 1 || stash.get('platz') == 2) && stash.get('queue') == 77)) {
output += '\n			<td class="';
//line 70 "preise_ranking_list.js.html"
output += stash.get('class');
output += '" align="left" valign="middle"><div><img src="/pics/microsite/moposportschau/t4p1_2.jpg" ></div></td>\n			<td class="';
//line 71 "preise_ranking_list.js.html"
output += stash.get('class');
output += '" align="left" valign="middle"><div>2 Ehrenkarten f&uuml;r die &quot;Pro-<br>Sieben FightNight&quot; am 7.12.<br>Hamburg</div></td>\n			';
}

output += '\n			';
//line 76 "preise_ranking_list.js.html"
if ((stash.get('platz') == 1 && stash.get('queue') == 78)) {
output += '\n			<td class="';
//line 74 "preise_ranking_list.js.html"
output += stash.get('class');
output += '" align="left" valign="middle"><div><img src="/pics/microsite/moposportschau/t5p1.jpg" ></div></td>\n			<td class="';
//line 75 "preise_ranking_list.js.html"
output += stash.get('class');
output += '" align="left" valign="middle"><div>2 VIP-Karten f&uuml;r das Spiel<br>HSV gegen Energie Cottbus</div></td>\n			';
}

output += '\n			';
//line 80 "preise_ranking_list.js.html"
if ((stash.get('platz') == 2 && stash.get('queue') == 78)) {
output += '\n			<td class="';
//line 78 "preise_ranking_list.js.html"
output += stash.get('class');
output += '" align="left" valign="middle"><div><img src="/pics/microsite/moposportschau/t5p2.jpg" ></div></td>\n			<td class="';
//line 79 "preise_ranking_list.js.html"
output += stash.get('class');
output += '" align="left" valign="middle"><div>1 signiertes Trikot<br>des HSV</div></td>\n			';
}

output += '\n			\n			<td class="';
//line 82 "preise_ranking_list.js.html"
output += stash.get('class');
output += '"><div style="overflow:hidden; width:280px;">';
//line 82 "preise_ranking_list.js.html"
output += stash.get(['p', 0, 'movie_title', 0]);
output += '</div></td>\n			<td class="';
//line 83 "preise_ranking_list.js.html"
output += stash.get('class');
output += '"><div><span class="alias"><a href="/user/';
//line 83 "preise_ranking_list.js.html"
output += stash.get(['p', 0, 'alias', 0]);
output += '"><div style="overflow:hidden; width:100px;">';
//line 83 "preise_ranking_list.js.html"
output += stash.get(['p', 0, 'alias', 0]);
output += '</div></a></span></div></td>\n			<td class="';
//line 84 "preise_ranking_list.js.html"
output += stash.get('class');
output += '">&nbsp;</td>\n		  </tr>\n		  ';
}
else {
output += '\n		  <tr>\n		  	<td class="';
//line 88 "preise_ranking_list.js.html"
output += stash.get('class');
output += ' border_left">&nbsp;</td>\n			<td class="';
//line 89 "preise_ranking_list.js.html"
output += stash.get('class');
output += '" align="center"><div>';
//line 89 "preise_ranking_list.js.html"
output += stash.get('count') + 1 + (stash.get(['pagination', 0, 'entries_per_page', 0]) * (stash.get(['pagination', 0, 'curr', 0]) - 1));
output += '</div></td>\n			<td class="';
//line 90 "preise_ranking_list.js.html"
output += stash.get('class');
output += '" colspan="2"><div>&nbsp;</div></td>\n			<td class="';
//line 91 "preise_ranking_list.js.html"
output += stash.get('class');
output += '"><div style="overflow:hidden; width:280px;">';
//line 91 "preise_ranking_list.js.html"
output += stash.get(['p', 0, 'movie_title', 0]);
output += '</div></td>\n			<td class="';
//line 92 "preise_ranking_list.js.html"
output += stash.get('class');
output += '"><div><span class="alias"><a href="/user/';
//line 92 "preise_ranking_list.js.html"
output += stash.get(['p', 0, 'alias', 0]);
output += '"><div style="overflow:hidden; width:100px;">';
//line 92 "preise_ranking_list.js.html"
output += stash.get(['p', 0, 'alias', 0]);
output += '</div></a></span></div></td>\n			<td class="';
//line 93 "preise_ranking_list.js.html"
output += stash.get('class');
output += ' border_right">&nbsp;</td>\n		  </tr>\n		  ';
}

output += '\n		  ';
//line 96 "preise_ranking_list.js.html"
stash.set('count', stash.get('count') + 1);
output += '\n		';;
            retval = list.get_next();
            value = retval[0];
            done = retval[1];
        }
    }
    catch(e) {
        throw(context.set_error(e, output));
    }
    stash.set('loop', oldloop);
})();

output += '\n	';
}
else {
output += '\n		<tr><th class="bg"><div align="center">Zur Zeit befinden sich keine Eintr&auml;ge in der Datenbank.</div></td></tr>\n	';
}

output += '\n	\n		<tr>\n			<td colspan="7">\n				<table id="footer" cellspacing="0" cellpadding="0" border="0" width="100%">\n					<tr>\n						<td class="left">&nbsp;</td>\n						<td class="bg " width="90"><strong>Seite ';
//line 107 "preise_ranking_list.js.html"
output += stash.get(['pagination', 0, 'curr', 0]);
output += ' von ';
//line 107 "preise_ranking_list.js.html"
output += stash.get(['pagination', 0, 'last', 0]);
output += '</strong></td>\n						<td class="bg">';
//line 108 "preise_ranking_list.js.html"
if ((stash.get(['pagination', 0, 'pages', 0]) > 1)) {
//line 108 "preise_ranking_list.js.html"
output += context.include('preise_ranking_pagination.js.html');
}
else {
output += '&nbsp;';
}

output += '</td>\n						<td class="bg" align="right" width="180">Gehe zur Seite <input id="seite" type="text" style="width:20px" maxlength="3">&nbsp;&nbsp;<input id="LosButton" type="button" value="Los" onclick="__Yur.preisranking.getPageForm(\'seite\')">&nbsp;&nbsp;&nbsp;</td>\n						<td class="right">&nbsp;</td>\n					</tr>\n				</table>\n			</td>\n		</tr>\n	</table>\n	';
    }
    catch(e) {
        var error = context.set_error(e, output);
        throw(error);
    }

    return output;
}

Jemplate.templateMap['preise_ranking_pagination.js.html'] = function(context) {
    if (! context) throw('Jemplate function called without context\n');
    var stash = context.stash;
    var output = '';

    try {
output += '	';
//line 1 "preise_ranking_pagination.js.html"
stash.set('pagination', '');
output += '\n	';
//line 2 "preise_ranking_pagination.js.html"
stash.set('span', '');
output += '\n	';
//line 3 "preise_ranking_pagination.js.html"
stash.set('pa', stash.get(['model', 0, 'pagination', 0]));
output += '\n	';
//line 4 "preise_ranking_pagination.js.html"
if ((stash.get(['pa', 0, 'first', 0]) >= 5 || stash.get(['pa', 0, 'last', 0]) >= 1)) {
//line 4 "preise_ranking_pagination.js.html"
stash.set('pagination', 'paginationPlatzSparen');
}

output += '\n	';
//line 5 "preise_ranking_pagination.js.html"
if ((stash.get(['pa', 0, 'first', 0]) >= 50 || stash.get(['pa', 0, 'last', 0]) >= 1)) {
//line 5 "preise_ranking_pagination.js.html"
stash.set('span', 'spanPlatzSparen');
}

output += '\n	<div class="paginationContainerRanking">\n	  <div class="pagination ';
//line 7 "preise_ranking_pagination.js.html"
output += stash.get('pagination');
output += '">\n		<!--div class="rechts">\n			<span class="cursor';
//line 9 "preise_ranking_pagination.js.html"
if ((! stash.get(['pa', 0, 'forward', 0]))) {
output += ' disabled';
}

output += '" onclick="__Yur.preisranking.getPage(';
//line 9 "preise_ranking_pagination.js.html"
output += stash.get(['pa', 0, 'last', 0]);
output += ')">\n				&gt;&gt;\n			</span>\n		</div-->\n		<!--div class="links">\n			<span class="cursor';
//line 14 "preise_ranking_pagination.js.html"
if ((! stash.get(['pa', 0, 'back', 0]))) {
output += ' disabled';
}

output += '" onclick="__Yur.preisranking.getPage(';
//line 14 "preise_ranking_pagination.js.html"
output += stash.get(['pa', 0, 'first', 0]);
output += ')">\n				&lt;&lt;\n			</span>\n		</div-->\n		';
//line 18 "preise_ranking_pagination.js.html"
stash.set('count', 0);
output += '\n		<div class="mitte">\n			<span class="cursor';
//line 20 "preise_ranking_pagination.js.html"
if ((! stash.get(['pa', 0, 'back', 0]))) {
output += ' disabled';
}

output += '" onclick="__Yur.preisranking.getPage(';
//line 20 "preise_ranking_pagination.js.html"
output += stash.get(['pa', 0, 'back', 0]);
output += ')">\n				&lt;&nbsp;zur&uuml;ck\n			</span>&nbsp;\n		';
//line 27 "preise_ranking_pagination.js.html"

// FOREACH 
(function() {
    var list = stash.get(['pa', 0, 'steps', 0]);
    list = new Jemplate.Iterator(list);
    var retval = list.get_first();
    var value = retval[0];
    var done = retval[1];
    var oldloop;
    try { oldloop = stash.get('loop') } finally {}
    stash.set('loop', list);
    try {
        while (! done) {
            stash.data['step'] = value;
output += '\n			';
//line 24 "preise_ranking_pagination.js.html"
if ((stash.get('count'))) {
output += '|';
}

output += '\n			';
//line 25 "preise_ranking_pagination.js.html"
if ((stash.get(['pa', 0, 'curr', 0]) != stash.get('step'))) {
output += '<span class="cursor ';
//line 25 "preise_ranking_pagination.js.html"
output += stash.get('span');
output += '" onclick="__Yur.preisranking.getPage(';
//line 25 "preise_ranking_pagination.js.html"
output += stash.get('step');
output += ')">';
}
else {
output += '<span class="act ';
//line 25 "preise_ranking_pagination.js.html"
output += stash.get('span');
output += '">';
}

//line 25 "preise_ranking_pagination.js.html"
output += stash.get(['tool', 0, 'format_ranking_pagination_steps_with_first', [ stash.get('step'), stash.get(['pa', 0, 'entries_per_page', 0]), stash.get(['pa', 0, 'total_entries', 0]), stash.get(['pa', 0, 'first_site_entries', 0]) ]]);
output += '</span>\n			';
//line 26 "preise_ranking_pagination.js.html"
stash.set('count', stash.get('count') + 1);
output += '\n		';;
            retval = list.get_next();
            value = retval[0];
            done = retval[1];
        }
    }
    catch(e) {
        throw(context.set_error(e, output));
    }
    stash.set('loop', oldloop);
})();

output += '\n			&nbsp;<span class="cursor';
//line 28 "preise_ranking_pagination.js.html"
if ((! stash.get(['pa', 0, 'forward', 0]))) {
output += ' disabled';
}

output += '" onclick="__Yur.preisranking.getPage(';
//line 28 "preise_ranking_pagination.js.html"
output += stash.get(['pa', 0, 'forward', 0]);
output += ')">\n				weiter&nbsp;&gt;\n			</span>\n		</div>\n	  </div>\n	</div>';
    }
    catch(e) {
        var error = context.set_error(e, output);
        throw(error);
    }

    return output;
}

Jemplate.templateMap['queue_item.js.html'] = function(context) {
    if (! context) throw('Jemplate function called without context\n');
    var stash = context.stash;
    var output = '';

    try {
//line 1 "queue_item.js.html"
stash.set('item', stash.get('model'));
output += '\n';
//line 2 "queue_item.js.html"
stash.set('movie', stash.get(['item', 0, 'movie_', 0]));
output += '\n';
//line 3 "queue_item.js.html"
stash.set('id', stash.get(['item', 0, 'id', 0]));
output += '\n';
//line 4 "queue_item.js.html"
stash.set('user', stash.get(['movie', 0, 'uploader_', 0]));
output += '\n';
//line 5 "queue_item.js.html"
stash.set('votes', stash.get(['movie', 0, 'vote_counter', 0]));
output += '\n';
//line 6 "queue_item.js.html"
if ((stash.get('votes') == stash.get('null'))) {
//line 6 "queue_item.js.html"
stash.set('votes', 0);
}

output += '\n	<div id="QueueSwitch">\n	<div id="queueItem';
//line 8 "queue_item.js.html"
output += stash.get('id');
output += '" class="';
//line 8 "queue_item.js.html"
output += stash.get(['item', 0, 'divClass', 0]);
output += '">\n		<!--div style="position:relative; width:329px; height:73px;"-->\n		\n			<div class="thumbContainer">\n				<div class="imgBorder" id="itemThumb';
//line 12 "queue_item.js.html"
output += stash.get('id');
output += '"><a href="javascript:__Yur.moviePreview.show(';
//line 12 "queue_item.js.html"
output += stash.get(['movie', 0, 'id', 0]);
output += ')"><img src="/movies/';
//line 12 "queue_item.js.html"
output += stash.get(['movie', 0, 'path', 0]);
output += '/screen1.jpg" width="80" height="60" /></a></div>\n				<div class="imgBorder" id="itemPreview';
//line 13 "queue_item.js.html"
output += stash.get('id');
output += '" style="display:none"></div>\n			</div>\n			\n			<div class="linepos"><div class="line"><img src="/pics/t.gif" height="1" width="1"></div></div>\n			\n			<div class="queueItemPositionContainer"><div id="queueItemPosition';
//line 18 "queue_item.js.html"
output += stash.get('id');
output += '">';
//line 18 "queue_item.js.html"
output += stash.get(['item', 0, 'position', 0]);
output += '</div></div>\n			\n			<div class="buttenSchnellerContainer" id="queueItemUp';
//line 20 "queue_item.js.html"
output += stash.get('id');
output += '">';
//line 20 "queue_item.js.html"
if (stash.get(['item', 0, 'position', 0]) > 1) {
output += '<a href="javascript:__Yur.queue.items[';
//line 20 "queue_item.js.html"
output += stash.get('id');
output += '].voting.vote(2)" onmouseout="MM_swapImgRestore()" onmouseover="MM_swapImage(\'schnellerbtn';
//line 20 "queue_item.js.html"
output += stash.get('id');
output += '\',\'\',\'/pics/navi/schneller_act.gif\',1)"><img src="/pics/navi/schneller.gif" name="schnellerbtn';
//line 20 "queue_item.js.html"
output += stash.get('id');
output += '" border="0" id="schnellerbtn';
//line 20 "queue_item.js.html"
output += stash.get('id');
output += '" /></a>';
}

output += '</div>\n			<div class="buttonSpaeterContainer" id="queueItemDown';
//line 21 "queue_item.js.html"
output += stash.get('id');
output += '">';
//line 21 "queue_item.js.html"
if (stash.get(['item', 0, 'position', 0]) > 1) {
output += '<a href="javascript:__Yur.queue.items[';
//line 21 "queue_item.js.html"
output += stash.get('id');
output += '].voting.vote(-2)" onmouseout="MM_swapImgRestore()" onmouseover="MM_swapImage(\'spaeterbtn';
//line 21 "queue_item.js.html"
output += stash.get('id');
output += '\',\'\',\'/pics/navi/spaeter_act.gif\',1)"><img src="/pics/navi/spaeter.gif" name="spaeterbtn';
//line 21 "queue_item.js.html"
output += stash.get('id');
output += '" border="0" id="spaeterbtn';
//line 21 "queue_item.js.html"
output += stash.get('id');
output += '" /></a>';
}

output += '</div>\n			\n			<div class="nameContainer">\n				<span class="alias cursor"><a href="/user/';
//line 24 "queue_item.js.html"
output += stash.get(['user', 0, 'alias', 0]);
output += '">';
//line 24 "queue_item.js.html"
output += stash.get(['user', 0, 'alias', 0]);
output += '</a></span><span id="itemScore';
//line 24 "queue_item.js.html"
output += stash.get('id');
output += '" style="display:none">';
//line 24 "queue_item.js.html"
output += stash.get(['item', 0, 'score', 0]);
output += '</span>';
//line 24 "queue_item.js.html"
if ((stash.get(['movie', 0, 'validiert', 0]) == 1)) {
output += '<span> (';
//line 24 "queue_item.js.html"
if ((stash.get(['user', 0, 'stock_points', 0]) > 0)) {
//line 24 "queue_item.js.html"
output += stash.get(['user', 0, 'stock_points', 0]) / 100;
}
else {
output += '0';
}

output += ' P.):</span>';
}
else {
output += '<span> (Video noch nicht gepr&uuml;ft)</span>';
}

output += '\n			</div>\n			\n			<div class="titelContainer"><strong>';
//line 27 "queue_item.js.html"
output += stash.get(['movie', 0, 'title', 0]);
output += '</strong></div>\n			\n			<div class="zeitContainer"><span id="itemDuration';
//line 29 "queue_item.js.html"
output += stash.get(['item', 0, 'id', 0]);
output += '">';
//line 29 "queue_item.js.html"
output += stash.get(['tool', 0, 'format_time_period', [ stash.get(['item', 0, 'time_to_play', 0]) ]]);
output += '</span> bis Sendestart</div>  \n				\n			<!--div class="description">';
//line 31 "queue_item.js.html"
output += stash.get(['movie', 0, 'description', 0]);
output += '</div-->\n		\n			<div id="movieTextContainer';
//line 33 "queue_item.js.html"
output += stash.get('id');
output += '"></div>\n		\n		<!--/div-->\n	</div>\n	</div>';
    }
    catch(e) {
        var error = context.set_error(e, output);
        throw(error);
    }

    return output;
}

Jemplate.templateMap['queue_item_charts.js.html'] = function(context) {
    if (! context) throw('Jemplate function called without context\n');
    var stash = context.stash;
    var output = '';

    try {
//line 1 "queue_item_charts.js.html"
stash.set('item', stash.get('model'));
output += '\n';
//line 2 "queue_item_charts.js.html"
stash.set('movie', stash.get(['item', 0, 'movie_', 0]));
output += '\n';
//line 3 "queue_item_charts.js.html"
stash.set('id', stash.get(['item', 0, 'id', 0]));
output += '\n';
//line 4 "queue_item_charts.js.html"
stash.set('user', stash.get(['movie', 0, 'uploader_', 0]));
output += '\n';
//line 5 "queue_item_charts.js.html"
stash.set('votes', stash.get(['movie', 0, 'vote_counter', 0]));
output += '\n';
//line 6 "queue_item_charts.js.html"
if ((stash.get('votes') == stash.get('null'))) {
//line 6 "queue_item_charts.js.html"
stash.set('votes', 0);
}

output += '\n	<div id="QueueSwitch" class="charts">\n	<div id="queueItem';
//line 8 "queue_item_charts.js.html"
output += stash.get('id');
output += '" class="';
//line 8 "queue_item_charts.js.html"
output += stash.get(['item', 0, 'divClass', 0]);
output += '">\n		<!--div style="position:relative; width:329px; height:73px;"-->\n		\n			<div class="thumbContainer">\n				<div class="imgBorder" id="itemThumb';
//line 12 "queue_item_charts.js.html"
output += stash.get('id');
output += '"><a href="javascript:__Yur.moviePreview.show(';
//line 12 "queue_item_charts.js.html"
output += stash.get(['movie', 0, 'id', 0]);
output += ')"><img src="/movies/';
//line 12 "queue_item_charts.js.html"
output += stash.get(['movie', 0, 'path', 0]);
output += '/screen1.jpg" width="80" height="60" /></a></div>\n				<div class="imgBorder" id="itemPreview';
//line 13 "queue_item_charts.js.html"
output += stash.get('id');
output += '" style="display:none"></div>\n			</div>\n			\n			<div class="linepos"><div class="line"><img src="/pics/t.gif" height="1" width="1"></div></div>\n			\n			<div class="queueItemPositionContainer"><div id="queueItemPosition';
//line 18 "queue_item_charts.js.html"
output += stash.get('id');
output += '">';
//line 18 "queue_item_charts.js.html"
output += stash.get(['item', 0, 'position', 0]);
output += '</div></div>\n			\n			<div class="buttenSchnellerContainer" id="queueItemUp';
//line 20 "queue_item_charts.js.html"
output += stash.get('id');
output += '">';
//line 20 "queue_item_charts.js.html"
if (stash.get(['item', 0, 'position', 0]) > 1) {
output += '<a href="javascript:__Yur.queue.items[';
//line 20 "queue_item_charts.js.html"
output += stash.get('id');
output += '].voting.vote(2)" onmouseout="MM_swapImgRestore()" onmouseover="MM_swapImage(\'schnellerbtn';
//line 20 "queue_item_charts.js.html"
output += stash.get('id');
output += '\',\'\',\'/pics/navi/schneller_act.gif\',1)"><img src="/pics/navi/schneller.gif" name="schnellerbtn';
//line 20 "queue_item_charts.js.html"
output += stash.get('id');
output += '" border="0" id="schnellerbtn';
//line 20 "queue_item_charts.js.html"
output += stash.get('id');
output += '" /></a>';
}

output += '</div>\n			<div class="buttonSpaeterContainer" id="queueItemDown';
//line 21 "queue_item_charts.js.html"
output += stash.get('id');
output += '">';
//line 21 "queue_item_charts.js.html"
if (stash.get(['item', 0, 'position', 0]) > 1) {
output += '<a href="javascript:__Yur.queue.items[';
//line 21 "queue_item_charts.js.html"
output += stash.get('id');
output += '].voting.vote(-2)" onmouseout="MM_swapImgRestore()" onmouseover="MM_swapImage(\'spaeterbtn';
//line 21 "queue_item_charts.js.html"
output += stash.get('id');
output += '\',\'\',\'/pics/navi/spaeter_act.gif\',1)"><img src="/pics/navi/spaeter.gif" name="spaeterbtn';
//line 21 "queue_item_charts.js.html"
output += stash.get('id');
output += '" border="0" id="spaeterbtn';
//line 21 "queue_item_charts.js.html"
output += stash.get('id');
output += '" /></a>';
}

output += '</div>\n			\n			<div class="nameContainer">\n				<span class="alias cursor"><a href="/user/';
//line 24 "queue_item_charts.js.html"
output += stash.get(['user', 0, 'alias', 0]);
output += '">';
//line 24 "queue_item_charts.js.html"
output += stash.get(['user', 0, 'alias', 0]);
output += '</a></span>\n			</div>\n			\n			<div class="titelContainer"><strong>';
//line 27 "queue_item_charts.js.html"
output += stash.get(['movie', 0, 'title', 0]);
output += ' (';
//line 27 "queue_item_charts.js.html"
output += stash.get(['movie', 0, 'charts_aktuell_element', 0, 'points', 0]) / 100;
output += '&nbsp;P.)</strong>';
//line 27 "queue_item_charts.js.html"
if ((stash.get(['movie', 0, 'validiert', 0]) != 1)) {
output += '<span> (Video noch nicht gepr&uuml;ft)</span>';
}

output += '</div>\n			\n			<div class="zeitContainer"><span id="itemDuration';
//line 29 "queue_item_charts.js.html"
output += stash.get(['item', 0, 'id', 0]);
output += '">';
//line 29 "queue_item_charts.js.html"
output += stash.get(['tool', 0, 'format_time_period', [ stash.get(['item', 0, 'time_to_play', 0]) ]]);
output += '</span> bis Sendestart</div>  \n			\n			<div class="orangeBox">\n			\n				';
//line 33 "queue_item_charts.js.html"
stash.set('tendenz', '');
output += '\n				';
//line 34 "queue_item_charts.js.html"
if ((stash.get(['movie', 0, 'charts_aktuell_element', 0, 'position', 0]) * 1 > stash.get(['movie', 0, 'charts_aktuell_element', 0, 'position_befor', 0]) * 1)) {
//line 34 "queue_item_charts.js.html"
stash.set('tendenz', 'runter');
}

output += '\n				';
//line 35 "queue_item_charts.js.html"
if ((stash.get(['movie', 0, 'charts_aktuell_element', 0, 'position', 0]) * 1 < stash.get(['movie', 0, 'charts_aktuell_element', 0, 'position_befor', 0]) * 1)) {
//line 35 "queue_item_charts.js.html"
stash.set('tendenz', 'hoch');
}

output += '\n				';
//line 36 "queue_item_charts.js.html"
if ((stash.get(['movie', 0, 'charts_aktuell_element', 0, 'position', 0]) * 1 == stash.get(['movie', 0, 'charts_aktuell_element', 0, 'position_befor', 0]) * 1)) {
//line 36 "queue_item_charts.js.html"
stash.set('tendenz', 'gleich');
}

output += '\n				';
//line 37 "queue_item_charts.js.html"
if ((stash.get(['movie', 0, 'charts_aktuell_element', 0, 'position_befor', 0]) * 1 == 0)) {
//line 37 "queue_item_charts.js.html"
stash.set('tendenz', 'neu');
}

output += '\n				\n				\n				<table cellspacing="0" cellpadding="0" border="0">\n					<tr>\n						<td width="28" height="19" align="center" valign="middle">';
//line 42 "queue_item_charts.js.html"
if ((stash.get('tendenz') == 'neu')) {
output += '<img src="/pics/charts/q_neu.gif" width="24" height="15" border="0">';
}
else {
output += '<img src="/pics/charts/tendenz_q_';
//line 42 "queue_item_charts.js.html"
output += stash.get('tendenz');
output += '.gif" width="14" height="14" border="0">';
}

output += '</td>\n						<td width="35" align="right" valign="middle" class="chartsposition">';
//line 43 "queue_item_charts.js.html"
if ((stash.get('tendenz') == 'neu')) {
output += '&nbsp;';
}
else {
output += '<strong>';
//line 43 "queue_item_charts.js.html"
output += stash.get(['movie', 0, 'charts_aktuell_element', 0, 'position', 0]);
output += '.</strong>';
}

output += '</td>\n						<td valign="middle" class="chartstext">&nbsp;&nbsp;';
//line 44 "queue_item_charts.js.html"
if ((stash.get('tendenz') == 'neu')) {
output += 'Diese Woche neu in den <a href="/charts">Charts</a>';
}
else {
output += 'Platz in den aktuellen <a href="/charts">Charts</a>';
}

output += '</td>\n					</tr>\n				</table>\n			</div>\n				\n			<!--div class="description">';
//line 49 "queue_item_charts.js.html"
output += stash.get(['movie', 0, 'description', 0]);
output += '</div-->\n		\n			<div id="movieTextContainer';
//line 51 "queue_item_charts.js.html"
output += stash.get('id');
output += '"></div>\n		\n		<!--/div-->\n	</div>\n	</div>';
    }
    catch(e) {
        var error = context.set_error(e, output);
        throw(error);
    }

    return output;
}

Jemplate.templateMap['queue_pagination.js.html'] = function(context) {
    if (! context) throw('Jemplate function called without context\n');
    var stash = context.stash;
    var output = '';

    try {
output += '	';
//line 1 "queue_pagination.js.html"
stash.set('pagination', '');
output += '\n	';
//line 2 "queue_pagination.js.html"
stash.set('span', '');
output += '\n	';
//line 3 "queue_pagination.js.html"
if ((stash.get(['pa', 0, 'first', 0]) >= 100 || stash.get(['pa', 0, 'last', 0]) >= 100)) {
//line 3 "queue_pagination.js.html"
stash.set('pagination', 'paginationPlatzSparen');
}

output += '\n	';
//line 4 "queue_pagination.js.html"
if ((stash.get(['pa', 0, 'first', 0]) >= 1000 || stash.get(['pa', 0, 'last', 0]) >= 1000)) {
//line 4 "queue_pagination.js.html"
stash.set('span', 'spanPlatzSparen');
}

output += '\n	<div class="pagination ';
//line 5 "queue_pagination.js.html"
output += stash.get('pagination');
output += '">\n		<div class="rechts">\n			<span class="cursor';
//line 7 "queue_pagination.js.html"
if ((! stash.get(['pa', 0, 'forward', 0]))) {
output += ' disabled';
}

output += '" onclick="__Yur.getQueuePage(';
//line 7 "queue_pagination.js.html"
output += stash.get(['pa', 0, 'last', 0]);
output += ')">\n				&gt;&gt;\n			</span>\n		</div>\n		<div class="links">\n			<span class="cursor';
//line 12 "queue_pagination.js.html"
if ((! stash.get(['pa', 0, 'back', 0]))) {
output += ' disabled';
}

output += '" onclick="__Yur.getQueuePage(';
//line 12 "queue_pagination.js.html"
output += stash.get(['pa', 0, 'first', 0]);
output += ')">\n				&lt;&lt;\n			</span>\n		</div>\n		';
//line 16 "queue_pagination.js.html"
stash.set('count', 0);
output += '\n		<div class="mitte">\n			<span class="cursor';
//line 18 "queue_pagination.js.html"
if ((! stash.get(['pa', 0, 'back', 0]))) {
output += ' disabled';
}

output += '" onclick="__Yur.getQueuePage(';
//line 18 "queue_pagination.js.html"
output += stash.get(['pa', 0, 'back', 0]);
output += ')">\n				&lt;\n			</span>&nbsp;\n		';
//line 25 "queue_pagination.js.html"

// FOREACH 
(function() {
    var list = stash.get(['pa', 0, 'steps', 0]);
    list = new Jemplate.Iterator(list);
    var retval = list.get_first();
    var value = retval[0];
    var done = retval[1];
    var oldloop;
    try { oldloop = stash.get('loop') } finally {}
    stash.set('loop', list);
    try {
        while (! done) {
            stash.data['step'] = value;
output += '\n			';
//line 22 "queue_pagination.js.html"
if ((stash.get('count'))) {
output += '|';
}

output += '\n			';
//line 23 "queue_pagination.js.html"
if ((stash.get(['pa', 0, 'curr', 0]) != stash.get('step'))) {
output += '<span class="cursor ';
//line 23 "queue_pagination.js.html"
output += stash.get('span');
output += '" onclick="__Yur.getQueuePage(';
//line 23 "queue_pagination.js.html"
output += stash.get('step');
output += ')">';
}
else {
output += '<span class="act ';
//line 23 "queue_pagination.js.html"
output += stash.get('span');
output += '">';
}

//line 23 "queue_pagination.js.html"
output += stash.get('step');
output += '</span>\n			';
//line 24 "queue_pagination.js.html"
stash.set('count', stash.get('count') + 1);
output += '\n		';;
            retval = list.get_next();
            value = retval[0];
            done = retval[1];
        }
    }
    catch(e) {
        throw(context.set_error(e, output));
    }
    stash.set('loop', oldloop);
})();

output += '\n			&nbsp;<span class="cursor';
//line 26 "queue_pagination.js.html"
if ((! stash.get(['pa', 0, 'forward', 0]))) {
output += ' disabled';
}

output += '" onclick="__Yur.getQueuePage(';
//line 26 "queue_pagination.js.html"
output += stash.get(['pa', 0, 'forward', 0]);
output += ')">\n				&gt;\n			</span>\n		</div>\n	</div>';
    }
    catch(e) {
        var error = context.set_error(e, output);
        throw(error);
    }

    return output;
}

Jemplate.templateMap['ranking_first3.js.html'] = function(context) {
    if (! context) throw('Jemplate function called without context\n');
    var stash = context.stash;
    var output = '';

    try {
output += '\n';
//line 2 "ranking_first3.js.html"
stash.set('pagination', stash.get(['model', 0, 'pagination', 0]));
output += '\n\n';
//line 32 "ranking_first3.js.html"
if ((stash.get(['pagination', 0, 'curr', 0]) == 1)) {
output += '\n	';
//line 31 "ranking_first3.js.html"
if ((stash.get(['pagination', 0, 'total_entries', 0]))) {
output += '\n		';
//line 6 "ranking_first3.js.html"
stash.set('count', 0);
output += '\n		';
//line 11 "ranking_first3.js.html"
if ((stash.get(['pagination', 0, 'first_entry_on_page', 0]) == 1)) {
output += '\n			';
//line 8 "ranking_first3.js.html"
stash.set('list', stash.get(['model', 0, 'firstthreelist', 0]));
output += '\n		';
}
else {
output += '\n			';
//line 10 "ranking_first3.js.html"
stash.set('list', stash.get(['model', 0, 'firstthreelist', 0]));
output += '\n		';
}

output += '\n		';
//line 28 "ranking_first3.js.html"

// FOREACH 
(function() {
    var list = stash.get('list');
    list = new Jemplate.Iterator(list);
    var retval = list.get_first();
    var value = retval[0];
    var done = retval[1];
    var oldloop;
    try { oldloop = stash.get('loop') } finally {}
    stash.set('loop', list);
    try {
        while (! done) {
            stash.data['p'] = value;
output += '\n		  ';
//line 13 "ranking_first3.js.html"
stash.set('platz', stash.get(['pagination', 0, 'first_entry_on_page', 0]) + stash.get('count'));
output += '\n		  ';
//line 14 "ranking_first3.js.html"
stash.set('class', '');
output += '\n		  ';
//line 15 "ranking_first3.js.html"
stash.set('image', '');
output += '\n		  ';
//line 16 "ranking_first3.js.html"
if ((stash.get('platz') == 1)) {
//line 16 "ranking_first3.js.html"
stash.set('class', 'first');
//line 16 "ranking_first3.js.html"
stash.set('image', stash.get(['p', 0, 'image_html_big', 0]));
}

output += '\n		  ';
//line 17 "ranking_first3.js.html"
if ((stash.get('platz') == 2)) {
//line 17 "ranking_first3.js.html"
stash.set('class', 'second');
//line 17 "ranking_first3.js.html"
stash.set('image', stash.get(['p', 0, 'image_html_small', 0]));
}

output += '\n		  ';
//line 18 "ranking_first3.js.html"
if ((stash.get('platz') == 3)) {
//line 18 "ranking_first3.js.html"
stash.set('class', 'third');
//line 18 "ranking_first3.js.html"
stash.set('image', stash.get(['p', 0, 'image_html_small', 0]));
}

output += '\n		  ';
//line 26 "ranking_first3.js.html"
if ((stash.get('platz') <= 3)) {
output += '\n			';
//line 20 "ranking_first3.js.html"
if ((stash.get('image') != stash.get('null'))) {
output += '<div id="';
//line 20 "ranking_first3.js.html"
output += stash.get('class');
output += 'pic"><table cellpadding="0" cellspacing="0" border="0"><tr><td><div id="picContainer"><table cellpadding="0" cellspacing="0" border="0"><tr>';
//line 20 "ranking_first3.js.html"
if ((stash.get('platz') == 1)) {
output += '<td valign="middle" align="center" width="138" height="104" style="background-color:#000000;">';
}
else {
output += '<td valign="middle" align="center" width="117" height="88" style="background-color:#000000;">';
}

output += '<a href="/user/';
//line 20 "ranking_first3.js.html"
output += stash.get(['p', 0, 'alias', 0]);
output += '">';
//line 20 "ranking_first3.js.html"
output += stash.get('image');
output += '</a></td></tr></table></div></td></tr></table></div>';
}

output += '\n			<div id="';
//line 21 "ranking_first3.js.html"
output += stash.get('class');
output += 'text">\n				<div class="platz">PLATZ ';
//line 22 "ranking_first3.js.html"
output += stash.get('platz');
output += '</div>\n				';
//line 23 "ranking_first3.js.html"
output += stash.get(['p', 0, 'alias', 0]);
output += '\n				<div class="punkte">';
//line 24 "ranking_first3.js.html"
output += stash.get(['p', 0, 'points', 0]) / 100;
output += ' Punkte</div>\n			</div>	\n		  ';
}

output += '	\n		  ';
//line 27 "ranking_first3.js.html"
stash.set('count', stash.get('count') + 1);
output += '\n		';;
            retval = list.get_next();
            value = retval[0];
            done = retval[1];
        }
    }
    catch(e) {
        throw(context.set_error(e, output));
    }
    stash.set('loop', oldloop);
})();

output += '\n	';
}
else {
output += '\n		<!--Zur Zeit befinden sich keine Eintr&auml;ge in der Datenbank.-->\n	';
}

output += '\n';
}

output += '\n	';
    }
    catch(e) {
        var error = context.set_error(e, output);
        throw(error);
    }

    return output;
}

Jemplate.templateMap['ranking_list.js.html'] = function(context) {
    if (! context) throw('Jemplate function called without context\n');
    var stash = context.stash;
    var output = '';

    try {
output += '\n';
//line 2 "ranking_list.js.html"
stash.set('list', stash.get(['model', 0, 'list', 0]));
output += '\n';
//line 3 "ranking_list.js.html"
stash.set('pagination', stash.get(['model', 0, 'pagination', 0]));
output += '\n\n	<table id="resulttable" cellpadding="0" cellspacing="0" border="0">\n	';
//line 60 "ranking_list.js.html"
if ((stash.get(['pagination', 0, 'total_entries', 0]))) {
output += '\n		<tr>\n			<th class="left">&nbsp;</th>\n			<th class="bg"><div><a href="javascript:__Yur.ranking.changeSorting(1)">PLATZ</a></div></th>\n			<th class="bg"><div>&nbsp;</div></th>\n			<th class="bg"><div><a href="javascript:__Yur.ranking.changeSorting(2)">NAME</a></div></th>\n			<th class="bg"><div><a href="javascript:__Yur.ranking.changeSorting(3)">PUNKTE</a></div></th>\n			<th class="bg"><div><a href="javascript:__Yur.ranking.changeSorting(4)">GESAMT&nbsp;BEITR&Auml;GE</a></div></th>\n			<th class="bg"><div><a href="javascript:__Yur.ranking.changeSorting(5)">ON-AIR-ZEIT</a></div></th>\n			<th class="bg beitrag"><div><a href="javascript:__Yur.ranking.changeSorting(6)">ERFOLGREICHSTER&nbsp;BEITRAG</a></div></th>\n			<th class="bg"><div><a href="javascript:__Yur.ranking.changeSorting(7)">LETZTER&nbsp;BEITRAG</a></div></th>\n			<th class="right">&nbsp;</th>\n		</tr>\n		\n		';
//line 20 "ranking_list.js.html"
stash.set('count', 0);
output += '\n		';
//line 57 "ranking_list.js.html"

// FOREACH 
(function() {
    var list = stash.get('list');
    list = new Jemplate.Iterator(list);
    var retval = list.get_first();
    var value = retval[0];
    var done = retval[1];
    var oldloop;
    try { oldloop = stash.get('loop') } finally {}
    stash.set('loop', list);
    try {
        while (! done) {
            stash.data['p'] = value;
output += '\n		  ';
//line 22 "ranking_list.js.html"
stash.set('platz', stash.get(['pagination', 0, 'first_entry_on_page', 0]) + stash.get('count'));
output += '\n		  ';
//line 23 "ranking_list.js.html"
stash.set('class', '');
output += '\n		  \n		  ';
//line 25 "ranking_list.js.html"
if ((stash.get('platz') > 0 && stash.get('platz') <= 10)) {
//line 25 "ranking_list.js.html"
stash.set('class', 'first10');
}

output += '\n		  ';
//line 26 "ranking_list.js.html"
if ((stash.get('platz') > 10)) {
//line 26 "ranking_list.js.html"
stash.set('class', 'rest');
}

output += '\n		  ';
//line 27 "ranking_list.js.html"
if ((stash.get('platz') <= 10 && ! (stash.get('count') % 2))) {
//line 27 "ranking_list.js.html"
stash.set('class', stash.get('class')  + ' dunkel1');
}

output += '\n		  ';
//line 28 "ranking_list.js.html"
if ((stash.get('platz') > 10 && ! (stash.get('count') % 2))) {
//line 28 "ranking_list.js.html"
stash.set('class', stash.get('class')  + ' dunkel2');
}

output += '\n		  ';
//line 29 "ranking_list.js.html"
if ((stash.get(['model', 0, 'person', 0]) && stash.get(['p', 0, 'person', 0]) == stash.get(['model', 0, 'person', 0]))) {
//line 29 "ranking_list.js.html"
stash.set('class', stash.get('class')  + ' treffer');
}

output += '\n		  ';
//line 55 "ranking_list.js.html"
if ((stash.get('platz') <= 10)) {
output += '\n		  <tr>\n		  	<td class="';
//line 32 "ranking_list.js.html"
output += stash.get('class');
output += '">&nbsp;</td>\n			<td class="';
//line 33 "ranking_list.js.html"
output += stash.get('class');
output += '" align="center"><div>';
//line 33 "ranking_list.js.html"
output += stash.get(['p', 0, 'position', 0]);
output += '</div></td>\n			<td class="';
//line 34 "ranking_list.js.html"
output += stash.get('class');
output += '" align="center"><div style="padding-right:5px;">';
//line 34 "ranking_list.js.html"
if ((stash.get(['p', 0, 'image_html_topten', 0]))) {
output += '<table cellpadding="0" cellspacing="0" border="0"><tr><td valign="middle" align="center" width="57" height="42" style="background-color:#000000;"><a href="/user/';
//line 34 "ranking_list.js.html"
output += stash.get(['p', 0, 'alias', 0]);
output += '">';
//line 34 "ranking_list.js.html"
output += stash.get(['p', 0, 'image_html_topten', 0]);
output += '</a></td></tr></table>';
}

output += '</div></td>\n			<td class="';
//line 35 "ranking_list.js.html"
output += stash.get('class');
output += '"><div><span class="alias"><a href="/user/';
//line 35 "ranking_list.js.html"
output += stash.get(['p', 0, 'alias', 0]);
output += '"><div style="overflow:hidden; width:100px;">';
//line 35 "ranking_list.js.html"
output += stash.get(['p', 0, 'alias', 0]);
output += '</div></a></span></div></td>\n			<td class="';
//line 36 "ranking_list.js.html"
output += stash.get('class');
output += '" align="center"><div>';
//line 36 "ranking_list.js.html"
output += stash.get(['p', 0, 'points', 0]) / 100;
output += '</div></td>\n			<td class="';
//line 37 "ranking_list.js.html"
output += stash.get('class');
output += '" align="center"><div>';
//line 37 "ranking_list.js.html"
output += stash.get(['p', 0, 'active_movies', 0]);
output += '</div></td>\n			<td class="';
//line 38 "ranking_list.js.html"
output += stash.get('class');
output += '"><div>';
//line 38 "ranking_list.js.html"
output += stash.get(['tool', 0, 'format_advanced_time_period', [ stash.get(['p', 0, 'on_air_time', 0]) ]]);
output += '</div></td>\n			<td class="';
//line 39 "ranking_list.js.html"
output += stash.get('class');
output += '"><div class="beitrag">';
//line 39 "ranking_list.js.html"
output += stash.get(['p', 0, 'best_movie', 0]);
output += '</div></td>\n			<td class="';
//line 40 "ranking_list.js.html"
output += stash.get('class');
output += '" align="center"><div>';
//line 40 "ranking_list.js.html"
output += stash.get(['tool', 0, 'format_sql_to_german', [ stash.get(['p', 0, 'last_upload', 0]) ]]);
output += '</div></td>\n			<td class="';
//line 41 "ranking_list.js.html"
output += stash.get('class');
output += '">&nbsp;</td>\n		  </tr>\n		  ';
}
else {
output += '\n		  <tr>\n		  	<td class="';
//line 45 "ranking_list.js.html"
output += stash.get('class');
output += ' border_left">&nbsp;</td>\n			<td class="';
//line 46 "ranking_list.js.html"
output += stash.get('class');
output += '" align="center"><div>';
//line 46 "ranking_list.js.html"
output += stash.get(['p', 0, 'position', 0]);
output += '</div></td>\n			<td colspan="2" class="';
//line 47 "ranking_list.js.html"
output += stash.get('class');
output += '"><div><span class="alias"><a href="/user/';
//line 47 "ranking_list.js.html"
output += stash.get(['p', 0, 'alias', 0]);
output += '">';
//line 47 "ranking_list.js.html"
output += stash.get(['p', 0, 'alias', 0]);
output += '</a></span></div></td>\n			<td class="';
//line 48 "ranking_list.js.html"
output += stash.get('class');
output += '" align="center"><div>';
//line 48 "ranking_list.js.html"
output += stash.get(['p', 0, 'points', 0]) / 100;
output += '</div></td>\n			<td class="';
//line 49 "ranking_list.js.html"
output += stash.get('class');
output += '" align="center"><div>';
//line 49 "ranking_list.js.html"
output += stash.get(['p', 0, 'active_movies', 0]);
output += '</div></td>\n			<td class="';
//line 50 "ranking_list.js.html"
output += stash.get('class');
output += '"><div>';
//line 50 "ranking_list.js.html"
output += stash.get(['tool', 0, 'format_advanced_time_period', [ stash.get(['p', 0, 'on_air_time', 0]) ]]);
output += '</div></td>\n			<td class="';
//line 51 "ranking_list.js.html"
output += stash.get('class');
output += '"><div class="beitrag">';
//line 51 "ranking_list.js.html"
output += stash.get(['p', 0, 'best_movie', 0]);
output += '</div></td>\n			<td class="';
//line 52 "ranking_list.js.html"
output += stash.get('class');
output += '" align="center"><div>';
//line 52 "ranking_list.js.html"
output += stash.get(['tool', 0, 'format_sql_to_german', [ stash.get(['p', 0, 'last_upload', 0]) ]]);
output += '</div></td>\n			<td class="';
//line 53 "ranking_list.js.html"
output += stash.get('class');
output += ' border_right">&nbsp;</td>\n		  </tr>\n		  ';
}

output += '\n		  ';
//line 56 "ranking_list.js.html"
stash.set('count', stash.get('count') + 1);
output += '\n		';;
            retval = list.get_next();
            value = retval[0];
            done = retval[1];
        }
    }
    catch(e) {
        throw(context.set_error(e, output));
    }
    stash.set('loop', oldloop);
})();

output += '\n	';
}
else {
output += '\n		<tr><th class="bg"><div align="center">Zur Zeit befinden sich keine Eintr&auml;ge in der Datenbank.</div></td></tr>\n	';
}

output += '\n	\n		<tr>\n			<td colspan="10">\n				<table id="footer" cellspacing="0" cellpadding="0" border="0" width="100%">\n					<tr>\n						<td class="left">&nbsp;</td>\n						<td class="bg " width="90"><strong>Seite ';
//line 67 "ranking_list.js.html"
output += stash.get(['pagination', 0, 'curr', 0]);
output += ' von ';
//line 67 "ranking_list.js.html"
output += stash.get(['pagination', 0, 'last', 0]);
output += '</strong></td>\n						<td class="bg">';
//line 68 "ranking_list.js.html"
if ((stash.get(['pagination', 0, 'pages', 0]) > 1)) {
//line 68 "ranking_list.js.html"
output += context.include('ranking_pagination.js.html');
}
else {
output += '&nbsp;';
}

output += '</td>\n						<td class="bg" align="right" width="180">Gehe zur Seite <input id="seite" type="text" style="width:20px" maxlength="3">&nbsp;&nbsp;<input id="LosButton" type="button" value="Los" onclick="__Yur.ranking.getPageForm(\'seite\')">&nbsp;&nbsp;&nbsp;</td>\n						<td class="right">&nbsp;</td>\n					</tr>\n				</table>\n			</td>\n		</tr>\n	</table>\n	';
    }
    catch(e) {
        var error = context.set_error(e, output);
        throw(error);
    }

    return output;
}

Jemplate.templateMap['ranking_pagination.js.html'] = function(context) {
    if (! context) throw('Jemplate function called without context\n');
    var stash = context.stash;
    var output = '';

    try {
output += '	';
//line 1 "ranking_pagination.js.html"
stash.set('pagination', '');
output += '\n	';
//line 2 "ranking_pagination.js.html"
stash.set('span', '');
output += '\n	';
//line 3 "ranking_pagination.js.html"
stash.set('pa', stash.get(['model', 0, 'pagination', 0]));
output += '\n	';
//line 4 "ranking_pagination.js.html"
if ((stash.get(['pa', 0, 'first', 0]) >= 5 || stash.get(['pa', 0, 'last', 0]) >= 1)) {
//line 4 "ranking_pagination.js.html"
stash.set('pagination', 'paginationPlatzSparen');
}

output += '\n	';
//line 5 "ranking_pagination.js.html"
if ((stash.get(['pa', 0, 'first', 0]) >= 50 || stash.get(['pa', 0, 'last', 0]) >= 1)) {
//line 5 "ranking_pagination.js.html"
stash.set('span', 'spanPlatzSparen');
}

output += '\n	<div class="paginationContainerRanking">\n	  <div class="pagination ';
//line 7 "ranking_pagination.js.html"
output += stash.get('pagination');
output += '">\n		<!--div class="rechts">\n			<span class="cursor';
//line 9 "ranking_pagination.js.html"
if ((! stash.get(['pa', 0, 'forward', 0]))) {
output += ' disabled';
}

output += '" onclick="__Yur.ranking.getPage(';
//line 9 "ranking_pagination.js.html"
output += stash.get(['pa', 0, 'last', 0]);
output += ')">\n				&gt;&gt;\n			</span>\n		</div-->\n		<!--div class="links">\n			<span class="cursor';
//line 14 "ranking_pagination.js.html"
if ((! stash.get(['pa', 0, 'back', 0]))) {
output += ' disabled';
}

output += '" onclick="__Yur.ranking.getPage(';
//line 14 "ranking_pagination.js.html"
output += stash.get(['pa', 0, 'first', 0]);
output += ')">\n				&lt;&lt;\n			</span>\n		</div-->\n		';
//line 18 "ranking_pagination.js.html"
stash.set('count', 0);
output += '\n		<div class="mitte">\n			<span class="cursor';
//line 20 "ranking_pagination.js.html"
if ((! stash.get(['pa', 0, 'back', 0]))) {
output += ' disabled';
}

output += '" onclick="__Yur.ranking.getPage(';
//line 20 "ranking_pagination.js.html"
output += stash.get(['pa', 0, 'back', 0]);
output += ')">\n				&lt;&nbsp;zur&uuml;ck\n			</span>&nbsp;\n		';
//line 27 "ranking_pagination.js.html"

// FOREACH 
(function() {
    var list = stash.get(['pa', 0, 'steps', 0]);
    list = new Jemplate.Iterator(list);
    var retval = list.get_first();
    var value = retval[0];
    var done = retval[1];
    var oldloop;
    try { oldloop = stash.get('loop') } finally {}
    stash.set('loop', list);
    try {
        while (! done) {
            stash.data['step'] = value;
output += '\n			';
//line 24 "ranking_pagination.js.html"
if ((stash.get('count'))) {
output += '|';
}

output += '\n			';
//line 25 "ranking_pagination.js.html"
if ((stash.get(['pa', 0, 'curr', 0]) != stash.get('step'))) {
output += '<span class="cursor ';
//line 25 "ranking_pagination.js.html"
output += stash.get('span');
output += '" onclick="__Yur.ranking.getPage(';
//line 25 "ranking_pagination.js.html"
output += stash.get('step');
output += ')">';
}
else {
output += '<span class="act ';
//line 25 "ranking_pagination.js.html"
output += stash.get('span');
output += '">';
}

//line 25 "ranking_pagination.js.html"
output += stash.get(['tool', 0, 'format_ranking_pagination_steps_with_first', [ stash.get('step'), stash.get(['pa', 0, 'entries_per_page', 0]), stash.get(['pa', 0, 'total_entries', 0]), stash.get(['pa', 0, 'first_site_entries', 0]) ]]);
output += '</span>\n			';
//line 26 "ranking_pagination.js.html"
stash.set('count', stash.get('count') + 1);
output += '\n		';;
            retval = list.get_next();
            value = retval[0];
            done = retval[1];
        }
    }
    catch(e) {
        throw(context.set_error(e, output));
    }
    stash.set('loop', oldloop);
})();

output += '\n			&nbsp;<span class="cursor';
//line 28 "ranking_pagination.js.html"
if ((! stash.get(['pa', 0, 'forward', 0]))) {
output += ' disabled';
}

output += '" onclick="__Yur.ranking.getPage(';
//line 28 "ranking_pagination.js.html"
output += stash.get(['pa', 0, 'forward', 0]);
output += ')">\n				weiter&nbsp;&gt;\n			</span>\n		</div>\n	  </div>\n	</div>';
    }
    catch(e) {
        var error = context.set_error(e, output);
        throw(error);
    }

    return output;
}


// ##########################
// File: /storage/www/yur/www/lib/JSON.js
// ##########################
/*
    json.js
    2007-03-20
    
    

    Public Domain

    This file adds these methods to JavaScript:

        array.toJSONString()
        boolean.toJSONString()
        date.toJSONString()
        number.toJSONString()
        object.toJSONString()
        string.toJSONString()
            These methods produce a JSON text from a JavaScript value.
            It must not contain any cyclical references. Illegal values
            will be excluded.

            The default conversion for dates is to an ISO string. You can
            add a toJSONString method to any date object to get a different
            representation.

        string.parseJSON(filter)
            This method parses a JSON text to produce an object or
            array. It can throw a SyntaxError exception.

            The optional filter parameter is a function which can filter and
            transform the results. It receives each of the keys and values, and
            its return value is used instead of the original value. If it
            returns what it received, then structure is not modified. If it
            returns undefined then the member is deleted.

            Example:

            // Parse the text. If a key contains the string 'date' then
            // convert the value to a date.

            myData = text.parseJSON(function (key, value) {
                return key.indexOf('date') >= 0 ? new Date(value) : value;
            });

    It is expected that these methods will formally become part of the
    JavaScript Programming Language in the Fourth Edition of the
    ECMAScript standard in 2008.

    This file will break programs with improper for..in loops. See
    http://yuiblog.com/blog/2006/09/26/for-in-intrigue/

    This is a reference implementation. You are free to copy, modify, or
    redistribute.

    Use your own copy. It is extremely unwise to load untrusted third party
    code into your pages.
*/

// Augment the basic prototypes if they have not already been augmented.

if (!Object.prototype.toJSONString) {

    Array.prototype.toJSONString = function () {
        var a = ['['],  // The array holding the text fragments.
            b,          // A boolean indicating that a comma is required.
            i,          // Loop counter.
            l = this.length,
            v;          // The value to be stringified.

        function p(s) {

// p accumulates text fragments in an array. It inserts a comma before all
// except the first fragment.

            if (b) {
                a.push(',');
            }
            a.push(s);
            b = true;
        }

// For each value in this array...

        for (i = 0; i < l; i += 1) {
            v = this[i];
            switch (typeof v) {

// Serialize a JavaScript object value. Ignore objects thats lack the
// toJSONString method. Due to a specification error in ECMAScript,
// typeof null is 'object', so watch out for that case.

            case 'object':
                if (v) {
                    if (typeof v.toJSONString === 'function') {
                        p(v.toJSONString());
                    }
                } else {
                    p("null");
                }
                break;

// Otherwise, serialize the value.

            case 'string':
            case 'number':
            case 'boolean':
                p(v.toJSONString());

// Values without a JSON representation are ignored.

            }
        }

// Join all of the fragments together and return.

        a.push(']');
        return a.join('');
    };


    Boolean.prototype.toJSONString = function () {
        return String(this);
    };


    Date.prototype.toJSONString = function () {

// Ultimately, this method will be equivalent to the date.toISOString method.

        function f(n) {

// Format integers to have at least two digits.

            return n < 10 ? '0' + n : n;
        }

        return '"' + this.getFullYear() + '-' +
                f(this.getMonth() + 1) + '-' +
                f(this.getDate()) + 'T' +
                f(this.getHours()) + ':' +
                f(this.getMinutes()) + ':' +
                f(this.getSeconds()) + '"';
    };


    Number.prototype.toJSONString = function () {

// JSON numbers must be finite. Encode non-finite numbers as null.

        return isFinite(this) ? String(this) : "null";
    };


    Object.prototype.toJSONString = function () {
        var a = ['{'],  // The array holding the text fragments.
            b,          // A boolean indicating that a comma is required.
            k,          // The current key.
            v;          // The current value.

        function p(s) {

// p accumulates text fragment pairs in an array. It inserts a comma before all
// except the first fragment pair.

            if (b) {
                a.push(',');
            }
            a.push(k.toJSONString(), ':', s);
            b = true;
        }

// Iterate through all of the keys in the object, ignoring the proto chain.

        for (k in this) {
            if (this.hasOwnProperty(k)) {
                v = this[k];
                switch (typeof v) {

// Serialize a JavaScript object value. Ignore objects that lack the
// toJSONString method. Due to a specification error in ECMAScript,
// typeof null is 'object', so watch out for that case.

                case 'object':
                    if (v) {
                        if (typeof v.toJSONString === 'function') {
                            p(v.toJSONString());
                        }
                    } else {
                        p("null");
                    }
                    break;

            case 'string':
            case 'number':
            case 'boolean':
                    p(v.toJSONString());

// Values without a JSON representation are ignored.

                }
            }
        }

// Join all of the fragments together and return.

        a.push('}');
        return a.join('');
    };


    (function (s) {

// Augment String.prototype. We do this in an immediate anonymous function to
// avoid defining global variables.

// m is a table of character substitutions.

        var m = {
            '\b': '\\b',
            '\t': '\\t',
            '\n': '\\n',
            '\f': '\\f',
            '\r': '\\r',
            '"' : '\\"',
            '\\': '\\\\'
        };


        s.parseJSON = function (filter) {

// Parsing happens in three stages. In the first stage, we run the text against
// a regular expression which looks for non-JSON characters. We are especially
// concerned with '()' and 'new' because they can cause invocation, and '='
// because it can cause mutation. But just to be safe, we will reject all
// unexpected characters.

            try {
                //if (/^("(\\.|[^"\\\n\r])*?"|[,:{}\[\]0-9.\-+Eaeflnr-u \n\r\t])+?$/.
                //        test(this)) {
                        
                if(true) {

// In the second stage we use the eval function to compile the text into a
// JavaScript structure. The '{' operator is subject to a syntactic ambiguity
// in JavaScript: it can begin a block or an object literal. We wrap the text
// in parens to eliminate the ambiguity.

                    var j = eval('(' + this + ')');
					
					return j;

// In the optional third stage, we recursively walk the new structure, passing
// each name/value pair to a filter function for possible transformation.

                    if (typeof filter === 'function') {

                        function walk(k, v) {
                            if (v && typeof v === 'object') {
                                for (var i in v) {
                                    if (v.hasOwnProperty(i)) {
                                        v[i] = walk(i, v[i]);
                                    }
                                }
                            }
                            return filter(k, v);
                        }

                        j = walk('', j);
                    }
                    return j;
                }
            } catch (e) {

// Fall through if the regexp test fails.

            }
            throw new SyntaxError("parseJSON");
        };


        s.toJSONString = function () {

// If the string contains no control characters, no quote characters, and no
// backslash characters, then we can simply slap some quotes around it.
// Otherwise we must also replace the offending characters with safe
// sequences.

            if (/["\\\x00-\x1f]/.test(this)) {
                return '"' + this.replace(/([\x00-\x1f\\"])/g, function(a, b) {
                    var c = m[b];
                    if (c) {
                        return c;
                    }
                    c = b.charCodeAt();
                    return '\\u00' +
                        Math.floor(c / 16).toString(16) +
                        (c % 16).toString(16);
                }) + '"';
            }
            return '"' + this + '"';
        };
    })(String.prototype);
}
// ##########################
// File: /storage/www/yur/www/lib/jsProgressBarHandler.js
// ##########################
/*****************************************************************
 *
 * jsProgressBarHandler 0.1 - by Bramus! - http://www.bram.us/
 *
 * v 0.1 - 2007.08.02 - initial release
 *
 * Licensed under the Creative Commons Attribution 2.5 License - http://creativecommons.org/licenses/by/2.5/
 *
 *****************************************************************/
var JS_BRAMUS;

function init_progressbar_handler(win){
	if (!JS_BRAMUS) { JS_BRAMUS = new Object(); }

	JS_BRAMUS.jsProgressBarHandler = Class.create();
	
	JS_BRAMUS.jsProgressBarHandler.prototype = {
	
		imageWidth			: 240,
		pbArray				: new Object(),
	
		initialize			: function() {
			
			this.initialPos		= (this.imageWidth / 2) * (-1);
			this.pxPerPercent	= (this.imageWidth / 2) / 100;
			
			/*
			$$('span.progressBar').each(function(progressBar) {
				this.buildProgressBar(progressBar);  
			}.bind(this));
			*/
			
			this.buildProgressBar(win.$('progress_bar'));  
			
		},
		
		buildProgressBar	: function(progressBar) {
			var percentage 		= parseInt(progressBar.innerHTML.replace("%",""));
			var id				= progressBar.id;
			
			progressBar.innerHTML = '<img id="' + id + '_percentImage" src="/pics/percentImage.png" alt="0%" style="background-position: 0px 0px;"/> <span id="' + id + '_percentText">0%</span>';
			
			this.setPercentage(id, percentage);
		},
		
		setPercentage		: function(id, percentage) {
		
			if (!win.$('progress_bar')){ return }

			var prevPercentage	= (this.pbArray[id] || 0);
			
			if ((percentage.toString().substring(0,1) == "+") || (percentage.toString().substring(0,1) == "-")) {
				percentage	= prevPercentage + parseInt(percentage);
			}
			
			if (percentage < 0)		percentage = 0;
			if (percentage > 100)	percentage = 100;
			
			if (percentage != prevPercentage) {					
				if (prevPercentage < percentage) {
					prevPercentage++;	
				} else {
					prevPercentage--;	
				}			
			}
			
			this.pbArray[id]	= prevPercentage;
			
			win.$(id + "_percentImage").style.backgroundPosition 	= "" + (this.initialPos + (prevPercentage * this.pxPerPercent)) + "px 0px";
			win.$(id + "_percentImage").alt 						= "" + prevPercentage + "%";
			win.$(id + "_percentImage").title 						= "" + prevPercentage + "%";
			//alert("ist: "+prevPercentage);
			//alert("soll: "+percentage);
			win.$(id + "_percentText").innerHTML = "" + prevPercentage + "%";
										  
			if (percentage != prevPercentage) {
				setTimeout("myJsProgressBarHandler.setPercentage('" + id + "','" + percentage + "')", 10);
				//myJsProgressBarHandler.setPercentage('" + id + "','" + percentage + "');
			}
			
			//alert("done");
			
		},
		
		getPercentage		: function(id) {
			return this.pbArray[id];	
		}
	
	}
}	

function initProgressBarHandler(win) { 
	var mywin = win;
	if (mywin == null) {mywin = window}
	init_progressbar_handler(mywin);
	myJsProgressBarHandler = new JS_BRAMUS.jsProgressBarHandler(); 
}

//Event.observe(window, 'load', initProgressBarHandler, false);
// ##########################
// File: /storage/www/yur/www/lib/mouseXY.js
// ##########################

var mouseX = 0; var mouseY = 0;

function updateXY(e) {
	if (e) {
		mouseX = e.pageX; mouseY = e.pageY;
	} else {
		mouseX = event.clientX; mouseY = event.clientY;
	}
}

document.onmousemove = updateXY;

// ##########################
// File: /storage/www/yur/www/lib/prototype.js
// ##########################
/*  Prototype JavaScript framework, version 1.4.0
 *  (c) 2005 Sam Stephenson <sam@conio.net>
 *
 *  Prototype is freely distributable under the terms of an MIT-style license.
 *  For details, see the Prototype web site: http://prototype.conio.net/
 *
/*--------------------------------------------------------------------------*/

var Prototype = {
  Version: '1.4.0',
  ScriptFragment: '(?:<script.*?>)((\n|\r|.)*?)(?:<\/script>)',

  emptyFunction: function() {},
  K: function(x) {return x}
}

var Class = {
  create: function() {
    return function() {
      this.initialize.apply(this, arguments);
    }
  }
}

var $A = Array.from = function(iterable) {
  if (!iterable) return [];
  if (iterable.toArray) {
    return iterable.toArray();
  } else {
    var results = [];
    for (var i = 0; i < iterable.length; i++)
      results.push(iterable[i]);
    return results;
  }
}

var Abstract = new Object();

Object.extend = function(destination, source) {
  for (property in source) {
    destination[property] = source[property];
  }
  return destination;
}

Object.inspect = function(object) {
  try {
    if (object == undefined) return 'undefined';
    if (object == null) return 'null';
    return object.inspect ? object.inspect() : object.toString();
  } catch (e) {
    if (e instanceof RangeError) return '...';
    throw e;
  }
}

Function.prototype.bind = function() {
  var __method = this, args = $A(arguments), object = args.shift();
  return function() {
    return __method.apply(object, args.concat($A(arguments)));
  }
}

Function.prototype.bindAsEventListener = function(object) {
  var __method = this;
  return function(event) {
    return __method.call(object, event || window.event);
  }
}

Object.extend(Number.prototype, {
  toColorPart: function() {
    var digits = this.toString(16);
    if (this < 16) return '0' + digits;
    return digits;
  },

  succ: function() {
    return this + 1;
  },

  times: function(iterator) {
    $R(0, this, true).each(iterator);
    return this;
  }
});

var Try = {
  these: function() {
    var returnValue;

    for (var i = 0; i < arguments.length; i++) {
      var lambda = arguments[i];
      try {
        returnValue = lambda();
        break;
      } catch (e) {}
    }

    return returnValue;
  }
}

/*--------------------------------------------------------------------------*/

var PeriodicalExecuter = Class.create();
PeriodicalExecuter.prototype = {
  initialize: function(callback, frequency) {
    this.callback = callback;
    this.frequency = frequency;
    this.currentlyExecuting = false;

    this.registerCallback();
  },

  registerCallback: function() {
    setInterval(this.onTimerEvent.bind(this), this.frequency * 1000);
  },

  onTimerEvent: function() {
    if (!this.currentlyExecuting) {
      try {
        this.currentlyExecuting = true;
        this.callback();
      } finally {
        this.currentlyExecuting = false;
      }
    }
  }
}

/*--------------------------------------------------------------------------*/

function $() {
  var elements = new Array();

  for (var i = 0; i < arguments.length; i++) {
    var element = arguments[i];
    if (typeof element == 'string')
      element = document.getElementById(element);

    if (arguments.length == 1)
      return element;

    elements.push(element);
  }

  return elements;
}
Object.extend(String.prototype, {
  stripTags: function() {
    return this.replace(/<\/?[^>]+>/gi, '');
  },

  stripScripts: function() {
    return this.replace(new RegExp(Prototype.ScriptFragment, 'img'), '');
  },

  extractScripts: function() {
    var matchAll = new RegExp(Prototype.ScriptFragment, 'img');
    var matchOne = new RegExp(Prototype.ScriptFragment, 'im');
    return (this.match(matchAll) || []).map(function(scriptTag) {
      return (scriptTag.match(matchOne) || ['', ''])[1];
    });
  },

  evalScripts: function() {
    return this.extractScripts().map(eval);
  },

  escapeHTML: function() {
    var div = document.createElement('div');
    var text = document.createTextNode(this);
    div.appendChild(text);
    return div.innerHTML;
  },

  unescapeHTML: function() {
    var div = document.createElement('div');
    div.innerHTML = this.stripTags();
    return div.childNodes[0] ? div.childNodes[0].nodeValue : '';
  },

  toQueryParams: function() {
    var pairs = this.match(/^\??(.*)$/)[1].split('&');
    return pairs.inject({}, function(params, pairString) {
      var pair = pairString.split('=');
      params[pair[0]] = pair[1];
      return params;
    });
  },

  toArray: function() {
    return this.split('');
  },

  camelize: function() {
    var oStringList = this.split('-');
    if (oStringList.length == 1) return oStringList[0];

    var camelizedString = this.indexOf('-') == 0
      ? oStringList[0].charAt(0).toUpperCase() + oStringList[0].substring(1)
      : oStringList[0];

    for (var i = 1, len = oStringList.length; i < len; i++) {
      var s = oStringList[i];
      camelizedString += s.charAt(0).toUpperCase() + s.substring(1);
    }

    return camelizedString;
  },

  inspect: function() {
    return "'" + this.replace('\\', '\\\\').replace("'", '\\\'') + "'";
  }
});

String.prototype.parseQuery = String.prototype.toQueryParams;

var $break    = new Object();
var $continue = new Object();

var Enumerable = {
  each: function(iterator) {
    var index = 0;
    try {
      this._each(function(value) {
        try {
          iterator(value, index++);
        } catch (e) {
          if (e != $continue) throw e;
        }
      });
    } catch (e) {
      if (e != $break) throw e;
    }
  },

  all: function(iterator) {
    var result = true;
    this.each(function(value, index) {
      result = result && !!(iterator || Prototype.K)(value, index);
      if (!result) throw $break;
    });
    return result;
  },

  any: function(iterator) {
    var result = true;
    this.each(function(value, index) {
      if (result = !!(iterator || Prototype.K)(value, index))
        throw $break;
    });
    return result;
  },

  collect: function(iterator) {
    var results = [];
    this.each(function(value, index) {
      results.push(iterator(value, index));
    });
    return results;
  },

  detect: function (iterator) {
    var result;
    this.each(function(value, index) {
      if (iterator(value, index)) {
        result = value;
        throw $break;
      }
    });
    return result;
  },

  findAll: function(iterator) {
    var results = [];
    this.each(function(value, index) {
      if (iterator(value, index))
        results.push(value);
    });
    return results;
  },

  grep: function(pattern, iterator) {
    var results = [];
    this.each(function(value, index) {
      var stringValue = value.toString();
      if (stringValue.match(pattern))
        results.push((iterator || Prototype.K)(value, index));
    })
    return results;
  },

  include: function(object) {
    var found = false;
    this.each(function(value) {
      if (value == object) {
        found = true;
        throw $break;
      }
    });
    return found;
  },

  inject: function(memo, iterator) {
    this.each(function(value, index) {
      memo = iterator(memo, value, index);
    });
    return memo;
  },

  invoke: function(method) {
    var args = $A(arguments).slice(1);
    return this.collect(function(value) {
      return value[method].apply(value, args);
    });
  },

  max: function(iterator) {
    var result;
    this.each(function(value, index) {
      value = (iterator || Prototype.K)(value, index);
      if (value >= (result || value))
        result = value;
    });
    return result;
  },

  min: function(iterator) {
    var result;
    this.each(function(value, index) {
      value = (iterator || Prototype.K)(value, index);
      if (value <= (result || value))
        result = value;
    });
    return result;
  },

  partition: function(iterator) {
    var trues = [], falses = [];
    this.each(function(value, index) {
      ((iterator || Prototype.K)(value, index) ?
        trues : falses).push(value);
    });
    return [trues, falses];
  },

  pluck: function(property) {
    var results = [];
    this.each(function(value, index) {
      results.push(value[property]);
    });
    return results;
  },

  reject: function(iterator) {
    var results = [];
    this.each(function(value, index) {
      if (!iterator(value, index))
        results.push(value);
    });
    return results;
  },

  sortBy: function(iterator) {
    return this.collect(function(value, index) {
      return {value: value, criteria: iterator(value, index)};
    }).sort(function(left, right) {
      var a = left.criteria, b = right.criteria;
      return a < b ? -1 : a > b ? 1 : 0;
    }).pluck('value');
  },

  toArray: function() {
    return this.collect(Prototype.K);
  },

  zip: function() {
    var iterator = Prototype.K, args = $A(arguments);
    if (typeof args.last() == 'function')
      iterator = args.pop();

    var collections = [this].concat(args).map($A);
    return this.map(function(value, index) {
      iterator(value = collections.pluck(index));
      return value;
    });
  },

  inspect: function() {
    return '#<Enumerable:' + this.toArray().inspect() + '>';
  }
}

Object.extend(Enumerable, {
  map:     Enumerable.collect,
  find:    Enumerable.detect,
  select:  Enumerable.findAll,
  member:  Enumerable.include,
  entries: Enumerable.toArray
});

Object.extend(Array.prototype, Enumerable);

Array.prototype._reverse = Array.prototype.reverse;

Object.extend(Array.prototype, {
  _each: function(iterator) {
    for (var i = 0; i < this.length; i++)
      iterator(this[i]);
  },

  clear: function() {
    this.length = 0;
    return this;
  },

  first: function() {
    return this[0];
  },

  last: function() {
    return this[this.length - 1];
  },

  compact: function() {
    return this.select(function(value) {
      return value != undefined || value != null;
    });
  },

  flatten: function() {
    return this.inject([], function(array, value) {
      return array.concat(value.constructor == Array ?
        value.flatten() : [value]);
    });
  },

  without: function() {
    var values = $A(arguments);
    return this.select(function(value) {
      return !values.include(value);
    });
  },

  indexOf: function(object) {
    for (var i = 0; i < this.length; i++)
      if (this[i] == object) return i;
    return -1;
  },

  reverse: function(inline) {
    return (inline !== false ? this : this.toArray())._reverse();
  },

  shift: function() {
    var result = this[0];
    for (var i = 0; i < this.length - 1; i++)
      this[i] = this[i + 1];
    this.length--;
    return result;
  },

  inspect: function() {
    return '[' + this.map(Object.inspect).join(', ') + ']';
  }
});
var Hash = {
  _each: function(iterator) {
    for (key in this) {
      var value = this[key];
      if (typeof value == 'function') continue;

      var pair = [key, value];
      pair.key = key;
      pair.value = value;
      iterator(pair);
    }
  },

  keys: function() {
    return this.pluck('key');
  },

  values: function() {
    return this.pluck('value');
  },

  merge: function(hash) {
    return $H(hash).inject($H(this), function(mergedHash, pair) {
      mergedHash[pair.key] = pair.value;
      return mergedHash;
    });
  },

  toQueryString: function() {
    return this.map(function(pair) {
      return pair.map(encodeURIComponent).join('=');
    }).join('&');
  },

  inspect: function() {
    return '#<Hash:{' + this.map(function(pair) {
      return pair.map(Object.inspect).join(': ');
    }).join(', ') + '}>';
  }
}

function $H(object) {
  var hash = Object.extend({}, object || {});
  Object.extend(hash, Enumerable);
  Object.extend(hash, Hash);
  return hash;
}
ObjectRange = Class.create();
Object.extend(ObjectRange.prototype, Enumerable);
Object.extend(ObjectRange.prototype, {
  initialize: function(start, end, exclusive) {
    this.start = start;
    this.end = end;
    this.exclusive = exclusive;
  },

  _each: function(iterator) {
    var value = this.start;
    do {
      iterator(value);
      value = value.succ();
    } while (this.include(value));
  },

  include: function(value) {
    if (value < this.start)
      return false;
    if (this.exclusive)
      return value < this.end;
    return value <= this.end;
  }
});

var $R = function(start, end, exclusive) {
  return new ObjectRange(start, end, exclusive);
}

var Ajax = {
  getTransport: function() {
    return Try.these(
      function() {return new ActiveXObject('Msxml2.XMLHTTP')},
      function() {return new ActiveXObject('Microsoft.XMLHTTP')},
      function() {return new XMLHttpRequest()}
    ) || false;
  },

  activeRequestCount: 0
}

Ajax.Responders = {
  responders: [],

  _each: function(iterator) {
    this.responders._each(iterator);
  },

  register: function(responderToAdd) {
    if (!this.include(responderToAdd))
      this.responders.push(responderToAdd);
  },

  unregister: function(responderToRemove) {
    this.responders = this.responders.without(responderToRemove);
  },

  dispatch: function(callback, request, transport, json) {
    this.each(function(responder) {
      if (responder[callback] && typeof responder[callback] == 'function') {
        try {
          responder[callback].apply(responder, [request, transport, json]);
        } catch (e) {}
      }
    });
  }
};

Object.extend(Ajax.Responders, Enumerable);

Ajax.Responders.register({
  onCreate: function() {
    Ajax.activeRequestCount++;
  },

  onComplete: function() {
    Ajax.activeRequestCount--;
  }
});

Ajax.Base = function() {};
Ajax.Base.prototype = {
  setOptions: function(options) {
    this.options = {
      method:       'post',
      asynchronous: true,
      parameters:   ''
    }
    Object.extend(this.options, options || {});
  },

  responseIsSuccess: function() {
    return this.transport.status == undefined
        || this.transport.status == 0
        || (this.transport.status >= 200 && this.transport.status < 300);
  },

  responseIsFailure: function() {
    return !this.responseIsSuccess();
  }
}

Ajax.Request = Class.create();
Ajax.Request.Events =
  ['Uninitialized', 'Loading', 'Loaded', 'Interactive', 'Complete'];

Ajax.Request.prototype = Object.extend(new Ajax.Base(), {
  initialize: function(url, options) {
    this.transport = Ajax.getTransport();
    this.setOptions(options);
    this.request(url);
  },

  request: function(url) {
    var parameters = this.options.parameters || '';
    if (parameters.length > 0) parameters += '&_=';

    try {
      this.url = url;
      if (this.options.method == 'get' && parameters.length > 0)
        this.url += (this.url.match(/\?/) ? '&' : '?') + parameters;

      Ajax.Responders.dispatch('onCreate', this, this.transport);

      this.transport.open(this.options.method, this.url,
        this.options.asynchronous);

      if (this.options.asynchronous) {
        this.transport.onreadystatechange = this.onStateChange.bind(this);
        setTimeout((function() {this.respondToReadyState(1)}).bind(this), 10);
      }

      this.setRequestHeaders();

      var body = this.options.postBody ? this.options.postBody : parameters;
      this.transport.send(this.options.method == 'post' ? body : null);

    } catch (e) {
      this.dispatchException(e);
    }
  },

  setRequestHeaders: function() {
    var requestHeaders =
      ['X-Requested-With', 'XMLHttpRequest',
       'X-Prototype-Version', Prototype.Version];

    if (this.options.method == 'post') {
      requestHeaders.push('Content-type',
        'application/x-www-form-urlencoded');

      /* Force "Connection: close" for Mozilla browsers to work around
       * a bug where XMLHttpReqeuest sends an incorrect Content-length
       * header. See Mozilla Bugzilla #246651.
       */
      if (this.transport.overrideMimeType)
        requestHeaders.push('Connection', 'close');
    }

    if (this.options.requestHeaders)
      requestHeaders.push.apply(requestHeaders, this.options.requestHeaders);

    for (var i = 0; i < requestHeaders.length; i += 2)
      this.transport.setRequestHeader(requestHeaders[i], requestHeaders[i+1]);
  },

  onStateChange: function() {
    var readyState = this.transport.readyState;
    if (readyState != 1)
      this.respondToReadyState(this.transport.readyState);
  },

  header: function(name) {
    try {
      return this.transport.getResponseHeader(name);
    } catch (e) {}
  },

  evalJSON: function() {
    try {
      return eval(this.header('X-JSON'));
    } catch (e) {}
  },

  evalResponse: function() {
    try {
      return eval(this.transport.responseText);
    } catch (e) {
      this.dispatchException(e);
    }
  },

  respondToReadyState: function(readyState) {
    var event = Ajax.Request.Events[readyState];
    var transport = this.transport, json = this.evalJSON();

    if (event == 'Complete') {
      try {
        (this.options['on' + this.transport.status]
         || this.options['on' + (this.responseIsSuccess() ? 'Success' : 'Failure')]
         || Prototype.emptyFunction)(transport, json);
      } catch (e) {
        this.dispatchException(e);
      }

      if ((this.header('Content-type') || '').match(/^text\/javascript/i))
        this.evalResponse();
    }

    try {
      (this.options['on' + event] || Prototype.emptyFunction)(transport, json);
      Ajax.Responders.dispatch('on' + event, this, transport, json);
    } catch (e) {
      this.dispatchException(e);
    }

    /* Avoid memory leak in MSIE: clean up the oncomplete event handler */
    if (event == 'Complete')
      this.transport.onreadystatechange = Prototype.emptyFunction;
  },

  dispatchException: function(exception) {
    (this.options.onException || Prototype.emptyFunction)(this, exception);
    Ajax.Responders.dispatch('onException', this, exception);
  }
});

Ajax.Updater = Class.create();

Object.extend(Object.extend(Ajax.Updater.prototype, Ajax.Request.prototype), {
  initialize: function(container, url, options) {
    this.containers = {
      success: container.success ? $(container.success) : $(container),
      failure: container.failure ? $(container.failure) :
        (container.success ? null : $(container))
    }

    this.transport = Ajax.getTransport();
    this.setOptions(options);

    var onComplete = this.options.onComplete || Prototype.emptyFunction;
    this.options.onComplete = (function(transport, object) {
      this.updateContent();
      onComplete(transport, object);
    }).bind(this);

    this.request(url);
  },

  updateContent: function() {
    var receiver = this.responseIsSuccess() ?
      this.containers.success : this.containers.failure;
    var response = this.transport.responseText;

    if (!this.options.evalScripts)
      response = response.stripScripts();

    if (receiver) {
      if (this.options.insertion) {
        new this.options.insertion(receiver, response);
      } else {
        Element.update(receiver, response);
      }
    }

    if (this.responseIsSuccess()) {
      if (this.onComplete)
        setTimeout(this.onComplete.bind(this), 10);
    }
  }
});

Ajax.PeriodicalUpdater = Class.create();
Ajax.PeriodicalUpdater.prototype = Object.extend(new Ajax.Base(), {
  initialize: function(container, url, options) {
    this.setOptions(options);
    this.onComplete = this.options.onComplete;

    this.frequency = (this.options.frequency || 2);
    this.decay = (this.options.decay || 1);

    this.updater = {};
    this.container = container;
    this.url = url;

    this.start();
  },

  start: function() {
    this.options.onComplete = this.updateComplete.bind(this);
    this.onTimerEvent();
  },

  stop: function() {
    this.updater.onComplete = undefined;
    clearTimeout(this.timer);
    (this.onComplete || Prototype.emptyFunction).apply(this, arguments);
  },

  updateComplete: function(request) {
    if (this.options.decay) {
      this.decay = (request.responseText == this.lastText ?
        this.decay * this.options.decay : 1);

      this.lastText = request.responseText;
    }
    this.timer = setTimeout(this.onTimerEvent.bind(this),
      this.decay * this.frequency * 1000);
  },

  onTimerEvent: function() {
    this.updater = new Ajax.Updater(this.container, this.url, this.options);
  }
});
document.getElementsByClassName = function(className, parentElement) {
  var children = ($(parentElement) || document.body).getElementsByTagName('*');
  return $A(children).inject([], function(elements, child) {
    if (child.className.match(new RegExp("(^|\\s)" + className + "(\\s|$)")))
      elements.push(child);
    return elements;
  });
}

/*--------------------------------------------------------------------------*/

if (!window.Element) {
  var Element = new Object();
}

Object.extend(Element, {
  visible: function(element) {
    return $(element).style.display != 'none';
  },

  toggle: function() {
    for (var i = 0; i < arguments.length; i++) {
      var element = $(arguments[i]);
      Element[Element.visible(element) ? 'hide' : 'show'](element);
    }
  },

  hide: function() {
    for (var i = 0; i < arguments.length; i++) {
      var element = $(arguments[i]);
      element.style.display = 'none';
    }
  },

  show: function() {
    for (var i = 0; i < arguments.length; i++) {
      var element = $(arguments[i]);
      element.style.display = '';
    }
  },

  remove: function(element) {
    element = $(element);
    element.parentNode.removeChild(element);
  },

  update: function(element, html) {
    $(element).innerHTML = html.stripScripts();
    setTimeout(function() {html.evalScripts()}, 10);
  },

  getHeight: function(element) {
    element = $(element);
    return element.offsetHeight;
  },

  classNames: function(element) {
    return new Element.ClassNames(element);
  },

  hasClassName: function(element, className) {
    if (!(element = $(element))) return;
    return Element.classNames(element).include(className);
  },

  addClassName: function(element, className) {
    if (!(element = $(element))) return;
    return Element.classNames(element).add(className);
  },

  removeClassName: function(element, className) {
    if (!(element = $(element))) return;
    return Element.classNames(element).remove(className);
  },

  // removes whitespace-only text node children
  cleanWhitespace: function(element) {
    element = $(element);
    for (var i = 0; i < element.childNodes.length; i++) {
      var node = element.childNodes[i];
      if (node.nodeType == 3 && !/\S/.test(node.nodeValue))
        Element.remove(node);
    }
  },

  empty: function(element) {
    return $(element).innerHTML.match(/^\s*$/);
  },

  scrollTo: function(element) {
    element = $(element);
    var x = element.x ? element.x : element.offsetLeft,
        y = element.y ? element.y : element.offsetTop;
    window.scrollTo(x, y);
  },

  getStyle: function(element, style) {
    element = $(element);
    var value = element.style[style.camelize()];
    if (!value) {
      if (document.defaultView && document.defaultView.getComputedStyle) {
        var css = document.defaultView.getComputedStyle(element, null);
        value = css ? css.getPropertyValue(style) : null;
      } else if (element.currentStyle) {
        value = element.currentStyle[style.camelize()];
      }
    }

    if (window.opera && ['left', 'top', 'right', 'bottom'].include(style))
      if (Element.getStyle(element, 'position') == 'static') value = 'auto';

    return value == 'auto' ? null : value;
  },

  setStyle: function(element, style) {
    element = $(element);
    for (name in style)
      element.style[name.camelize()] = style[name];
  },

  getDimensions: function(element) {
    element = $(element);
    if (Element.getStyle(element, 'display') != 'none')
      return {width: element.offsetWidth, height: element.offsetHeight};

    // All *Width and *Height properties give 0 on elements with display none,
    // so enable the element temporarily
    var els = element.style;
    var originalVisibility = els.visibility;
    var originalPosition = els.position;
    els.visibility = 'hidden';
    els.position = 'absolute';
    els.display = '';
    var originalWidth = element.clientWidth;
    var originalHeight = element.clientHeight;
    els.display = 'none';
    els.position = originalPosition;
    els.visibility = originalVisibility;
    return {width: originalWidth, height: originalHeight};
  },

  makePositioned: function(element) {
    element = $(element);
    var pos = Element.getStyle(element, 'position');
    if (pos == 'static' || !pos) {
      element._madePositioned = true;
      element.style.position = 'relative';
      // Opera returns the offset relative to the positioning context, when an
      // element is position relative but top and left have not been defined
      if (window.opera) {
        element.style.top = 0;
        element.style.left = 0;
      }
    }
  },

  undoPositioned: function(element) {
    element = $(element);
    if (element._madePositioned) {
      element._madePositioned = undefined;
      element.style.position =
        element.style.top =
        element.style.left =
        element.style.bottom =
        element.style.right = '';
    }
  },

  makeClipping: function(element) {
    element = $(element);
    if (element._overflow) return;
    element._overflow = element.style.overflow;
    if ((Element.getStyle(element, 'overflow') || 'visible') != 'hidden')
      element.style.overflow = 'hidden';
  },

  undoClipping: function(element) {
    element = $(element);
    if (element._overflow) return;
    element.style.overflow = element._overflow;
    element._overflow = undefined;
  }
});

var Toggle = new Object();
Toggle.display = Element.toggle;

/*--------------------------------------------------------------------------*/

Abstract.Insertion = function(adjacency) {
  this.adjacency = adjacency;
}

Abstract.Insertion.prototype = {
  initialize: function(element, content) {
    this.element = $(element);
    this.content = content.stripScripts();

    if (this.adjacency && this.element.insertAdjacentHTML) {
      try {
        this.element.insertAdjacentHTML(this.adjacency, this.content);
      } catch (e) {
        if (this.element.tagName.toLowerCase() == 'tbody') {
          this.insertContent(this.contentFromAnonymousTable());
        } else {
          throw e;
        }
      }
    } else {
      this.range = this.element.ownerDocument.createRange();
      if (this.initializeRange) this.initializeRange();
      this.insertContent([this.range.createContextualFragment(this.content)]);
    }

    setTimeout(function() {content.evalScripts()}, 10);
  },

  contentFromAnonymousTable: function() {
    var div = document.createElement('div');
    div.innerHTML = '<table><tbody>' + this.content + '</tbody></table>';
    return $A(div.childNodes[0].childNodes[0].childNodes);
  }
}

var Insertion = new Object();

Insertion.Before = Class.create();
Insertion.Before.prototype = Object.extend(new Abstract.Insertion('beforeBegin'), {
  initializeRange: function() {
    this.range.setStartBefore(this.element);
  },

  insertContent: function(fragments) {
    fragments.each((function(fragment) {
      this.element.parentNode.insertBefore(fragment, this.element);
    }).bind(this));
  }
});

Insertion.Top = Class.create();
Insertion.Top.prototype = Object.extend(new Abstract.Insertion('afterBegin'), {
  initializeRange: function() {
    this.range.selectNodeContents(this.element);
    this.range.collapse(true);
  },

  insertContent: function(fragments) {
    fragments.reverse(false).each((function(fragment) {
      this.element.insertBefore(fragment, this.element.firstChild);
    }).bind(this));
  }
});

Insertion.Bottom = Class.create();
Insertion.Bottom.prototype = Object.extend(new Abstract.Insertion('beforeEnd'), {
  initializeRange: function() {
    this.range.selectNodeContents(this.element);
    this.range.collapse(this.element);
  },

  insertContent: function(fragments) {
    fragments.each((function(fragment) {
      this.element.appendChild(fragment);
    }).bind(this));
  }
});

Insertion.After = Class.create();
Insertion.After.prototype = Object.extend(new Abstract.Insertion('afterEnd'), {
  initializeRange: function() {
    this.range.setStartAfter(this.element);
  },

  insertContent: function(fragments) {
    fragments.each((function(fragment) {
      this.element.parentNode.insertBefore(fragment,
        this.element.nextSibling);
    }).bind(this));
  }
});

/*--------------------------------------------------------------------------*/

Element.ClassNames = Class.create();
Element.ClassNames.prototype = {
  initialize: function(element) {
    this.element = $(element);
  },

  _each: function(iterator) {
    this.element.className.split(/\s+/).select(function(name) {
      return name.length > 0;
    })._each(iterator);
  },

  set: function(className) {
    this.element.className = className;
  },

  add: function(classNameToAdd) {
    if (this.include(classNameToAdd)) return;
    this.set(this.toArray().concat(classNameToAdd).join(' '));
  },

  remove: function(classNameToRemove) {
    if (!this.include(classNameToRemove)) return;
    this.set(this.select(function(className) {
      return className != classNameToRemove;
    }).join(' '));
  },

  toString: function() {
    return this.toArray().join(' ');
  }
}

Object.extend(Element.ClassNames.prototype, Enumerable);
var Field = {
  clear: function() {
    for (var i = 0; i < arguments.length; i++)
      $(arguments[i]).value = '';
  },

  focus: function(element) {
    $(element).focus();
  },

  present: function() {
    for (var i = 0; i < arguments.length; i++)
      if ($(arguments[i]).value == '') return false;
    return true;
  },

  select: function(element) {
    $(element).select();
  },

  activate: function(element) {
    element = $(element);
    element.focus();
    if (element.select)
      element.select();
  }
}

/*--------------------------------------------------------------------------*/

var Form = {
  serialize: function(form) {
    var elements = Form.getElements($(form));
    var queryComponents = new Array();

    for (var i = 0; i < elements.length; i++) {
      var queryComponent = Form.Element.serialize(elements[i]);
      if (queryComponent)
        queryComponents.push(queryComponent);
    }

    return queryComponents.join('&');
  },

  getElements: function(form) {
    form = $(form);
    var elements = new Array();

    for (tagName in Form.Element.Serializers) {
      var tagElements = form.getElementsByTagName(tagName);
      for (var j = 0; j < tagElements.length; j++)
        elements.push(tagElements[j]);
    }
    return elements;
  },

  getInputs: function(form, typeName, name) {
    form = $(form);
    var inputs = form.getElementsByTagName('input');

    if (!typeName && !name)
      return inputs;

    var matchingInputs = new Array();
    for (var i = 0; i < inputs.length; i++) {
      var input = inputs[i];
      if ((typeName && input.type != typeName) ||
          (name && input.name != name))
        continue;
      matchingInputs.push(input);
    }

    return matchingInputs;
  },

  disable: function(form) {
    var elements = Form.getElements(form);
    for (var i = 0; i < elements.length; i++) {
      var element = elements[i];
      element.blur();
      element.disabled = 'true';
    }
  },

  enable: function(form) {
    var elements = Form.getElements(form);
    for (var i = 0; i < elements.length; i++) {
      var element = elements[i];
      element.disabled = '';
    }
  },

  findFirstElement: function(form) {
    return Form.getElements(form).find(function(element) {
      return element.type != 'hidden' && !element.disabled &&
        ['input', 'select', 'textarea'].include(element.tagName.toLowerCase());
    });
  },

  focusFirstElement: function(form) {
    Field.activate(Form.findFirstElement(form));
  },

  reset: function(form) {
    $(form).reset();
  }
}

Form.Element = {
  serialize: function(element) {
    element = $(element);
    var method = element.tagName.toLowerCase();
    var parameter = Form.Element.Serializers[method](element);

    if (parameter) {
      var key = encodeURIComponent(parameter[0]);
      if (key.length == 0) return;

      if (parameter[1].constructor != Array)
        parameter[1] = [parameter[1]];

      return parameter[1].map(function(value) {
        return key + '=' + encodeURIComponent(value);
      }).join('&');
    }
  },

  getValue: function(element) {
    element = $(element);
    var method = element.tagName.toLowerCase();
    var parameter = Form.Element.Serializers[method](element);

    if (parameter)
      return parameter[1];
  }
}

Form.Element.Serializers = {
  input: function(element) {
    switch (element.type.toLowerCase()) {
      case 'submit':
      case 'hidden':
      case 'password':
      case 'text':
        return Form.Element.Serializers.textarea(element);
      case 'checkbox':
      case 'radio':
        return Form.Element.Serializers.inputSelector(element);
    }
    return false;
  },

  inputSelector: function(element) {
    if (element.checked)
      return [element.name, element.value];
  },

  textarea: function(element) {
    return [element.name, element.value];
  },

  select: function(element) {
    return Form.Element.Serializers[element.type == 'select-one' ?
      'selectOne' : 'selectMany'](element);
  },

  selectOne: function(element) {
    var value = '', opt, index = element.selectedIndex;
    if (index >= 0) {
      opt = element.options[index];
      value = opt.value;
      if (!value && !('value' in opt))
        value = opt.text;
    }
    return [element.name, value];
  },

  selectMany: function(element) {
    var value = new Array();
    for (var i = 0; i < element.length; i++) {
      var opt = element.options[i];
      if (opt.selected) {
        var optValue = opt.value;
        if (!optValue && !('value' in opt))
          optValue = opt.text;
        value.push(optValue);
      }
    }
    return [element.name, value];
  }
}

/*--------------------------------------------------------------------------*/

var $F = Form.Element.getValue;

/*--------------------------------------------------------------------------*/

Abstract.TimedObserver = function() {}
Abstract.TimedObserver.prototype = {
  initialize: function(element, frequency, callback) {
    this.frequency = frequency;
    this.element   = $(element);
    this.callback  = callback;

    this.lastValue = this.getValue();
    this.registerCallback();
  },

  registerCallback: function() {
    setInterval(this.onTimerEvent.bind(this), this.frequency * 1000);
  },

  onTimerEvent: function() {
    var value = this.getValue();
    if (this.lastValue != value) {
      this.callback(this.element, value);
      this.lastValue = value;
    }
  }
}

Form.Element.Observer = Class.create();
Form.Element.Observer.prototype = Object.extend(new Abstract.TimedObserver(), {
  getValue: function() {
    return Form.Element.getValue(this.element);
  }
});

Form.Observer = Class.create();
Form.Observer.prototype = Object.extend(new Abstract.TimedObserver(), {
  getValue: function() {
    return Form.serialize(this.element);
  }
});

/*--------------------------------------------------------------------------*/

Abstract.EventObserver = function() {}
Abstract.EventObserver.prototype = {
  initialize: function(element, callback) {
    this.element  = $(element);
    this.callback = callback;

    this.lastValue = this.getValue();
    if (this.element.tagName.toLowerCase() == 'form')
      this.registerFormCallbacks();
    else
      this.registerCallback(this.element);
  },

  onElementEvent: function() {
    var value = this.getValue();
    if (this.lastValue != value) {
      this.callback(this.element, value);
      this.lastValue = value;
    }
  },

  registerFormCallbacks: function() {
    var elements = Form.getElements(this.element);
    for (var i = 0; i < elements.length; i++)
      this.registerCallback(elements[i]);
  },

  registerCallback: function(element) {
    if (element.type) {
      switch (element.type.toLowerCase()) {
        case 'checkbox':
        case 'radio':
          Event.observe(element, 'click', this.onElementEvent.bind(this));
          break;
        case 'password':
        case 'text':
        case 'textarea':
        case 'select-one':
        case 'select-multiple':
          Event.observe(element, 'change', this.onElementEvent.bind(this));
          break;
      }
    }
  }
}

Form.Element.EventObserver = Class.create();
Form.Element.EventObserver.prototype = Object.extend(new Abstract.EventObserver(), {
  getValue: function() {
    return Form.Element.getValue(this.element);
  }
});

Form.EventObserver = Class.create();
Form.EventObserver.prototype = Object.extend(new Abstract.EventObserver(), {
  getValue: function() {
    return Form.serialize(this.element);
  }
});
if (!window.Event) {
  var Event = new Object();
}

Object.extend(Event, {
  KEY_BACKSPACE: 8,
  KEY_TAB:       9,
  KEY_RETURN:   13,
  KEY_ESC:      27,
  KEY_LEFT:     37,
  KEY_UP:       38,
  KEY_RIGHT:    39,
  KEY_DOWN:     40,
  KEY_DELETE:   46,

  element: function(event) {
    return event.target || event.srcElement;
  },

  isLeftClick: function(event) {
    return (((event.which) && (event.which == 1)) ||
            ((event.button) && (event.button == 1)));
  },

  pointerX: function(event) {
    return event.pageX || (event.clientX +
      (document.documentElement.scrollLeft || document.body.scrollLeft));
  },

  pointerY: function(event) {
    return event.pageY || (event.clientY +
      (document.documentElement.scrollTop || document.body.scrollTop));
  },

  stop: function(event) {
    if (event.preventDefault) {
      event.preventDefault();
      event.stopPropagation();
    } else {
      event.returnValue = false;
      event.cancelBubble = true;
    }
  },

  // find the first node with the given tagName, starting from the
  // node the event was triggered on; traverses the DOM upwards
  findElement: function(event, tagName) {
    var element = Event.element(event);
    while (element.parentNode && (!element.tagName ||
        (element.tagName.toUpperCase() != tagName.toUpperCase())))
      element = element.parentNode;
    return element;
  },

  observers: false,

  _observeAndCache: function(element, name, observer, useCapture) {
    if (!this.observers) this.observers = [];
    if (element.addEventListener) {
      this.observers.push([element, name, observer, useCapture]);
      element.addEventListener(name, observer, useCapture);
    } else if (element.attachEvent) {
      this.observers.push([element, name, observer, useCapture]);
      element.attachEvent('on' + name, observer);
    }
  },

  unloadCache: function() {
    if (!Event.observers) return;
    for (var i = 0; i < Event.observers.length; i++) {
      Event.stopObserving.apply(this, Event.observers[i]);
      Event.observers[i][0] = null;
    }
    Event.observers = false;
  },

  observe: function(element, name, observer, useCapture) {
    var element = $(element);
    useCapture = useCapture || false;

    if (name == 'keypress' &&
        (navigator.appVersion.match(/Konqueror|Safari|KHTML/)
        || element.attachEvent))
      name = 'keydown';

    this._observeAndCache(element, name, observer, useCapture);
  },

  stopObserving: function(element, name, observer, useCapture) {
    var element = $(element);
    useCapture = useCapture || false;

    if (name == 'keypress' &&
        (navigator.appVersion.match(/Konqueror|Safari|KHTML/)
        || element.detachEvent))
      name = 'keydown';

    if (element.removeEventListener) {
      element.removeEventListener(name, observer, useCapture);
    } else if (element.detachEvent) {
      element.detachEvent('on' + name, observer);
    }
  }
});

/* prevent memory leaks in IE */
Event.observe(window, 'unload', Event.unloadCache, false);
var Position = {
  // set to true if needed, warning: firefox performance problems
  // NOT neeeded for page scrolling, only if draggable contained in
  // scrollable elements
  includeScrollOffsets: false,

  // must be called before calling withinIncludingScrolloffset, every time the
  // page is scrolled
  prepare: function() {
    this.deltaX =  window.pageXOffset
                || document.documentElement.scrollLeft
                || document.body.scrollLeft
                || 0;
    this.deltaY =  window.pageYOffset
                || document.documentElement.scrollTop
                || document.body.scrollTop
                || 0;
  },

  realOffset: function(element) {
    var valueT = 0, valueL = 0;
    do {
      valueT += element.scrollTop  || 0;
      valueL += element.scrollLeft || 0;
      element = element.parentNode;
    } while (element);
    return [valueL, valueT];
  },

  cumulativeOffset: function(element) {
    var valueT = 0, valueL = 0;
    do {
      valueT += element.offsetTop  || 0;
      valueL += element.offsetLeft || 0;
      element = element.offsetParent;
    } while (element);
    return [valueL, valueT];
  },

  positionedOffset: function(element) {
    var valueT = 0, valueL = 0;
    do {
      valueT += element.offsetTop  || 0;
      valueL += element.offsetLeft || 0;
      element = element.offsetParent;
      if (element) {
        p = Element.getStyle(element, 'position');
        if (p == 'relative' || p == 'absolute') break;
      }
    } while (element);
    return [valueL, valueT];
  },

  offsetParent: function(element) {
    if (element.offsetParent) return element.offsetParent;
    if (element == document.body) return element;

    while ((element = element.parentNode) && element != document.body)
      if (Element.getStyle(element, 'position') != 'static')
        return element;

    return document.body;
  },

  // caches x/y coordinate pair to use with overlap
  within: function(element, x, y) {
    if (this.includeScrollOffsets)
      return this.withinIncludingScrolloffsets(element, x, y);
    this.xcomp = x;
    this.ycomp = y;
    this.offset = this.cumulativeOffset(element);

    return (y >= this.offset[1] &&
            y <  this.offset[1] + element.offsetHeight &&
            x >= this.offset[0] &&
            x <  this.offset[0] + element.offsetWidth);
  },

  withinIncludingScrolloffsets: function(element, x, y) {
    var offsetcache = this.realOffset(element);

    this.xcomp = x + offsetcache[0] - this.deltaX;
    this.ycomp = y + offsetcache[1] - this.deltaY;
    this.offset = this.cumulativeOffset(element);

    return (this.ycomp >= this.offset[1] &&
            this.ycomp <  this.offset[1] + element.offsetHeight &&
            this.xcomp >= this.offset[0] &&
            this.xcomp <  this.offset[0] + element.offsetWidth);
  },

  // within must be called directly before
  overlap: function(mode, element) {
    if (!mode) return 0;
    if (mode == 'vertical')
      return ((this.offset[1] + element.offsetHeight) - this.ycomp) /
        element.offsetHeight;
    if (mode == 'horizontal')
      return ((this.offset[0] + element.offsetWidth) - this.xcomp) /
        element.offsetWidth;
  },

  clone: function(source, target) {
    source = $(source);
    target = $(target);
    target.style.position = 'absolute';
    var offsets = this.cumulativeOffset(source);
    target.style.top    = offsets[1] + 'px';
    target.style.left   = offsets[0] + 'px';
    target.style.width  = source.offsetWidth + 'px';
    target.style.height = source.offsetHeight + 'px';
  },

  page: function(forElement) {
    var valueT = 0, valueL = 0;

    var element = forElement;
    do {
      valueT += element.offsetTop  || 0;
      valueL += element.offsetLeft || 0;

      // Safari fix
      if (element.offsetParent==document.body)
        if (Element.getStyle(element,'position')=='absolute') break;

    } while (element = element.offsetParent);

    element = forElement;
    do {
      valueT -= element.scrollTop  || 0;
      valueL -= element.scrollLeft || 0;
    } while (element = element.parentNode);

    return [valueL, valueT];
  },

  clone: function(source, target) {
    var options = Object.extend({
      setLeft:    true,
      setTop:     true,
      setWidth:   true,
      setHeight:  true,
      offsetTop:  0,
      offsetLeft: 0
    }, arguments[2] || {})

    // find page position of source
    source = $(source);
    var p = Position.page(source);

    // find coordinate system to use
    target = $(target);
    var delta = [0, 0];
    var parent = null;
    // delta [0,0] will do fine with position: fixed elements,
    // position:absolute needs offsetParent deltas
    if (Element.getStyle(target,'position') == 'absolute') {
      parent = Position.offsetParent(target);
      delta = Position.page(parent);
    }

    // correct by body offsets (fixes Safari)
    if (parent == document.body) {
      delta[0] -= document.body.offsetLeft;
      delta[1] -= document.body.offsetTop;
    }

    // set position
    if(options.setLeft)   target.style.left  = (p[0] - delta[0] + options.offsetLeft) + 'px';
    if(options.setTop)    target.style.top   = (p[1] - delta[1] + options.offsetTop) + 'px';
    if(options.setWidth)  target.style.width = source.offsetWidth + 'px';
    if(options.setHeight) target.style.height = source.offsetHeight + 'px';
  },

  absolutize: function(element) {
    element = $(element);
    if (element.style.position == 'absolute') return;
    Position.prepare();

    var offsets = Position.positionedOffset(element);
    var top     = offsets[1];
    var left    = offsets[0];
    var width   = element.clientWidth;
    var height  = element.clientHeight;

    element._originalLeft   = left - parseFloat(element.style.left  || 0);
    element._originalTop    = top  - parseFloat(element.style.top || 0);
    element._originalWidth  = element.style.width;
    element._originalHeight = element.style.height;

    element.style.position = 'absolute';
    element.style.top    = top + 'px';;
    element.style.left   = left + 'px';;
    element.style.width  = width + 'px';;
    element.style.height = height + 'px';;
  },

  relativize: function(element) {
    element = $(element);
    if (element.style.position == 'relative') return;
    Position.prepare();

    element.style.position = 'relative';
    var top  = parseFloat(element.style.top  || 0) - (element._originalTop || 0);
    var left = parseFloat(element.style.left || 0) - (element._originalLeft || 0);

    element.style.top    = top + 'px';
    element.style.left   = left + 'px';
    element.style.height = element._originalHeight;
    element.style.width  = element._originalWidth;
  }
}

// Safari returns margins on body which is incorrect if the child is absolutely
// positioned.  For performance reasons, redefine Position.cumulativeOffset for
// KHTML/WebKit only.
if (/Konqueror|Safari|KHTML/.test(navigator.userAgent)) {
  Position.cumulativeOffset = function(element) {
    var valueT = 0, valueL = 0;
    do {
      valueT += element.offsetTop  || 0;
      valueL += element.offsetLeft || 0;
      if (element.offsetParent == document.body)
        if (Element.getStyle(element, 'position') == 'absolute') break;

      element = element.offsetParent;
    } while (element);

    return [valueL, valueT];
  }
}
// ##########################
// File: /storage/www/yur/www/lib/quicktime_player.js
// ##########################
/*

File: AC_QuickTime.js

Abstract: This file contains functions to generate OBJECT and EMBED tags for QuickTime content.

Version: <1.1>

Disclaimer: IMPORTANT:  This Apple software is supplied to you by Apple
Computer, Inc. ("Apple") in consideration of your agreement to the
following terms, and your use, installation, modification or
redistribution of this Apple software constitutes acceptance of these
terms.  If you do not agree with these terms, please do not use,
install, modify or redistribute this Apple software.

In consideration of your agreement to abide by the following terms, and
subject to these terms, Apple grants you a personal, non-exclusive
license, under Apple's copyrights in this original Apple software (the
"Apple Software"), to use, reproduce, modify and redistribute the Apple
Software, with or without modifications, in source and/or binary forms;
provided that if you redistribute the Apple Software in its entirety and
without modifications, you must retain this notice and the following
text and disclaimers in all such redistributions of the Apple Software. 
Neither the name, trademarks, service marks or logos of Apple Computer,
Inc. may be used to endorse or promote products derived from the Apple
Software without specific prior written permission from Apple.  Except
as expressly stated in this notice, no other rights or licenses, express
or implied, are granted by Apple herein, including but not limited to
any patent rights that may be infringed by your derivative works or by
other works in which the Apple Software may be incorporated.

The Apple Software is provided by Apple on an "AS IS" basis.  APPLE
MAKES NO WARRANTIES, EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION
THE IMPLIED WARRANTIES OF NON-INFRINGEMENT, MERCHANTABILITY AND FITNESS
FOR A PARTICULAR PURPOSE, REGARDING THE APPLE SOFTWARE OR ITS USE AND
OPERATION ALONE OR IN COMBINATION WITH YOUR PRODUCTS.

IN NO EVENT SHALL APPLE BE LIABLE FOR ANY SPECIAL, INDIRECT, INCIDENTAL
OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
INTERRUPTION) ARISING IN ANY WAY OUT OF THE USE, REPRODUCTION,
MODIFICATION AND/OR DISTRIBUTION OF THE APPLE SOFTWARE, HOWEVER CAUSED
AND WHETHER UNDER THEORY OF CONTRACT, TORT (INCLUDING NEGLIGENCE),
STRICT LIABILITY OR OTHERWISE, EVEN IF APPLE HAS BEEN ADVISED OF THE
POSSIBILITY OF SUCH DAMAGE.

Copyright © 2006 Apple Computer, Inc., All Rights Reserved

*/ 

/*
 * This file contains functions to generate OBJECT and EMBED tags for QuickTime content. 
 */

/************** LOCALIZABLE GLOBAL VARIABLES ****************/

var gArgCountErr =	'The "%%" function requires an even number of arguments.'
				+	'\nArguments should be in the form "atttributeName", "attributeValue", ...';

/******************** END LOCALIZABLE **********************/

var gTagAttrs				= null;
var gQTGeneratorVersion		= 1.0;

function AC_QuickTimeVersion()	{ return gQTGeneratorVersion; }

function _QTComplain(callingFcnName, errMsg)
{
    errMsg = errMsg.replace("%%", callingFcnName);
	alert(errMsg);
}

function _QTAddAttribute(prefix, slotName, tagName)
{
	var		value;
	
	if(slotName == "id") {
		return ""
	}

	value = gTagAttrs[prefix + slotName];
	if ( null == value )
		value = gTagAttrs[slotName];

	if ( null != value )
	{
		if ( 0 == slotName.indexOf(prefix) && (null == tagName) )
			tagName = slotName.substring(prefix.length); 
		if ( null == tagName ) 
			tagName = slotName;
		return tagName + '="' + value + '" ';
	}
	else
		return "";
}

function _QTAddObjectAttr(slotName, tagName)
{
	// don't bother if it is only for the embed tag
	if ( 0 == slotName.indexOf("emb#") )
		return "";

	if ( 0 == slotName.indexOf("obj#") && (null == tagName) )
		tagName = slotName.substring(4); 

	return _QTAddAttribute("obj#", slotName, tagName);
}

function _QTAddEmbedAttr(slotName, tagName)
{
	// don't bother if it is only for the object tag
	if ( 0 == slotName.indexOf("obj#") )
		return "";

	if ( 0 == slotName.indexOf("emb#") && (null == tagName) )
		tagName = slotName.substring(4); 

	return _QTAddAttribute("emb#", slotName, tagName);
}


function _QTAddObjectParam(slotName, generateXHTML)
{
	var		paramValue;
	var		paramStr = "";
	var		endTagChar = (generateXHTML) ? ' />' : '>';

	if ( -1 == slotName.indexOf("emb#") )
	{
		// look for the OBJECT-only param first. if there is none, look for a generic one
		paramValue = gTagAttrs["obj#" + slotName];
		if ( null == paramValue )
			paramValue = gTagAttrs[slotName];

		if ( 0 == slotName.indexOf("obj#") )
			slotName = slotName.substring(4); 
	
		if ( null != paramValue )
			paramStr = '  <param name="' + slotName + '" value="' + paramValue + '"' + endTagChar + '\n';
	}

	return paramStr;
}

function _QTDeleteTagAttrs()
{
	for ( var ndx = 0; ndx < arguments.length; ndx++ )
	{
		var attrName = arguments[ndx];
		delete gTagAttrs[attrName];
		delete gTagAttrs["emb#" + attrName];
		delete gTagAttrs["obj#" + attrName];
	}
}

		

// generate an embed and object tag, return as a string
function _QTGenerate(callingFcnName, generateXHTML, args)
{
	// is the number of optional arguments even?
	if ( args.length < 4 || (0 != (args.length % 2)) )
	{
		_QTComplain(callingFcnName, gArgCountErr);
		return "";
	}
	
	// allocate an array, fill in the required attributes with fixed place params and defaults
	gTagAttrs = new Array();
	gTagAttrs["src"] = args[0];
	gTagAttrs["width"] = args[1];
	gTagAttrs["height"] = args[2];
	gTagAttrs["classid"] = "clsid:02BF25D5-8C17-4B23-BC80-D3488ABDDC6B";
		//Impportant note: It is recommended that you use this exact classid in order to ensure a seamless experience for all viewers
	gTagAttrs["pluginspage"] = "http://www.apple.com/quicktime/download/";

	// set up codebase attribute with specified or default version before parsing args so
	//  anything passed in will override
	var activexVers = args[3]
	if ( (null == activexVers) || ("" == activexVers) )
		activexVers = "6,0,2,0";
	gTagAttrs["codebase"] = "http://www.apple.com/qtactivex/qtplugin.cab#version=" + activexVers;

	var	attrName,
		attrValue;

	// add all of the optional attributes to the array
	for ( var ndx = 4; ndx < args.length; ndx += 2)
	{
		attrName = args[ndx].toLowerCase();
		attrValue = args[ndx + 1];
		
		
 
		gTagAttrs[attrName] = attrValue;
	}

	// init both tags with the required and "special" attributes
	var objTag =  '<object '
					+ _QTAddObjectAttr("classid")
					+ _QTAddObjectAttr("width")
					+ _QTAddObjectAttr("height")
					+ _QTAddObjectAttr("codebase")
					+ "id='" + gTagAttrs["id"] + "Object' "
					+ _QTAddObjectAttr("tabindex")
					+ _QTAddObjectAttr("hspace")
					+ _QTAddObjectAttr("vspace")
					+ _QTAddObjectAttr("border")
					+ _QTAddObjectAttr("align")
					+ _QTAddObjectAttr("class")
					+ _QTAddObjectAttr("title")
					+ _QTAddObjectAttr("accesskey")
					+ _QTAddObjectAttr("noexternaldata")
					+ '>\n'
					+ _QTAddObjectParam("src", generateXHTML);
	var embedTag = '  <embed '
					+ _QTAddEmbedAttr("src")
					+ _QTAddEmbedAttr("width")
					+ _QTAddEmbedAttr("height")
					+ _QTAddEmbedAttr("pluginspage")
					+ "id='" + gTagAttrs["id"] + "Embed' "
					+ _QTAddEmbedAttr("align")
					+ _QTAddEmbedAttr("tabindex");

	// delete the attributes/params we have already added
	_QTDeleteTagAttrs("src","width","height","pluginspage","classid","codebase","name","tabindex",
					"hspace","vspace","border","align","noexternaldata","class","title","accesskey");

	// and finally, add all of the remaining attributes to the embed and object
	for ( var attrName in gTagAttrs )
	{
		attrValue = gTagAttrs[attrName];
		
		
		if(typeof(attrValue) == "function") {
			continue
		}
		
		if ( null != attrValue )
		{
			embedTag += _QTAddEmbedAttr(attrName);
			objTag += _QTAddObjectParam(attrName, generateXHTML);
		}
	} 

	// end both tags, we're done
	return objTag + embedTag + '> </em' + 'bed>\n</ob' + 'ject' + '>';
}

// return the object/embed as a string
function QT_GenerateOBJECTText()
{
	return _QTGenerate("QT_GenerateOBJECTText", false, arguments);
}

function QT_GenerateOBJECTText_XHTML()
{
	return _QTGenerate("QT_GenerateOBJECTText_XHTML", true, arguments);
}

function QT_WriteOBJECT()
{
	var string = _QTGenerate("QT_WriteOBJECT", false, arguments);
	document.writeln(string);
}

function QT_WriteOBJECT_XHTML()
{
	document.writeln(_QTGenerate("QT_WriteOBJECT_XHTML", true, arguments));
}



// ##########################
// File: /storage/www/yur/www/lib/swfobject.js
// ##########################
/**
 * SWFObject v1.5: Flash Player detection and embed - http://blog.deconcept.com/swfobject/
 *
 * SWFObject is (c) 2007 Geoff Stearns and is released under the MIT License:
 * http://www.opensource.org/licenses/mit-license.php
 *
 */
if(typeof deconcept=="undefined"){var deconcept=new Object();}if(typeof deconcept.util=="undefined"){deconcept.util=new Object();}if(typeof deconcept.SWFObjectUtil=="undefined"){deconcept.SWFObjectUtil=new Object();}deconcept.SWFObject=function(_1,id,w,h,_5,c,_7,_8,_9,_a){if(!document.getElementById){return;}this.DETECT_KEY=_a?_a:"detectflash";this.skipDetect=deconcept.util.getRequestParameter(this.DETECT_KEY);this.params=new Object();this.variables=new Object();this.attributes=new Array();if(_1){this.setAttribute("swf",_1);}if(id){this.setAttribute("id",id);}if(w){this.setAttribute("width",w);}if(h){this.setAttribute("height",h);}if(_5){this.setAttribute("version",new deconcept.PlayerVersion(_5.toString().split(".")));}this.installedVer=deconcept.SWFObjectUtil.getPlayerVersion();if(!window.opera&&document.all&&this.installedVer.major>7){deconcept.SWFObject.doPrepUnload=true;}if(c){this.addParam("bgcolor",c);}var q=_7?_7:"high";this.addParam("quality",q);this.setAttribute("useExpressInstall",false);this.setAttribute("doExpressInstall",false);var _c=(_8)?_8:window.location;this.setAttribute("xiRedirectUrl",_c);this.setAttribute("redirectUrl","");if(_9){this.setAttribute("redirectUrl",_9);}};deconcept.SWFObject.prototype={useExpressInstall:function(_d){this.xiSWFPath=!_d?"expressinstall.swf":_d;this.setAttribute("useExpressInstall",true);},setAttribute:function(_e,_f){this.attributes[_e]=_f;},getAttribute:function(_10){return this.attributes[_10];},addParam:function(_11,_12){this.params[_11]=_12;},getParams:function(){return this.params;},addVariable:function(_13,_14){this.variables[_13]=_14;},getVariable:function(_15){return this.variables[_15];},getVariables:function(){return this.variables;},getVariablePairs:function(){var _16=new Array();var key;var _18=this.getVariables();for(key in _18){if (key != 'yurAddEvent') {_16[_16.length]=key+"="+_18[key];}}return _16;},getSWFHTML:function(){var _19="";if(navigator.plugins&&navigator.mimeTypes&&navigator.mimeTypes.length){if(this.getAttribute("doExpressInstall")){this.addVariable("MMplayerType","PlugIn");this.setAttribute("swf",this.xiSWFPath);}_19="<embed type=\"application/x-shockwave-flash\" src=\""+this.getAttribute("swf")+"\" width=\""+this.getAttribute("width")+"\" height=\""+this.getAttribute("height")+"\" style=\""+this.getAttribute("style")+"\"";_19+=" id=\""+this.getAttribute("id")+"\" name=\""+this.getAttribute("id")+"\" ";var _1a=this.getParams();for(var key in _1a){if (key != 'yurAddEvent' &&  key != 'yuraddevent' &&  key != 'yurmakeaccessors' &&  key != 'toJSONString' && key != 'yurMakeAccessors' && key != 'yurAddEvent' && key != 'flashvars') {_19+=[key]+"=\""+_1a[key]+"\" ";}}var _1c=this.getVariablePairs().join("&");if(_1c.length>0){_19+="flashvars=\""+_1c+"\"";}_19+="/>";}else{if(this.getAttribute("doExpressInstall")){this.addVariable("MMplayerType","ActiveX");this.setAttribute("swf",this.xiSWFPath);}_19="<object id=\""+this.getAttribute("id")+"\" classid=\"clsid:D27CDB6E-AE6D-11cf-96B8-444553540000\" width=\""+this.getAttribute("width")+"\" height=\""+this.getAttribute("height")+"\" style=\""+this.getAttribute("style")+"\">";_19+="<param name=\"movie\" value=\""+this.getAttribute("swf")+"\" />";var _1d=this.getParams();for(var key in _1d){_19+="<param name=\""+key+"\" value=\""+_1d[key]+"\" />";}var _1f=this.getVariablePairs().join("&");if(_1f.length>0){_19+="<param name=\"flashvars\" value=\""+_1f+"\" />";}_19+="</object>";}return _19;},write:function(_20){if(this.getAttribute("useExpressInstall")){var _21=new deconcept.PlayerVersion([6,0,65]);if(this.installedVer.versionIsValid(_21)&&!this.installedVer.versionIsValid(this.getAttribute("version"))){this.setAttribute("doExpressInstall",true);this.addVariable("MMredirectURL",escape(this.getAttribute("xiRedirectUrl")));document.title=document.title.slice(0,47)+" - Flash Player Installation";this.addVariable("MMdoctitle",document.title);}}if(this.skipDetect||this.getAttribute("doExpressInstall")||this.installedVer.versionIsValid(this.getAttribute("version"))){var n=(typeof _20=="string")?document.getElementById(_20):_20;n.innerHTML=this.getSWFHTML();return true;}else{if(this.getAttribute("redirectUrl")!=""){document.location.replace(this.getAttribute("redirectUrl"));}}return false;}};deconcept.SWFObjectUtil.getPlayerVersion=function(){var _23=new deconcept.PlayerVersion([0,0,0]);if(navigator.plugins&&navigator.mimeTypes.length){var x=navigator.plugins["Shockwave Flash"];if(x&&x.description){_23=new deconcept.PlayerVersion(x.description.replace(/([a-zA-Z]|\s)+/,"").replace(/(\s+r|\s+b[0-9]+)/,".").split("."));}}else{if(navigator.userAgent&&navigator.userAgent.indexOf("Windows CE")>=0){var axo=1;var _26=3;while(axo){try{_26++;axo=new ActiveXObject("ShockwaveFlash.ShockwaveFlash."+_26);_23=new deconcept.PlayerVersion([_26,0,0]);}catch(e){axo=null;}}}else{try{var axo=new ActiveXObject("ShockwaveFlash.ShockwaveFlash.7");}catch(e){try{var axo=new ActiveXObject("ShockwaveFlash.ShockwaveFlash.6");_23=new deconcept.PlayerVersion([6,0,21]);axo.AllowScriptAccess="always";}catch(e){if(_23.major==6){return _23;}}try{axo=new ActiveXObject("ShockwaveFlash.ShockwaveFlash");}catch(e){}}if(axo!=null){_23=new deconcept.PlayerVersion(axo.GetVariable("$version").split(" ")[1].split(","));}}}return _23;};deconcept.PlayerVersion=function(_29){this.major=_29[0]!=null?parseInt(_29[0]):0;this.minor=_29[1]!=null?parseInt(_29[1]):0;this.rev=_29[2]!=null?parseInt(_29[2]):0;};deconcept.PlayerVersion.prototype.versionIsValid=function(fv){if(this.major<fv.major){return false;}if(this.major>fv.major){return true;}if(this.minor<fv.minor){return false;}if(this.minor>fv.minor){return true;}if(this.rev<fv.rev){return false;}return true;};deconcept.util={getRequestParameter:function(_2b){var q=document.location.search||document.location.hash;if(_2b==null){return q;}if(q){var _2d=q.substring(1).split("&");for(var i=0;i<_2d.length;i++){if(_2d[i].substring(0,_2d[i].indexOf("="))==_2b){return _2d[i].substring((_2d[i].indexOf("=")+1));}}}return "";}};deconcept.SWFObjectUtil.cleanupSWFs=function(){var _2f=document.getElementsByTagName("OBJECT");for(var i=_2f.length-1;i>=0;i--){_2f[i].style.display="none";for(var x in _2f[i]){if(typeof _2f[i][x]=="function"){_2f[i][x]=function(){};}}}};if(deconcept.SWFObject.doPrepUnload){if(!deconcept.unloadSet){deconcept.SWFObjectUtil.prepUnload=function(){__flash_unloadHandler=function(){};__flash_savedUnloadHandler=function(){};window.attachEvent("onunload",deconcept.SWFObjectUtil.cleanupSWFs);};window.attachEvent("onbeforeunload",deconcept.SWFObjectUtil.prepUnload);deconcept.unloadSet=true;}}if(!document.getElementById&&document.all){document.getElementById=function(id){return document.all[id];};}var getQueryParamValue=deconcept.util.getRequestParameter;var FlashObject=deconcept.SWFObject;var SWFObject=deconcept.SWFObject;
// ##########################
// File: /storage/www/yur/www/lib/util.js
// ##########################
var content_breite = 0;
var content_hoehe = 0;
var hoehe_center = 0;
var my_over = 0;
var my_out = 0;
var timer = 0;
var last = 0;

if(window.urchinTracker == null) {
	window.urchinTracker = function () {}
}

function showUploadBox(queue) {
	window.open('/howto/'+queue,'uploadPopup'+Math.round(Math.random()*1000000000),'width=420,height=300');
}

function showPopupFernbedinung() {
	window.open('/static/popup_fernbedienung.html','uploadPopupFernbedinung','width=430,height=400');
}

function showPopupFreundesliste() {
	window.open('/static/popup_freundesliste.html','uploadPopupFreundesliste','width=430,height=200');
}

function showPopupKanalabo() {
	window.open('/static/popup_kanal_abo.html','uploadPopupKanalAbo','width=430,height=200');
}

function showPopupFreunde() {
	window.open('/static/popup_freunde_dieses_kanals.html','uploadPopupFreunde','width=430,height=200');
}

function showPopupSendungAufYurone() {
	window.open('/static/popup_sendung_auf_yurone.html','uploadPopupYurone','width=430,height=215');
}

function MM_findObj(n, d) { //v4.01
  var p,i,x;  if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) {
    d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}
  if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n];
  for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document);
  if(!x && d.getElementById) x=d.getElementById(n); return x;
}

function MM_validateForm() { //v4.0
  var i,p,q,nm,test,num,min,max,errors='',args=MM_validateForm.arguments;
  for (i=0; i<(args.length-2); i+=3) { test=args[i+2]; val=MM_findObj(args[i]);
    if (val) { if (args[i+1] != "") { nm=args[i+1]; } else { nm=val.name; } if ((val=val.value)!="") {
      if (test.indexOf('isEmail')!=-1) { p=val.indexOf('@');
        if (p<1 || p==(val.length-1)) errors+='- '+nm+' muss eine echte E-Mail-Adresse sein.\n';
      } else if (test!='R') { num = parseFloat(val);
        if (isNaN(val)) errors+='- '+nm+' muss eine Zahl sein.\n';
        if (test.indexOf('inRange') != -1) { p=test.indexOf(':');
          min=test.substring(8,p); max=test.substring(p+1);
          if (num<min || max<num) errors+='- '+nm+' muss eine Zahl zwischen '+min+' und '+max+' sein.\n';
    } } } else if (test.charAt(0) == 'R') errors += '- '+nm+' ist erforderlich.\n'; }
  }
  document.MM_returnValue = errors;
}

function keyPressed(e) {
	var key;
	if (window.event) key = window.event.keyCode
	else if (e) key = e.which
	return key;
}

function validateForm() {
	var args = validateForm.arguments;
	var form = args[0];
	var i;
	var error = ''
	for (i = 1; i < (args.length - 2); i += 3) {
		var feld = form[args[i]];
		var opt  = args[i+2];
		if (feld) {
			var e = '';
			var value = feld.value;
			if (value == null && feld.selectedIndex != null) {
				if (feld.selectedIndex >= 0) value = feld.options[feld.selectedIndex].value
			}
			if (value != null && value != "") {
				if (opt.indexOf('Email') != -1) {
					var position = value.indexOf('@');
       				if (position < 1 || position >= (value.length - 4)) e += ' muss eine E-Mail Addresse enthalten.';
				} else if (opt.indexOf('Zahl') != -1) {
					if (isNaN(value)) e += 'muss eine Zahl enthalten.'
				}
			} else if (opt.charAt(0) == 'R') e += ' muss angegeben werden.';
			if (e != '') {
				var name = args[i+1];
				if (name == "") {
					var o = $('fieldname' + args[i]);
					if (o) {
						name = o.innerHTML;
					} else {
						name = args[i];
					}
				}
				error += '- ' + name + ' ' + e + '\n';
			}
		}
	}

	return error;
}

function publishError(error) {
	alert('Folgende Fehler traten auf:\n' + error);
}

function showAttributes(obj) {
	var str = "";
	for (var x in obj) {
		str += "" + x + " = ";
		if (typeof(obj[x]) != "function") { str += "" + obj[x]; }
		else { str += "function"; }
		str += "\n";
	}
	return str;
}

function submitForm(f,action) {
	if (action != null) f.action = action;
	f.submit();
}

function submitForm0(action) {
	var f = document.forms[0];
	submitForm(f,action);
}


/* Funktionen/Variablen zur anzeige eines Fehlermeldung-Layers zu Formularfeldern */

function hide_err(id) {
	var div;
	if (div = document.getElementById(id)) div.style.display = "none";
}

function show_err(id) {
	var div;
	if (div = document.getElementById(id)) {
		if (mouseY != null) div.style.top = (mouseY + 10) + "px";
		div.style.display = "block";
	}
}

/* Verarbeitung/Validierung des Login-Formulars */

function login(form) {
	var btn = $('loginBtn');
	if (lockButton(btn, 'Pr&uuml;fe ...')) {
		var error = validateForm(form, "user_id", "Benutzername", "R", "login_passwd", "Passwort", "R");
		if (error != '') {
			alert("Es sind folgende Fehler aufgetreten:\n" + error);
			unlockButton(btn);
			__Yur.session.loginFocus();
		} else {
			__Yur.session.login_form(form, function () { unlockButton(btn); })
		}
	}
}

function loginPage(form) {
	var error = validateForm(form, "user_id", "Benutzername", "R", "login_passwd", "Passwort", "R");
	if (error != '') {
		alert("Es sind folgende Fehler aufgetreten:\n" + error);
		__Yur.session.loginFocus();
	} else {
		__Yur.session.login_form(form, function () {})
	}
}

function loginhomepage(form) {
	var error = validateForm(form, "user_id", "Benutzername", "R", "login_passwd", "Passwort", "R");
	if (error != '') {
		alert("Es sind folgende Fehler aufgetreten:\n" + error);
		__Yur.session.loginFocus();
	} else {
		__Yur.session.login_form(form, function () {})
	}
}

function keyPressedLogin(obj, event) {
	if (keyPressed(event) == 13) login(obj.form)
}


/* Verarbeitung/Validierung des Search-Formulars */

function search(form) {
	var error = validateForm(form, "alias", "Benutzername", "R");
	if (error != '') {
		alert("Es sind folgende Fehler aufgetreten:\n" + error);
		__Yur.ranking.searchFocus();
	} else {
		__Yur.ranking.search_form(form)
	}
	return false
}

function keyPressedSearch(obj, event) {
	if (keyPressed(event) == 13) search(obj.form)
}

/* Verarbeitung/Validierung des ResetPasswd-Formulars */

function reset_passwd(form) {
	//var btn = $('resetBtn');
	//if (lockButton(btn, 'Pr&uuml;fe ...')) {
		var error = validateForm(form, "email", "E-Mail", "REmail");
		if (error != '') {
			alert("Es sind folgende Fehler aufgetreten:\n" + error);
			//unlockButton(btn);
			__Yur.session.resetPasswdFocus();
		} else {
			__Yur.session.resetPasswd_form(form)
		}
	//}
}

function keyPressedResetPasswd(obj, event) {
	if (keyPressed(event) == 13) reset_passwd(obj.form)
}



/* Verarbeitung/Validierung der Register-Formulare */

function submitRegisterStep1(btn) {
	if (lockButton(btn, 'Pr&uuml;fe ...')) {
		var f = $('formularRegisterStep1')
		if (validateRegisterStep1(f)) submitForm(f,'/register/step3')
		else unlockButton(btn);
	}
}

function validateRegisterStep1(form) {
	var error = validateForm(form, "alias", "", "R", "anrede", "", "R", "name", "", "R", "strasse", "", "R", "plz", "", "R", "ort", "", "R", "land", "", "R", "geburtstag", "", "R", "email", "", "REmail", "handy", "", "Zahl");
	if (error != '') {
		publishError(error);
		return false;
	}
	return true;
}



function submitRegisterStep2(btn) {
	if (lockButton(btn, 'Pr&uuml;fe ...')) {
		var f = $('formularRegisterStep2')
		if (validateRegisterStep2(f)) submitForm(f,'/register/step3')
		else unlockButton(btn);
	}
}

function validateRegisterStep2(form) {
	if (form.agb.checked) return true
	alert("Stimmen Sie bitte den AGB's zu.");
	return false
}



function submitRegisterStep3(btn) {
	if (!($('agb').checked)) {
		alert('Bitte stimme den Nutzungsbedingungen zu.');
	} else {
		if ($('flirtmodusbox').checked) {$('flirtmodus').value = 1} else {$('flirtmodus').value = 0}
		if (lockButton(btn, 'Pr&uuml;fe ...')) {
			var f = $('formularRegisterStep3')
			if (validateRegisterStep3(f)) submitForm(f,'/register/final')
			else unlockButton(btn)
		}
	}
}

function submitRegisterFrame(btn) {
	if (!($('agb').checked)) {
		alert('Bitte stimme den Nutzungsbedingungen zu.');
	} else {
			$('losbtn').style.display='none';
			var f = window.frames['dataframe'].document.formularRegisterStep3;
			if (f.flirtmodusbox.checked) {f.flirtmodus.value = 1} else {f.flirtmodus.value = 0}
			
			if (validateRegisterStep3(f)) submitForm(f,'/register/final_frame')
			else parent.document.getElementById('losbtn').style.display='';
		
	}
}



function validateRegisterStep3(form) {
	var error = validateForm(form, "password", "", "R", "wiederholung", "", "R","alias", "", "R", "anrede", "Geschlecht", "R", "name", "", "R", "strasse", "", "R", "plz", "", "R", "ort", "", "R", "land", "", "R", "geburtstag", "", "R", "email", "", "REmail", "handy", "", "Zahl");
	if (error == '') {
		if (form.password.value != form.wiederholung.value) error += unescape('- Passwort und Wiederholung m%FCssen %FCbereinstimmen.')
	}
	if (error != '') {
		publishError(error);
		return false;
	}
	return true;
}



/* Verarbeitung/Validierung des Profile-Formulares */

function submitProfileUpdate(btn) {
	if (lockButton(btn, 'Speichere ...')) {
		var f = $('formularProfile');
		if (validateProfileUpdate(f)) {
			setHiddenFromCheckboxAll();
			submitForm(f,'/mytv/profile/update');
		}
		else unlockButton(btn)
	}
}

function validateProfileUpdate(form) {
	var error = validateForm(form, "anrede", "", "R", "name", "", "R", "geburtstag", "", "R", "email", "", "REmail", "handy", "", "Zahl");
	if (form.password.value != "" || form.wiederholung.value != "") {
		if (form.password.value != form.wiederholung.value) error += unescape('- Passwort und Wiederholung m%FCssen %FCbereinstimmen.')
		if (form.passwd.value == "") error += unescape('- Beim %C4ndern des Passwortes, muss das aktuelle Passwort angegeben werden.')
	}
	if (error != '') {
		publishError(error);
		return false;
	}
	return true;
}


/* Verarbeitung/Validierung der Movie Upload/Update Formulare */

function submitMovieUpdate(btn) {
	if (lockButton(btn, 'Speichere ...')) {
		var f = $('formularMovieUpdate')
		if (validateMovieUpdate(f)) submitForm(f)
		else unlockButton(btn)
	}
}

function validateMovieUpdate(form) {
	var error = validateForm(form, "thema", "", "R", "title", "", "R");
	if (error != '') {
		publishError(error);
		return false;
	}
	return true;
}

function submitMovieUpload(btn) {
//	if ($('agbbox').checked) {
//		hide('btnact');
//		show('btnin');
//		if ($('gemabox').checked) {
//			$('gema').value = 1;
//		} else {
//			$('gema').value = 0;
//		}
		var f = $('formularMovieUpload');
		var type = f.upload_type.options[f.upload_type.selectedIndex].value;
		if (validateMovieUpload(f)) {
			if (type == "url") {
				f.target = "";
				submitForm(f, '/start_movie_download');
			} else {
				initProgressBarHandler();
				var fetcher = new Yur.API('upload/prepare',
					function (data) {
						f.target = "uploadHolder";
						submitForm(f, '/upload.pl/' + data.tracking_id);
						$('uploadFormular').style.visibility = 'hidden';
						$('UploadStatus').style.display = 'block';
						trackUpload(data.tracking_id);
					},
					function (x) { unlockButton(btn); alert("upload failed ... " + x) }
				);
	//			fetcher.debug = true;
				fetcher.post({
					meta_queue:			f.meta_queue.value,
					actual_queue:		f.actual_queue.value,
					title:				f.title.value,
					description:		f.description.value,
					gema:				f.gema.value,
					upload_type:		type
				});
			}
//		} else {
//			show('btnact');
//			hide('btnin');
		}
//	} else {
//		alert('Bitte stimmen Sie den Nutzungsbedingungen zu.');
//	}
}

function submitMovieUploadFrame(btn) {
	if (window.frames['uploadframe'].$('agbbox').checked) {
		if (window.frames['uploadframe'].$('gemabox').checked) {
			window.frames['uploadframe'].$('gema').value = 1;
		} else {
			window.frames['uploadframe'].$('gema').value = 0;
		}
		$('losbtnupload').style.display='none';
		var f = window.frames['uploadframe'].document.formularMovieUpload;
		if (validateMovieUpload(f)) {
			initProgressBarHandler(window.frames['uploadframe']);
			var fetcher = new Yur.API('upload/prepare',
				function (data) {
					submitForm(f, '/upload.pl/' + data.tracking_id);
					window.frames['uploadframe'].$('UploadFormular').style.display = 'none';
					window.frames['uploadframe'].$('UploadStatus').style.display = 'block';
					trackUploadFrame(data.tracking_id);
				},
				function (x) { unlockButton(btn); alert("upload failed ... " + x) }
			);
//			fetcher.debug = true;
			fetcher.post({
				queue:			f.queue.value,
				title:			f.title.value,
				description:	f.description.value,
				gema:			f.gema.value
			});
		} else {
			parent.document.getElementById('losbtnupload').style.display='';
		}
	} else {
		alert('Bitte stimme den Nutzungsbedingungen zu.');
	}
}


function submitMovieUploadCamps(btn) {
	if ($('agbbox').checked) {
		hide('btnact');
		show('btnin');
		
		var f = $('formularMovieUpload');
		if (validateMovieUpload(f)) {
			var fetcher = new Yur.API('upload/preparewithoutlogin',
				function (data) {
					submitForm(f, '/upload.pl/' + data.tracking_id);
					$('UploadFormular').style.display = 'none';
					$('UploadStatus').style.display = 'block';
					trackUploadWithoutLogin(data.tracking_id);
				},
				function (x) { unlockButton(btn); alert("upload failed ... " + x) }
			);
//			fetcher.debug = true;
			fetcher.post({
				meta_queue:		f.queue.value,
				actual_queue:	0,
				uploadername:	f.uploadername.value,
				title:			f.title.value,
				description:	f.description.value,
				gema:	f.gema.value
			});
		} else {
			show('btnact');
			hide('btnin');
		}
	} else {
		alert('Bitte stimme den Nutzungsbedingungen zu.');
	}
}

function submitOffence(btn) {
	var f = $('formularVerstoss');
	hide('btnact');
	show('btnin');
	var fetcher = new Yur.API('offence',
		function (data) {
			hide('hide1');
			hide('hide2');
			hide('hide3');
			show('show1');
			show('show2');
		}
	);
	fetcher.post({
		movieid:	f.movieid.value,
		description: f.description.value
	});
}



function submitMovieDownload() {
	if ($('agbbox').checked) {
		$('formularMovieUpload').submit()
	}
	else {
		alert('Bitte stimme den Nutzungsbedingungen zu.');
	}
}

function submitPodcastAbo() {
	if ($('agbbox').checked) {
		$('formularMovieUpload').submit()
	}
	else {
		alert('Bitte stimme den Nutzungsbedingungen zu.');
	}
}

function trackUpload(tracking_id) {
	var fetcher = new Yur.API('upload/status',
		function (data) {
			updateUploadContainer(data);
			if (data.status < 2) setTimeout(function () { trackUpload(tracking_id) }, 3000)
		 }
	);
//	fetcher.debug = true;
	fetcher.post({
		tracking_id: tracking_id
	});
}

function trackUploadWithoutLogin(tracking_id) {
	var fetcher = new Yur.API('upload/statuswithoutlogin',
		function (data) {
			updateUploadContainer(data);
			if (data.status < 2) setTimeout(function () { trackUploadWithoutLogin(tracking_id) }, 3000)
		 }
	);
//	fetcher.debug = true;
	fetcher.post({
		tracking_id: tracking_id
	});
}

function trackUploadFrame(tracking_id) {
	var fetcher = new Yur.API('upload/status',
		function (data) {
			updateUploadContainerFrame(data);
			if (data.status < 2) setTimeout(function () { trackUploadFrame(tracking_id) }, 3000)
		 }
	);
//	fetcher.debug = true;
	fetcher.post({
		tracking_id: tracking_id
	});
}

function updateUploadContainerFrame(data) {
	var c = window.frames['uploadframe'].$('UploadStatus');
	if (data.status == 2) {
		myJsProgressBarHandler.setPercentage('progress_bar',"100");
		setTimeout('window.frames["uploadframe"].$("UploadStatus").innerHTML = window.frames["uploadframe"].$("UploadDone").innerHTML',1000);
	} else if (data.status == 3) {
		c.innerHTML = "<br>Hochladen fehlgeschlagen :(<br>";
	} else if (data.status == 1) {
		var p = Math.round(((data.size * 100) / data.estimated_size) * 10) / 10;
		myJsProgressBarHandler.setPercentage('progress_bar',p.toFixed(0));
	} else {
		myJsProgressBarHandler.setPercentage('progress_bar',"0");
	}
}

function updateUploadContainer(data) {
	var c = $('UploadStatus');
	if (data.status == 2) {
		myJsProgressBarHandler.setPercentage('progress_bar',"100");
		setTimeout('$("UploadStatus").innerHTML = $("UploadDone").innerHTML',1000);
	} else if (data.status == 3) {
		c.innerHTML = "<br>Hochladen fehlgeschlagen :(<br>";
	} else if (data.status == 1) {
		var p = Math.round(((data.size * 100) / data.estimated_size) * 10) / 10;
		myJsProgressBarHandler.setPercentage('progress_bar',p.toFixed(0));
	} else {
		myJsProgressBarHandler.setPercentage('progress_bar',"0");
	}
}

function resetUploadFormular() {
	var f = $('UploadFormular');
	var c = $('UploadStatus');

	$('formularMovieUpload').reset();
	c.style.display = 'none';
	if (f) f.style.display = 'block'
	else $('uploadFormular').style.visibility = ''
	c.innerHTML = 'Lade hoch ...<br><span class="progressBar percentImage" id="progress_bar">0%</span>';
	if ($('btnact')) show('btnact');
	if ($('btnin')) hide('btnin');
}

function validateMovieUpload(form) {
	var error;
	var type = form.upload_type.options[form.upload_type.selectedIndex].value;
	if (type == "url") {
		error= validateForm(form, "thema", "", "R", "title", "", "R", "url", "", "R");
	} else {
		error= validateForm(form, "thema", "", "R", "title", "", "R", "video", "", "R");
	}
	if (error != '') {
		publishError(error);
		return false;
	}
	return true;
}


/* Verarbeitung/Validierung des Handy-Confirm Formulares */


function submitConfirmHandy(btn) {
	if (lockButton(btn, 'best&auml;tige ...')) {
		var f = $('formularConfirmHandy')
		if (validateConfirmHandy(f)) submitForm(f) 
		else unlockButton(btn, 'best&auml;tige')
	}
}

function validateConfirmHandy(form) {
	var error = validateForm(form, "pin", "Pin", "RZahl");
	if (error != '') {
		publishError(error);
		return false;
	}
	return true;
}


/* Funktionen zum Un/Locken von Buttons */

function lockButton(btn, msg) {
	if (btn.lbLock) return false;
	var x = document.createElement('div');
	x.innerHTML   = msg;
	btn.lbLock    = true;
	btn.lbBackup  = btn.value;
	btn.value     = x.innerHTML;
	return true;
}

function unlockButton(btn, msg) {
	if (!btn.lbLock) return false;
	btn.lbLock = false;
	btn.value  = btn.lbBackup;
	return true;
}




function doMoviePreview(id, from) {
	setTimeout(function() {__Yur.moviePreview.show(id, from)}, 1);
}

function reason(status) {
	if (status == "20") {
		alert('Dieser Clip wurde vom User deaktiviert.');
	}
}

function setHiddenFromCheckbox(name) {
	if ($(name+'_box').checked) {
		$(name).value = 1;
	}
}

function setHiddenFromCheckboxAll() {
	setHiddenFromCheckbox('handy_is_public');
	setHiddenFromCheckbox('vorname_is_public');
	setHiddenFromCheckbox('name_is_public');
	//setHiddenFromCheckbox('anrede_is_public');
	setHiddenFromCheckbox('strasse_is_public');
	//setHiddenFromCheckbox('zusatz_is_public');
	setHiddenFromCheckbox('plz_is_public');
	//setHiddenFromCheckbox('ort_is_public');
	setHiddenFromCheckbox('land_is_public');
	setHiddenFromCheckbox('homepage_is_public');
	setHiddenFromCheckbox('geburtstag_is_public');
	setHiddenFromCheckbox('email_is_public');
	setHiddenFromCheckbox('flirtmodus');
	setHiddenFromCheckbox('newsletter');
	//setHiddenFromCheckbox('beschreibung_is_public');
	//setHiddenFromCheckbox('image_is_public');
	//setHiddenFromCheckbox('registriert_seit_is_public');
}
function Site_setCookie(name, value, expires, path, domain, secure) {
    document.cookie= name + "=" + escape(value) +
        ((expires) ? "; expires=" + expires.toGMTString() : "") +
        //((path) ? "; path=" + path : "") +
        "; path=/" + 
        ((domain) ? "; domain=" + domain : "") +
        ((secure) ? "; secure" : "");
}

function Site_readCookie(cookieName) {
	var theCookie=""+document.cookie;
	var ind=theCookie.indexOf(cookieName);
	if (ind==-1 || cookieName=="") {
		return ""; 
	}
	
	var ind1=theCookie.indexOf(';',ind);
	if (ind1==-1) ind1=theCookie.length; 
	
	var value = unescape(theCookie.substring(ind+cookieName.length+1,ind1));
	
	if(value == ";") { // bug with IE
		return ""
	}
	return value
}


var attribWithAll="location=no,menubar=no,toolbar=no,status=yes";
attribWithAll+=",resizable=yes,scrollbars=yes,width=410,height=580";

var attribWithAllCamps="location=no,menubar=no,toolbar=no,status=yes";
attribWithAllCamps+=",resizable=yes,scrollbars=yes,width=423,height=440";

var attribWithAllVerstoss="location=no,menubar=no,toolbar=no,status=yes";
attribWithAllVerstoss+=",resizable=yes,scrollbars=yes,width=423,height=340";


function PopUpWithAll()
/* oeffnet das Popup-Fenster mit allem drum und dran an der Stelle (10,50) */
{
	var time = (new Date()).getTime();
	//var sendung = $('selectsendung').value;
	//subwindow = window.open("/howto?sendung="+sendung,"upload"+time,attribWithAll);
	subwindow = window.open("/howto","upload"+time,attribWithAll);
	subwindow.focus()
}

function VerstossPopUp(id)
{
	var time = (new Date()).getTime();
	subwindow = window.open("/offence/"+id,"verstoss"+time,attribWithAllVerstoss);
	subwindow.focus()
}

function PopUpWithAllCamps()
/* oeffnet das Popup-Fenster mit allem drum und dran an der Stelle (10,50) */
{
	var time = (new Date()).getTime();
	//var sendung = $('selectsendung').value;
	//subwindow = window.open("/howto?sendung="+sendung,"upload"+time,attribWithAll);
	subwindow = window.open("/howtocamps","upload"+time,attribWithAllCamps);
	subwindow.focus()
}

function PopUpFileDownload()
/* oeffnet das Popup-Fenster mit allem drum und dran an der Stelle (10,50) */
{
	var time = (new Date()).getTime();
	//var sendung = $('selectsendung').value;
	//subwindow = window.open("/howto?sendung="+sendung,"upload"+time,attribWithAll);
	subwindow = window.open("/movie_download_window","upload"+time,attribWithAll);
	subwindow.focus()
}

function PopUpPodcastAbo()
/* oeffnet das Popup-Fenster mit allem drum und dran an der Stelle (10,50) */
{
	var time = (new Date()).getTime();
	//var sendung = $('selectsendung').value;
	//subwindow = window.open("/howto?sendung="+sendung,"upload"+time,attribWithAll);
	subwindow = window.open("/podcast/abo","podcast"+time,attribWithAll);
	subwindow.focus()
}

function PopUpWithAllorLogin()
/* oeffnet das Popup-Fenster mit allem drum und dran an der Stelle (10,50) */
{
	if (__Yur.session.logged_in) {
	var time = (new Date()).getTime();
	//var sendung = $('selectsendung').value;
	//subwindow = window.open("/howto?sendung="+sendung,"upload"+time,attribWithAll);
	subwindow = window.open("/howto","upload"+time,attribWithAll);
	subwindow.focus()
	} else {
		location.href='/login';
	}
}

function PopUpWithAllorLoginSelect(queue)
/* oeffnet das Popup-Fenster mit allem drum und dran an der Stelle (10,50) */
{
	if (__Yur.session.logged_in) {
	var time = (new Date()).getTime();
	//var sendung = $('selectsendung').value;
	//subwindow = window.open("/howto?sendung="+sendung,"upload"+time,attribWithAll);
	subwindow = window.open("/howto/"+queue,"upload"+time,attribWithAll);
	subwindow.focus()
	} else {
		location.href='/login';
	}
}


function show(id) {
	$(id).style.display='';
}

function hide(id) {
	$(id).style.display='none';
}


function MM_swapImgRestore() { //v3.0
  var i,x,a=document.MM_sr; for(i=0;a&&i<a.length&&(x=a[i])&&x.oSrc;i++) x.src=x.oSrc;
}

function MM_preloadImages() { //v3.0
  var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array();
    var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0; i<a.length; i++)
    if (a[i].indexOf("#")!=0){ d.MM_p[j]=new Image; d.MM_p[j++].src=a[i];}}
}

function MM_swapImage() { //v3.0
  var i,j=0,x,a=MM_swapImage.arguments; document.MM_sr=new Array; for(i=0;i<(a.length-2);i+=3)
   if ((x=MM_findObj(a[i]))!=null){document.MM_sr[j++]=x; if(!x.oSrc) x.oSrc=x.src; x.src=a[i+2];}
}

function switchClass(id,toClass) {
	if ($(id)) {
		if ($(id).className != toClass) {
			$(id).className=toClass;
		}
	}
}



function toggleGEMA(cbox, movie_id) {
	if (cbox.getting_saved) {
		return false;
	}
	var fetcher = new Yur.API("toggle_gema",
					function (data) {
						cbox.getting_saved = false;
						if (!data.success) {
							cbox.checked = !obj.checked;
							alert("Beim Speichern ist ein Fehler aufgetreten.");
						}
					},
					function () {
						cbox.getting_saved = false;
						cbox.checked = !obj.checked;
						alert("Beim Speichern ist ein Fehler aufgetreten.");
					}
				  )
	cbox.getting_saved = true;
	var gema = 1;
	if (!cbox.checked) { gema = 0 }
	fetcher.post({ id: movie_id, gema: gema });
	return true;
}




function loadScript(url) {
	var s = document.createElement('script');
	s.type = "text/javascript";
	s.src = url;
	document.body.appendChild(s);
}

function bookmark(name) {
	bookmarkurl='http://www.yur.tv';
	bookmarktitle='YUR.tv - Der Fernsehsender der Internet-Community';
	switch(name) {		
		case 'delicious':
			window.open('http://del.icio.us/post?url='+bookmarkurl+'&title='+bookmarktitle);
			break;
		case 'wong':
			window.open('http://www.mister-wong.de/index.php?action=addurl&bm_url='+bookmarkurl+'&bm_description='+bookmarktitle);
			break;
		case 'blinkList':
			window.open('http://www.blinklist.com/index.php?Action=Blink/addblink.php&Description=&Url='+bookmarkurl+'&Title='+bookmarktitle);
			break;
		case 'yahoo':
			window.open('http://myweb2.search.yahoo.com/myresults/bookmarklet?u='+bookmarkurl+'&t='+bookmarktitle);
			break;
		case 'yigg':
			window.open('http://yigg.de/neu?exturl='+bookmarkurl+'&exttitle='+bookmarktitle);
			break;	
		case 'furl':
			window.open('http://www.furl.net/storeIt.jsp?u='+bookmarkurl+'&t='+bookmarktitle);
			break;
		case 'oneview':
			window.open('http://beta.oneview.de:80/quickadd/neu/addBookmark.jsf?URL='+bookmarkurl+'&title='+bookmarktitle);			
			break;
		case 'folkd':
			window.open('http://www.folkd.com/submit/page/'+bookmarkurl);
			break;
		case 'linkarena':	
			window.open('http://linkarena.com/bookmarks/addlink/?url='+bookmarkurl+'&title='+bookmarktitle+'&desc=&tags=');
			break;
		case 'google': 		
			window.open('http://www.google.com/bookmarks/mark?op=add&hl=de&bkmk='+bookmarkurl+'&title='+bookmarktitle);
			break;
		case 'webnews': 		
			window.open('http://www.webnews.de/einstellen?url='+bookmarkurl+'&title='+bookmarktitle);
			break;
		case 'tausendreporter': 		
			window.open('http://tausendreporter.stern.de/submit.php?url='+bookmarkurl);
			break;
	}
}


function switchClassTo(obj,classname) {
	if (obj) {
		if (obj.className != classname) {
			obj.className=classname;
		}
	}
}

function bgs() {
	var supported = /MSIE ((5\.5)|[6789])/.test(navigator.userAgent) && navigator.platform == "Win32";
	if (supported) {
		var l = document.all.length;
		for (var i = 0; i < l; i++) {
			var bg = document.all[i].currentStyle.backgroundImage;
			if (bg) {
				if (bg.match(/\.png/i) != null) {
					var mypng = bg.substring(5,bg.length-2);
					document.all[i].style.filter = "progid:DXImageTransform.Microsoft.AlphaImageLoader(src='"+mypng+"', sizingMethod='scale')";
					document.all[i].style.backgroundImage = "url(/pics/shared/t.gif)";
				}
			}
 		}
 	}
}

function resizemovie() {
	var tmpwidth = $('middle').clientWidth-8;
	var ratio = 4/3;
	var tmpheight = tmpwidth / ratio;
	tmpheight = Math.round(tmpheight);
	$('playerContainer2Movie').height = tmpheight+'px';
}



function ProgrammUebersichtResize() {
		if (!(/MSIE ((5\.5)|[6789])/.test(navigator.userAgent) && navigator.platform == "Win32")) { return; }
		var xScroll, yScroll;
		if (window.innerHeight && window.scrollMaxY) {	
			xScroll = window.innerWidth + window.scrollMaxX;
			yScroll = window.innerHeight + window.scrollMaxY;
		} else if (document.body.scrollHeight > document.body.offsetHeight){ 
			xScroll = document.body.scrollWidth;
			yScroll = document.body.scrollHeight;
		} else { 
			xScroll = document.body.offsetWidth;
			yScroll = document.body.offsetHeight;
		}
		
		var windowWidth, windowHeight;
		
		if (self.innerHeight) {	// all except Explorer
			if(document.documentElement.clientWidth){
				windowWidth = document.documentElement.clientWidth; 
			} else {
				windowWidth = self.innerWidth;
			}
			windowHeight = self.innerHeight;
		} else if (document.documentElement && document.documentElement.clientHeight) {
			windowWidth = document.documentElement.clientWidth;
			windowHeight = document.documentElement.clientHeight;
		} else if (document.body) { 
			windowWidth = document.body.clientWidth;
			windowHeight = document.body.clientHeight;
		}	
		
		if(yScroll < windowHeight){
			hoehe = windowHeight;
		} else { 
			hoehe = yScroll;
		}
	
		if(xScroll < windowWidth){	
			breite = xScroll;		
		} else {
			breite = windowWidth;
		}
		if (breite < 1004) {
			breite = 1004;
		}
		
		obj = document.getElementById('programmuebersichtbg');
		obj.style.width= breite + 'px';
		obj.style.height= hoehe + 'px';

		obj = document.getElementById('programmuebersicht');
		obj.style.width= breite + 'px';
		obj.style.height= hoehe + 'px';
}
	
function ProgrammUebersichtShow() {
		obj = document.getElementById('programmuebersicht');
		obj.style.display = '';
		obj = document.getElementById('programmuebersichtbg');
		obj.style.display = '';
	
		ProgrammUebersichtResize();
		var old = window.onresize;
		if (typeof window.onresize != 'function') {
			window.onresize = ProgrammUebersichtResize;
		} else {
			window.onresize = function(e) {
				old(e);
				ProgrammUebersichtResize(e);
			}
		}
		
		var chatbox = $('chatcontainer');
		if (chatbox) chatbox.style.display = 'none';
		
		var movie   = $("playerContainer2Movie");
		if(movie)    movie.style.display   = "none"
		
//		AlleFlash-Objekte und DropDownlisten ausblenden.
//		Programm per Ajax laden (komplett damit kein Nachladen notwendig)
		ProgrammUebersichtLoad();
}

function ProgrammUebersichtLoad (page) {
	if (!page) page = 1;
	var ts = $('timingSelector');
	var timing = ts ? ts.options[ts.selectedIndex].value : '';
	var options = {
		parameters:	"page="+page+"&timing="+timing
	};
	new Ajax.Updater('programmuebersicht', '/programmuebersicht/', options);
}
	
function ProgrammUebersichtClose() {
		obj = $('programmuebersicht');
		obj.style.display = 'none';
		obj = $('programmuebersichtbg');
		obj.style.display = 'none';
		var chatbox = $('chatcontainer');
		if (chatbox) chatbox.style.display = '';
		
		var movie   = $("playerContainer2Movie");
		if(movie)    movie.style.display = "block"
}
	
function ProgrammUebersichtToggle(id, zusatz) {
		obj = $('format' + id);
		if (obj.style.display == 'none') {
			obj.style.display = ''; 
			obj = $('formatpfeil' + id);
			if (zusatz == 'act') {
				obj.src = '/pics/shared/programmuebersicht/apfeil_act.gif';
			} else {
				obj.src = '/pics/shared/programmuebersicht/pfeil_act.gif';
			}
		} else {
			obj.style.display = 'none';
			obj = $('formatpfeil' + id);
			if (zusatz == 'act') {
				obj.src = '/pics/shared/programmuebersicht/apfeil.gif';
			} else {
				obj.src = '/pics/shared/programmuebersicht/pfeil.gif';
			}
		}
}

function ProgrammUebersichtOrange (id, orange) {
	var c = orange ? 'orange cursor' : 'cursor';
	$('progTR'+id+'A').className = c;
	$('progTR'+id+'B').className = c;
	$('progTR'+id+'C').className = c;
}

// ##########################
// File: /storage/www/yur/www/lib/Yur.js
// ##########################
$LOG = function (msg) {
	if(!__Yur.debugMode) { // no debug output
		return
	}
	
	
	var stringMsg = new String(msg);
	var grep      = __Yur.debugGrep != "";	
	if(grep && stringMsg.indexOf(__Yur.debugGrep) == -1) {
		return
	}

	var log  = $("logArea");
	
	var html = new String( "" + msg + "\n" + log.innerHTML );
	
	html = html.substr( 0, 1000 );
	
	log.innerHTML = html;
}

function Yur_setUpNamespace(array) {
	var o = window
	for(var i = 0; i<array.length; i++) {
		var name = array[i]
		if(o[name] == null) {
			o[name] = {}
		}
		o = o[name]
	}
}

Yur = function () {}

Yur.inherit = function(source, destination) {
	
	for(var i in source.prototype) {
		if(destination.prototype[i] == null) {
			destination.prototype[i] = source.prototype[i]
		}
	}
	
	destination.prototype["super"] = function () {
		return source.prototype
	}
}

Yur.instance = function () {
	if(__Yur != null) {
		return Yur
	}
	__Yur = new Yur();
	return __Yur;
}

Yur.prototype.initialize = function (where) {

	
	// Safari absturz
	/*if(where == "homepage" || where == "ranking" ) {
		if(navigator.userAgent.indexOf("AppleWebKit") != -1) {
			location.href = "/safari.html"
		}
	}*/

	if (where == 'fullscreen') this.fullscreen = true
	else this.fullscreen = false;

	this.sitename = where; 
	this.votespecial = 0;
	this.queue_hide = 0;
	this.channel = 1;

	if (this.initialized) return;
	this.initialized = true;

	var me = this;

	this.freezers = new Yur.List();
	this.votes = new Yur.List();

	this.tool = new Yur.Toolbox();
	
	this.adver = new Yur.Adver();

	//this.operatorBlende = new Yur.TV.OperatorBlende();

	if (__Yur.sitename == 'homepage') {}
	
	if (__Yur.sitename == 'ranking') {
		this.ranking = new Yur.TV.Ranking();
	}
	
	if (__Yur.sitename == 'preiseranking') {
		this.preisranking = new Yur.TV.PreiseRanking();
	}
	
	if (__Yur.sitename == 'deinesendung') {
		this.sendform = new Yur.TV.SendForm();
	}
	
	if (__Yur.sitename == 'charts') {
		this.charts = new Yur.TV.Charts();
	}
	
	if (__Yur.sitename == 'my_user_channel') {
		this.meinyurtv = new Yur.TV.MeinYURtv();
		//this.gcontent = new Yur.TV.GenerallyContent();
	}

	if (__Yur.sitename == 'meinyurtv') {
		//this.meinyurtv = new Yur.TV.MeinYURtv();
		//this.gcontent = new Yur.TV.GenerallyContent();
	}
	
	if (__Yur.sitename == 'userchannel') {
		this.lastkommentar = new Yur.TV.LastKommentar();
		this.friends = new Yur.TV.Friends();
	}	

	this.now   = new Yur.TV.NowPlaying();

	//this.navigations = new Array();

	this.load_steps = {
		body_onload: false,
		session_sync: false
	};
	
	this.playlist_id = 1;
	
}

Yur.prototype.addVotes = function (data) {
	for(var i=0; i<data.length;i++) {
		this.votes.insert(data[i]);
	}

	$LOG(data.length + " Vote/en wurden geladen");
}

Yur.prototype.darfVoten = function (movie) {
	return true;
	if(!this.load_steps.session_sync) {
		throw new Error("Votes sind noch nicht geladen");
	}
	if (this.votes.isIn(movie)) return false;
	return true;
}

Yur.prototype.freeze = function (obj) {
	$LOG("Freeze");
	this.freezers.insert(obj);
}

Yur.prototype.unfreeze = function (obj) {
	$LOG("Unfreeze");
	this.freezers.remove(obj);
	if (!this.freezing()) $LOG("No more freeze!");
}

Yur.prototype.freezing = function () {
	return !this.freezers.isEmpty();
}

Yur.prototype.date = function () {	
	if(this.time_offset == null) {
		throw new Error("Not yet synced");
	}
	
	var now    = new Date();
	
	now.setTime(now.getTime() + this.time_offset);
	
	$LOG("Time: "+now + " OFfset "+this.time_offset)
	
	return now;
}

Yur.prototype.loaded = function(key) {
	if (this.load_steps[key]) return;
	this.load_steps[key] = true;
	for(var i in this.load_steps) {
		if(!this.load_steps[i]) {
			return
		}
	}
	this.onLoad();
}


Yur.prototype.updateQueue = function () {
	var me     = this;
	this.update_queue          = true;
	
	this.queue_update_interval = window.setInterval(
		function () { 
			me.now.fetchData();
		},
		4000
	)
	
	// initial
	me.now.fetchData();
}


Yur.prototype.bodyOnLoad = function () {
	var me = this;

	this.session        = new Yur.TV.Session();
	this.session.onSync = function (data) {
		me.time_offset  = new Number(data.offset) * 1000;
		me.loaded('session_sync')
	};
	this.session.sync();
	
	this.player    = new Yur.Player("player");
	
	this.spotlight = new Yur.Spotlight();
	
	this.loaded('body_onload');
}

Yur.prototype.onLoad = function () {
	
	if (this.sitename == 'homepage') {
		//this.nav('operator').activate(0);
		//this.nav('Hauptnavi').activate(0);
		this.updateQueue();
		//this.doInitialNavigation()
	}

	if (this.sitename == 'programmzeitschrift') {
		this.updateQueue();
	}	
	
	if (this.sitename == 'ranking') {
		this.nav('Hauptnavi').activate(2);
		this.ranking.show()
	}
	
	if (this.sitename == 'preiseranking') {
		this.preisranking.show();
	}	

	if (this.sitename == 'charts') {
		this.charts.show()
	}
	
	if (this.sitename == 'remote') {
		this.updateQueue();
	}
	
	if (this.sitename == 'meinyurtv') {
		//if (this.current_id && !(this.UpdateError)) {
			//this.nav('Hauptnavi').activate(6);
			//this.gcontent.loadMeinYURtvMovies(this.current_id,1);
		//}
	}
	
	if (this.sitename == 'sendungen') {
		this.nav('Hauptnavi').activate(5);
	}

	if (this.sitename == 'errorsite') {
		this.updateQueue();
	}	

	if (this.sitename == 'userchannel') {
		this.updateQueue();
	}	
	
	if (this.sitename == 'standardCMS') {
		this.updateQueue();
	}		
	
}

Yur.prototype.doInitialNavigation = function () {
	var hash = new String(location.hash);
	
	if(hash.indexOf("#go") == 0) {
		var action = hash.substr(3,255);
		if (action == "Register") {
			this.myTV.showRegister();
		} else {
			this[action].show();
		}
	}
	
}


Yur.prototype.nav = function (name) {

}

Yur.prototype.windowHeight = function () {

	if (window.innerHeight) {
		return window.innerHeight;
  	} else if (document.documentElement && document.documentElement.clientHeight) {
    	return document.documentElement.clientHeight;
	} else {
    	$LOG("Cant find window height")
	}
}

Yur.prototype.windowWidth = function () {
 	if (window.innerWidth) {
		return window.innerWidth;
  	} else if (document.documentElement && document.documentElement.clientWidth) {
    	return document.documentElement.clientWidth;
	} else {
    	$LOG("Cant find window width")
	}	
}

Yur.prototype.gongshow_vote = function (what) {
	if (this.now && this.now.interaktionsfeld) {
		if (what) this.now.interaktionsfeld.vote_good()
		else this.now.interaktionsfeld.vote_sucks()
	}
}

Yur.prototype.gongshow_onmouseover = function (where) {
	if (this.now && this.now.interaktionsfeld) this.now.interaktionsfeld.onmouseover(where)
}

Yur.prototype.gongshow_onmouseout = function () {
	if (this.now && this.now.interaktionsfeld) this.now.interaktionsfeld.onmouseout()
}

Yur.prototype.showBigInfoLayer = function (url) {
	if($('Operator')) $('Operator').style.display = 'none';
	if (this.fullscreen) {
		if ($('StreamingContainerFullscreen')) $('StreamingContainerFullscreen').style.visibility = 'hidden';
		var bii = $('BigInfoIFrame');
		var bil = $('BigInfoLayer');
		var p = new Yur.Player.Writer("quicktime");
		p.setFullscreenDimensions();
		bii.style.width  = p.width() + "px";
		bii.style.height = p.height() + "px";
		bil.style.width  = p.width() + "px";
		bil.style.height = p.height() + "px";
	} else {
		if($('Streaming')) $('Streaming').style.visibility = 'hidden';
	}
	if($('BigInfoIFrame')) $('BigInfoIFrame').src = url;
	if($('BigInfoLayer')) $('BigInfoLayer').style.display = 'block';
}

Yur.prototype.hideBigInfoLayer = function () {
	if($('BigInfoLayer')) $('BigInfoLayer').style.display = 'none';
	if($('BigInfoIFrame')) $('BigInfoIFrame').src = '/blank.html';
	if($('Operator')) $('Operator').style.display = 'block';
	if (this.fullscreen) {
		if ($('StreamingContainerFullscreen')) $('StreamingContainerFullscreen').style.visibility = 'visible'
	} else {
		if($('Streaming')) $('Streaming').style.visibility = 'visible';
	}
}

Yur.prototype.loadingHTML = function (name) {
	return '<div class="loading"><img src="/pics/' + name + '.gif" border="0"></div>';
}

Yur.prototype.gotoChannel =	function (channel) {
 	var me = this;
	var fetcher = new Yur.API("alias_by_channel", function (data) { me.gotoChannelDataReceived(data); })
	fetcher.cached = false;
	fetcher.setCacheIntervalSeconds(0);
	fetcher.debug = false;
	fetcher.get({
		channel: channel			
	});
}

Yur.prototype.gotoChannelDataReceived = function (data) {
	if (data.alias) {
		location.href = '/channel/'+data.alias
	} else {
		alert(unescape('Es ist ein %DCbertragungsfehler aufgetreten.'));
	}
}


Yur.tearDownLiveStream = function () { // this makes unloading in firefox much faster!
	if($("playerContainer2Movie")) {
		var player = document.getFlashMovieById("playerId");
		if(player != null && player.pause) {
			player.pause()
		}
		$("playerContainer2Movie").innerHTML = "";
	}
}
window.onunload = Yur.tearDownLiveStream;

Yur.prototype.switchchannel = function (direction) {
	var me = this;
	if (direction == 'up') {
		if (this.channel == window.all_channels_name.length) {this.channel = 1} else {this.channel++}
	} else {
		if (this.channel == 1) {this.channel = window.all_channels_name.length} else {this.channel--}
	}	
	
	var tmp_channel = this.channel;
	$('channel_number').innerHTML = this.channel;
	
	var player = document.getFlashMovieById("playerId");
	if(player != null && player.showChannel) {
		player.showChannel(window.all_channels_name[me.channel-1])
	}
	
	window.setTimeout(
		function () {
			if (tmp_channel == me.channel) {
			
				Yur.tearDownLiveStream()
			
				location.href = window.all_channels_link[me.channel-1];
				//me.gotoChannel(me.channel);
			}
		},
		800);
}

var __Yur = Yur.instance()

Yur.prototype.loadLastKommentar = function (movie_id) {
	var obj      = new Yur.BO.LastKommentar();
	obj.fromData(movie_id);
	obj.display();
}

Yur.prototype.addclick =	function (movie) {
 	var me = this;
	var fetcher = new Yur.API("add_movie_click", function (data) {})
	fetcher.cached = false;
	fetcher.setCacheIntervalSeconds(0);
	fetcher.debug = false;
	fetcher.get({
		movie: movie			
	});
}

Yur.prototype.addfriend =	function (alias) {
 	var me = this;
	var fetcher = new Yur.API("add_friend", function (data) {me.addfriendDataReceived(data);})
	fetcher.cached = false;
	fetcher.setCacheIntervalSeconds(0);
	fetcher.debug = false;
	fetcher.get({
		alias: alias			
	});
}

Yur.prototype.addfriendDataReceived = function (data) {
	if (data.succes) {
		alert(unescape('Dieser Channel wurde erfolgreich zu Deiner Freundesliste hinzugef%FCgt.'));
	} else if (data.schon_vorhanden) {
		alert(unescape('Dieser Channel ist bereits in Deiner Freundesliste.'));
	} else if (data.logged_in_error) {
		alert(unescape('Um diesen Channel zur Freundesliste hinzuf%FCgen zu k%F6nnen, log dich bitte ein.'));
	} else {
		alert(unescape('Es ist zu einem %DCbertragungsfehler gekommen. Bitte versuche es sp%E4ter noch einmal.'));
	}
}

Yur.prototype.ReportSpamKommentar =	function (id) {
 	var me = this;
	var fetcher = new Yur.API("report_spam_kommentar", function (data) {if (data.succes) {alert('Der Report wurde erfolgreich verschickt.')} else {alert(unescape('Es ist zu einem %DCbertragungsfehler gekommen. Bitte versuche es sp%E4ter noch einmal.'))}})
	fetcher.cached = false;
	fetcher.setCacheIntervalSeconds(0);
	fetcher.debug = false;
	fetcher.get({
		id: id
	});
}

Yur.prototype.ReportSpamGuestbook =	function (id,alias) {
 	var me = this;
	var fetcher = new Yur.API("report_spam_guestbook", function (data) {if (data.succes) {alert('Der Report wurde erfolgreich verschickt.')} else {alert(unescape('Es ist zu einem %DCbertragungsfehler gekommen. Bitte versuche es sp%E4ter noch einmal.'))}})
	fetcher.cached = false;
	fetcher.setCacheIntervalSeconds(0);
	fetcher.debug = false;
	fetcher.get({
		id: id,
		alias: alias
	});
}

Yur.prototype.addchannelabo =	function (alias) {
 	var me = this;
	var fetcher = new Yur.API("add_channel_abo", function (data) {me.addchannelaboDataReceived(data);})
	fetcher.cached = false;
	fetcher.setCacheIntervalSeconds(0);
	fetcher.debug = false;
	fetcher.get({
		alias: alias
	});
}

Yur.prototype.addmetachannelabo =	function (channelname) {
 	var me = this;
	var fetcher = new Yur.API("add_channel_abo", function (data) {me.addchannelaboDataReceived(data);})
	fetcher.cached = false;
	fetcher.setCacheIntervalSeconds(0);
	fetcher.debug = false;
	fetcher.get({
		channelname: channelname
	});
}


Yur.prototype.addchannelaboDataReceived = function (data) {
	if (data.succes) {
		alert(unescape('Dieser Channel wurde erfolgreich zu deiner Aboliste hinzugef%FCgt.'));
	} else if (data.schon_vorhanden) {
		alert(unescape('Dieser Channel ist bereits in deiner Aboliste.'));
	} else if (data.logged_in_error) {
		alert(unescape('Um diesen Channel zur Aboliste hinzuf%FCgen zu k%F6nnen, log dich bitte ein.'));
	} else {
		alert(unescape('Es ist zu einem %DCbertragungsfehler gekommen. Bitte versuche es sp%E4ter noch einmal.'));
	}
}



// ##########################
// File: /storage/www/yur/www/lib/Yur/Adver.js
// ##########################
Yur_setUpNamespace(["Yur"])

Yur.Adver = function () {

	this.last_reload = new Date();
	
}

Yur.Adver.prototype = {
	age:  function (value) {
		var now = new Date();
		
		var dif = (now.getTime() - this.last_reload.getTime()) / 1000
		
		return Math.round(dif);
	},
	
	shouldExchange:  function () {
		
		//alert(""+this.age() +">"+ Yur.Paras.Adver_Min_Display_Seconds)
	
		if(this.age() > Yur.Paras.Adver_Min_Display_Seconds) {
			return true
		}
		return false
	},
	
	redraw:  function () {
		var div = $("Advertising");
		
		if(div != null) {
			var html      = div.innerHTML;
			div.innerHTML = html
		}
		
		this.last_reload = new Date();
	},
	
	click:	function () {
		if(this.shouldExchange()) {
			this.redraw()
		}
	}
}






// ##########################
// File: /storage/www/yur/www/lib/Yur/API.js
// ##########################
Yur_setUpNamespace(["Yur"])


Yur.API = function(action, onSuccess, onFailure) {
	this.action = action;
	this.onSuccess = onSuccess
	if(onFailure != null) {
		this.onFailure = onFailure;
	} else {
		this.onFailure = function (error) {
			$LOG(error.asString())
		}
	}
	
	this.cached                 = false;
	this.cache_interval_seconds = 20;
	this.is_error_report        = false;
}

Yur.API.prototype.setCacheIntervalSeconds  = function (interval) {
	this.cache_interval_seconds = interval
}

Yur.API.prototype.post  = function (paras) {
	this._call("post", paras)
}

Yur.API.prototype.get  = function (paras) {
	this._call("get", paras)
}

Yur.API.prototype._call = function (method, paras) {
	
	var url  = "/api/" + this.action;
	
	if(this.cached) {
		var now = __Yur.date().getTimeSeconds();
		var mod = now % this.cache_interval_seconds;
		now     = now - mod;
		url = url + "/" + now
	} else {
		url = url + "/" + Math.random();
	}

	var para_string = null;
	
	if(paras != null) {
		para_string = $H(paras).toQueryString();	
		$LOG("Paras: "+para_string)
		if(para_string == "") {
			para_string = null
		}
	}
	
	if (this.debug) alert("DEBUG Request URL: " + url + "\nMethod: " + method + "\nParameters: " + para_string);
	
	var me = this
	var ajax = new Ajax.Request(
			url, 
			{
				method:     method, 
				parameters: para_string, 
				onComplete: function (request) { me.handleResponse(request) },
				onException: function (x,e) {if (console) console.debug("onException:"+e); document.last_error = e; }
			});
}

Yur.API.prototype.handleResponse = function (request) {
	var text = request.responseText;
	if (this.debug) alert("DEBUG Response-Text: " + text)
	text     = new String(text);

	try {	
		var obj  = text.parseJSON();
	
		if(obj.is_error == "1") {
			var error = new Yur.Error(obj.error_string, obj.error_class);
			if (this.debug) alert(this.action + '->onError(...)');
			this.onFailure(error);
		} else {
			if (this.debug) alert(this.action + '->onSuccess(...)');
			this.onSuccess(obj.data);
		}
	} catch (e) {
		if (this.debug) alert('Exception while doing ' + this.action + "\n" + e);
		if (!this.is_error_report) {
			var fetcher = new Yur.API('error/report', function () {});
			fetcher.is_error_report = true;
			fetcher.post({
				'error'         : "" + e,
				'typeof'        : typeof(e),
				'stack'         : e.stack,
				'action'        : this.action,
				'status'        : request.status,
				'appCodeName'   : navigator.appCodeName,
				'appName'       : navigator.appName,
				'appVersion'    : navigator.appVersion,
				'cookieEnabled' : navigator.cookieEnabled,
				'language'      : navigator.language,
				'platform'      : navigator.platform,
				'userAgent'     : navigator.userAgent,
				'href'			: document.location.href,
				'text'          : text
			});
		}
	}
}

// ##########################
// File: /storage/www/yur/www/lib/Yur/API2.js
// ##########################
/*Yur_setUpNamespace(["Yur"])


Yur.API = function(action, onSuccess, onFailure) {
	this.action = action;
	this.onSuccess = onSuccess
	if(onFailure != null) {
		this.onFailure = onFailure;
	} else {
		this.onFailure = function (error) {
			$LOG(error.asString())
		}
	}
	
	this.cached                 = false;
	this.cache_interval_seconds = 20; 
}

Yur.API.responseObjects = {};

Yur.API.prototype.setCacheIntervalSeconds  = function (interval) {
	this.cache_interval_seconds = interval
}

Yur.API.prototype.post  = function (paras) {
	this._call("post", paras)
}

Yur.API.prototype.get  = function (paras) {
	this._call("get", paras)
}

Yur.API.prototype._call = function (method, paras) {
	
	var url  = "/api/" + this.action;
	
	if(paras == null) {
		paras = {};
	}
	
	if(this.cached) {
		var now = __Yur.date().getTimeSeconds();
		var mod = now % this.cache_interval_seconds;
		now     = now - mod;
		url = url + "/" + now
	} else {
		url = url + "/" + Math.random();
	}
	
	var action = url;
	
	var para_string = null;
	
	paras.yur_asjs   = 1;
	
	if(paras != null) {
		para_string = $H(paras).toQueryString();	
		$LOG("Paras: "+para_string)
		if(para_string == "") {
			para_string = null
		}
	}
	
	var src = url +"?"+ para_string;
	
	Yur.API.responseObjects[action] = this;
	
	var s  = document.createElement("script");
	s.type = "text/javascript";
	s.src  = src;
	
	document.body.appendChild(s)
}

Yur.API.handleResponse = function (action,obj) {
	//if (this.debug) 
	
	var me   = Yur.API.responseObjects[action];
	
	if(me == null) {
		alert("Action: "+action)
	}
	
	if(obj.is_error == "1") {
		var error = new Yur.Error(obj.error_string, obj.error_class);
		me.onFailure(error);
	} else {
		try { $LOG(this.action + " -> onSuccess(...)"); me.onSuccess(obj.data) }
		catch (e) { $LOG(this.action + " -- " + e) }
	}
}
*/
// ##########################
// File: /storage/www/yur/www/lib/Yur/BO.js
// ##########################
Yur_setUpNamespace(["Yur"])


Yur.BO = function() {

}


Yur.BO.prototype = {
	fromData:	function (data) {
		for(var i in data) {
			this[i] = data[i]
		}
	},
	
	template:		function () {
		alert("Subclass Responsibility")
	},
	
	fullscreen: function () {
		return __Yur.fullscreen
	},
	
	draw:		function () {
		
		var template = this.template();
		
		//$LOG("drawing "+template+ " -> "+this.id)
		
		var result = Jemplate.process(template, {
			model: this,
			tool: __Yur.tool
		})
		
		return result
	},
	
	display:	function () {
		this.div().innerHTML = this.draw()
	},
	
	update:		function () { // incremental draw
		alert("Subclass Responsibility")
	},
	
	divName:	function () {
		return "obj" + this.id;
	},
	
	div:		function () {
		return $(this.divName())
	}
	
}

// ##########################
// File: /storage/www/yur/www/lib/Yur/BO/Airtime.js
// ##########################
Yur_setUpNamespace(["Yur", "BO"])


Yur.BO.Airtime = function() {
}


Yur.BO.Airtime.prototype = {
	
	template:	function () {
		return "current.js.html"
	},
	
	update:     function (dataRow) {
		
	},
	
	divName:	function () { // there is only one!!!!!
		return "cur"; 
	}
}

Yur.inherit(Yur.BO, Yur.BO.Airtime)


// ##########################
// File: /storage/www/yur/www/lib/Yur/BO/AirtimeKuecheVital.js
// ##########################
Yur_setUpNamespace(["Yur", "BO"])


Yur.BO.AirtimeKuecheVital = function() {
}


Yur.BO.AirtimeKuecheVital.prototype = {
	
	template:	function () {
		return "airtime_kueche_vital.js.html"
	},
	
	update:     function (dataRow) {
		
	},
	
	divName:	function () { // there is only one!!!!!
		return "kuechevital"; 
	}
}

Yur.inherit(Yur.BO, Yur.BO.AirtimeKuecheVital)


// ##########################
// File: /storage/www/yur/www/lib/Yur/BO/AirtimeVoteSpecial.js
// ##########################
Yur_setUpNamespace(["Yur", "BO"])


Yur.BO.AirtimeVoteSpecial = function() {
}


Yur.BO.AirtimeVoteSpecial.prototype = {
	
	template:	function () {
		return "airtime_vote_special.js.html"
	},
	
	update:     function (dataRow) {
		
	},
	
	divName:	function () { // there is only one!!!!!
		return "votespecial"; 
	}
}

Yur.inherit(Yur.BO, Yur.BO.AirtimeVoteSpecial)


// ##########################
// File: /storage/www/yur/www/lib/Yur/BO/Login.js
// ##########################
Yur_setUpNamespace(["Yur", "BO"])


Yur.BO.Login = function() {
}


Yur.BO.Login.prototype = {
	
	template:	function () {
		return "login.js.html"
	},
	
	update:     function (dataRow) {
		
	},
	
	divName:	function () { // there is only one!!!!!
		return "sessionLogout"; 
	}
}

Yur.inherit(Yur.BO, Yur.BO.Login)


// ##########################
// File: /storage/www/yur/www/lib/Yur/BO/Movie.js
// ##########################
Yur_setUpNamespace(["Yur", "BO"]);




Yur.BO.Movie = function () {
	this.movie = null;
	
	this.options = {
		debug_fetcher: 0,
		cache_interval_seconds: 60
	};
	
	this.requesting = false;
	this.voting = null;
}

Yur.BO.Movie.prototype = {

	template:		function () {
		return "movie_preview.js.html";
	},
	
	divName:		function () {
		return "MoviePreview"
	},

	onSuccess:		function (id) {},

	requestData:     function (movie_id) {
		if (this.requesting) return;
		var me = this;
		var fetcher = new Yur.API('movie', function (data) { me.saveResult(data) }, function () { me.saveResult() });
		fetcher.cached = true;
		fetcher.cache_interval_seconds = this.options.cache_interval_seconds;
		fetcher.debug = this.options.debug_fetcher;
		fetcher.get({
			id: movie_id
		});
		this.requesting = true;
		this.display();
	},

	saveResult:		function (data) {
		this.requesting = false;
		if (data != null && data.id) {
			this.movie = data;
			this.voting = new Yur.TV.Voting('', this.movie.id, this.movie.voting);
			this.voting.name = 'votePreview';
		} else {
			this.movie = null;
		}
		this.display();
		if (data != null && data.id) this.onSuccess(data.id)
		else this.onSuccess(null);
	}

}

Yur.inherit(Yur.BO, Yur.BO.Movie)




// ##########################
// File: /storage/www/yur/www/lib/Yur/BO/NextQueue.js
// ##########################
Yur_setUpNamespace(["Yur", "BO"])


Yur.BO.NextQueue = function() {
}


Yur.BO.NextQueue.prototype = {
	
	template:	function () {
		return "nextqueue.js.html"
	},
	
	update:     function (dataRow) {
		
	},
	
	divName:	function () { // there is only one!!!!!
		return "nextqueue"; 
	}
}

Yur.inherit(Yur.BO, Yur.BO.NextQueue)


// ##########################
// File: /storage/www/yur/www/lib/Yur/BO/Person.js
// ##########################
Yur_setUpNamespace(["Yur", "BO"]);




Yur.BO.Person = function () {
	this.person = null;
	
	this.options = {
		debug_fetcher: 0,
		cache_interval_seconds: 60
	};
}

Yur.BO.Person.prototype = {

	template:		function () {
		return "person_details.js.html";
	},
	
	divName:		function () {
		return "PersonDetails"
	},

	onSuccess:		function (data) {},

	requestData:     function (person_id) {
		var me = this;
		var fetcher = new Yur.API('person', function (data) { me.saveResult(data) });
		fetcher.cached = true;
		fetcher.cache_interval_seconds = this.options.cache_interval_seconds;
		fetcher.debug = this.options.debug_fetcher;
		fetcher.get({
			id: person_id
		});
	},

	saveResult:		function (data) {
		if (data && data.alias) {
			this.person = data;
			this.display();
			this.onSuccess(data);
		}
	}

}

Yur.inherit(Yur.BO, Yur.BO.Person)




// ##########################
// File: /storage/www/yur/www/lib/Yur/BO/Person/MeinYURMovies.js
// ##########################
Yur_setUpNamespace(["Yur", "BO", "Person"]);




Yur.BO.Person.MeinYURMovies = function () {
	this.data = null;
	
	this.options = {
		debug_fetcher: 0,
		cache_interval_seconds: 60,
		cached: false
	};
}

Yur.BO.Person.MeinYURMovies.prototype = {

	template:		function () {
		return "meinyurtv_movies.js.html";
	},
	
	div:			function () {
		return __Yur.gcontent.container();
	},

	onSuccess:		function (data) {},

	requestData:     function (person_id, page, archiv) {
		if (!page) page = 1;
		var me = this;
		var fetcher = new Yur.API('person/movies', function (data) { me.saveResult(data) });
		fetcher.cached = this.options.cached;
		fetcher.cache_interval_seconds = this.options.cache_interval_seconds;
		fetcher.debug = this.options.debug_fetcher;
		fetcher.get({
			id: person_id,
			page: page,
			archiv: archiv
		});
		$('GenerallyContent').innerHTML = __Yur.loadingHTML("loading_hell");
	},

	saveResult:		function (data) {
		this.data = data;
		try { this.display(); }
		catch (e) { alert(e) }
		this.onSuccess(data);
	}

}

Yur.inherit(Yur.BO, Yur.BO.Person.MeinYURMovies)




// ##########################
// File: /storage/www/yur/www/lib/Yur/BO/Person/Movies.js
// ##########################
Yur_setUpNamespace(["Yur", "BO", "Person"]);




Yur.BO.Person.Movies = function () {
	this.data = null;
	
	this.options = {
		debug_fetcher: 0,
		cache_interval_seconds: 60
	};
}

Yur.BO.Person.Movies.prototype = {

	template:		function () {
		return "person_movies.js.html";
	},
	
	div:			function () {
		return __Yur.gcontent.container();
	},

	onSuccess:		function (data) {},

	requestData:     function (person_id, page) {
		if (!page) page = 1;
		var me = this;
		var fetcher = new Yur.API('person/movies', function (data) { me.saveResult(data) });
		fetcher.cached = true;
		fetcher.cache_interval_seconds = this.options.cache_interval_seconds;
		fetcher.debug = this.options.debug_fetcher;
		fetcher.get({
			id: person_id,
			page: page
		});
	},

	saveResult:		function (data) {
		this.data = data;
		try { this.display(); }
		catch (e) { alert(e) }
		this.onSuccess(data);
	}

}

Yur.inherit(Yur.BO, Yur.BO.Person.Movies)




// ##########################
// File: /storage/www/yur/www/lib/Yur/BO/QueueItem.js
// ##########################
Yur_setUpNamespace(["Yur", "BO"])


Yur.BO.QueueItem = function() {
	this.tag = null;
	this.voting = null;
	this.options = {
		height:	74,
		musikcharts: 0,
		musikchartsqueue:33,
		space_top: 0
	};
}


Yur.BO.QueueItem.prototype = {
	
	template:	function () {
		if (this.queue == this.options.musikchartsqueue) {
			return "queue_item_charts.js.html"
		}
		return "queue_item.js.html"
	},
	
	update:     function (dataRow) {
		
		var top  = this.top();
		var style = this.div().style;
		
		// Verschiebe Element in der Liste an neue Position
		if(parseInt(style.top) != top) {
			style.top = "" + top + "px";
		}

		// Schreibe neue Positions-nummer ins Element
		if(dataRow.position != this.position) {
		
			$LOG("Resetting position:"+dataRow.position)
		
			this.position = dataRow.position
			$("queueItemPosition"+this.id).innerHTML = this.position
			
			$("queueItem"+this.id).className = this.divClass();
		}
		
		if(this.position < 2) {
			$("queueItemUp"+this.id).style.display = "none";
			$("queueItemDown"+this.id).style.display = "none";
		}
		
		// Schreibe Score
/*		if (this.score != dataRow.score) {
			this.score = dataRow.score;
			if (this.score != null) $("itemScore"+this.id).innerHTML = this.score;
		}
*/
		// Schreibe neue Zeit bis Sendestart ins Element
		if (this.time_to_play != dataRow.time_to_play) {
			this.time_to_play = dataRow.time_to_play;
			if (this.time_to_play != null) $("itemDuration"+this.id).innerHTML = __Yur.tool.format_time_period(this.time_to_play);
		}
		
		// Schreibe neue Tags ins Element
		if (this.movie_.tags_as_string != dataRow.movie_.tags_as_string) {
			var tags = this.movie_.tags_as_string = dataRow.movie_.tags_as_string;
			if (tags == "") tags = "&nbsp;";
			$("itemTags"+this.id).innerHTML = tags;
		}

		// Update das Voting
		if (dataRow.movie_.voting.count > this.voting.data.count) {
			this.voting.data = dataRow.movie_.voting;
			this.voting.update();
		}
	},
	
	divClass:	function () {
		
		var pos = new Number(this.position);
		var c = "movieDetails ";
		
		if(pos % 2) {
			return c + " hell"
		} else {
			return c + " dunkel"
		}
		
	},
	
	top:		function () {
		var pos = this.positionInList;
		pos     = pos * this.myheight() + this.options.space_top;
		return pos
	},
	
	preview:	function () {
/*		// OUT OF ORDER -- Siehe: Yur.TV.MoviePreview		
		var result = Jemplate.process("movie_preview.js.html", {
			model: this
		})
		
		$("itemThumb"+this.id).style.display = "none"
		var pre = $("itemPreview"+this.id);
		
		pre.innerHTML     = result;
		pre.style.display = "block"
*/
	},
	
	editTag:	function () {
		if (this.tag == null) this.tag = new Yur.TV.Tag(this.movie, this.id);
		this.tag.show();
		this.tag.focus();
	},
	
	divName:	function () {
		return "queueItem" + this.id;
	},
	
	div:		function () {
		return this.myDiv
	},
	
	container:	function () {
		return $("QueueItemList");
	},
	
	// DOM operations
	
	remove:	function () {
		this.container().removeChild( this.div() )
		if (this.tag) {
			delete(this.tag);
		}
		if (this.voting) {
//			this.voting.remove();
			delete(this.voting);
		}
	},
	
	insert:	function () {
		if (this.voting == null) {
			this.voting = new Yur.TV.Voting(this.id, this.movie, this.movie_.voting);
		}

		var div       = document.createElement("div");
		div.innerHTML = this.draw();
		div.className = 'movieDetailsContainer';
		
		this.myDiv    = div
		
		var style     = div.style;
		
		style.top      = "" + this.top() + "px";
		
		this.container().appendChild( div );
	},
	
	myheight: function () {
		var height = 74;
		if (this.queue == this.options.musikchartsqueue) {
			height = 95;	
			this.options.musikcharts = 1;	
		}
		return height;
	}
	
}

Yur.inherit(Yur.BO, Yur.BO.QueueItem)


// ##########################
// File: /storage/www/yur/www/lib/Yur/BO/TransitionAirtime.js
// ##########################
Yur_setUpNamespace(["Yur", "BO"])


Yur.BO.TransitionAirtime = function() {
}


Yur.BO.TransitionAirtime.prototype = {
	
	template:	function () {
		return "current_transition.js.html"
	},
	
	update:     function (dataRow) {
	
		
		
	},
	
	divName:	function () { // there is only one!!!!!
		return "cur"; 
	}
}

Yur.inherit(Yur.BO, Yur.BO.TransitionAirtime)


// ##########################
// File: /storage/www/yur/www/lib/Yur/BO/Vote.js
// ##########################
Yur_setUpNamespace(["Yur", "BO"]);




Yur.BO.Vote = function (movie, score) {

	this.movie = movie;
	this.score = score;
	
	this.action = 'vote';
}

Yur.BO.Vote.prototype = {

	onSuccess:		function (data) {},

	submitData:      function () {
		var me = this;
		var fetcher = new Yur.API(this.action, function (data) { me.saveResult(data) }, this.onFailure)
//		fetcher.debug = 1;
		fetcher.post({
			movie:      this.movie,
			score:      this.score,
			playlist_id: __Yur.playlist_id
		});
	},

	saveResult:		function (data) {
		this.onSuccess(data);
	}
	
}

Yur.inherit(Yur.BO, Yur.BO.Vote)




// ##########################
// File: /storage/www/yur/www/lib/Yur/BO/Vote/GongShow.js
// ##########################
Yur_setUpNamespace(["Yur", "BO"]);




Yur.BO.Vote.GongShow = function (movie, score) {

	this.movie = movie;
	this.score = score;
	
	this.action = 'vote/gongshow';
}


Yur.inherit(Yur.BO.Vote, Yur.BO.Vote.GongShow)


// ##########################
// File: /storage/www/yur/www/lib/Yur/BO/Vote/GongShowResult.js
// ##########################
Yur_setUpNamespace(["Yur", "BO"]);


Yur.BO.Vote.GongShowResult = function (movie) {

	this.movie = movie;
	
	this.action = 'vote/gongshow_result';
}

Yur.BO.Vote.GongShowResult.prototype = {

	onSuccess:		function (data) {},

	submitData:      function () {
		var me = this;
		var fetcher = new Yur.API(this.action, function (data) { me.saveResult(data) }, this.onFailure)
//		fetcher.debug = 1;
		fetcher.post({
			movie:      this.movie,
			playlist_id: __Yur.playlist_id
		});
	},

	saveResult:		function (data) {
		this.onSuccess(data);
	}
}

Yur.inherit(Yur.BO, Yur.BO.Vote.GongShowResult)
// ##########################
// File: /storage/www/yur/www/lib/Yur/Chat.js
// ##########################

// ##########################
// File: /storage/www/yur/www/lib/Yur/DivScroll.js
// ##########################
Yur_setUpNamespace(["Yur"])

var isOpera = (document.opera != null);
var isIE = (!isOpera && document.all)

Yur.DivScroll = function (id) {
	this.div_id   = id;
	this.xBar_ids = new Array(),
	this.yBar_ids = new Array(),
	this.opt = {
		xBar:		null,
		yBar:		null,
		x_mul:		0.5,
		y_mul:		0.5,
		schwelle: 	150,
		delay:		40,
		offsetTop:	null,
		offsetLeft: null,
		div:		null
	}
	this.scroll = {
		running:	false
	};
}

Yur.DivScroll.prototype = {
	init:				function (x, y) {
		this.div = document.getElementById(this.div_id);
		
		this.opt.xBar = new Array();
		for (var i = 0; i < this.xBar_ids.length; i++) { this.opt.xBar.push(document.getElementById(this.xBar_ids[i])) }
		this.opt.yBar = new Array();
		for (var i = 0; i < this.yBar_ids.length; i++) { this.opt.yBar.push(document.getElementById(this.yBar_ids[i])) }
		
		if (x != null) this._setX(x);
		if (y != null) this._setY(y);
	},
	
	xBarAdd:		function (id) {
		this.xBar_ids.push(id);
	},

	yBarAdd:		function (id) {
		this.yBar_ids.push(id);
	},
	
	offsetTop:			function () {
		if (this.opt.offsetTop == null) this.opt.offsetTop = this._ofT(this.div);
		return this.opt.offsetTop;
	},

	offsetLeft:			function () {
		if (this.opt.offsetLeft == null) this.opt.offsetLeft = this._ofL(this.div);
		return this.opt.offsetLeft;
	},

	_ofT:				function (o) {
		if (!o.offsetParent) return o.offsetTop;
		return o.offsetTop + this._ofT(o.offsetParent);
	},

	_ofL:				function (o) {
		if (!o.offsetParent) return o.offsetLeft;
		return o.offsetLeft + this._ofL(o.offsetParent);
	},

	mouseOut:			function (event) {
		if (!this.div) return;
		if (!event) event = window.event;
		var t = event.relatedTarget || event.toElement;
		if (!t) return;
		do {
			if (t == this.div) return;
			t = t.parentElement || t.offsetParent;
		} while (t);

		this.scroll.x = null;
		this.scroll.y = null;
		this.updateScrollRunner();
	},

	mouseMoving:		function (event) {
		if (!this.div) return;
		if(event) {
			if( typeof( event.pageX ) == 'number' ) {
				px = event.pageX;
				py = event.pageY;
			} else {
				px = event.clientX;
				py = event.clientY;
			}
		} else {
			event = window.event;
			px = event.clientX;
			py = event.clientY;
			if(document.documentElement
	        	&& (document.documentElement.scrollTop
	            || document.documentElement.scrollLeft)) {
				px += document.documentElement.scrollLeft;
				py += document.documentElement.scrollTop;
			} else if(document.body
					&& (document.body.scrollTop
					|| document.body.scrollLeft)) {
						px += document.body.scrollLeft;
						py += document.body.scrollTop;
			} else return;
		}

		px -= this.offsetLeft();
		py -= this.offsetTop();

		if (px <= this.opt.schwelle) {
			this.scroll.x = {
				direction : 'links',
				power : Math.round((this.opt.schwelle - px) + 1) * -1
			};
		} else if (px >= (this.div.clientWidth - this.opt.schwelle)) {
			this.scroll.x = {
				direction : 'rechts',
				power : Math.round((px - (this.div.clientWidth - this.opt.schwelle)) + 1)
			};
		} else {
			this.scroll.x = null;
		}
		if (py <= this.opt.schwelle) {
			this.scroll.y = {
				direction : 'hoch',
				power : Math.round((this.opt.schwelle - py) + 1) * -1
			};
		} else if (py >= (this.div.clientHeight - this.opt.schwelle)) {
			this.scroll.y = {
				direction : 'runter',
				power : Math.round((py - (this.div.clientHeight - this.opt.schwelle)) + 1)
			};
		} else {
			this.scroll.y = null;
		}
	
		this.updateScrollRunner();
	},

	updateScrollRunner:			function () {
		if (this.scroll.x || this.scroll.y) {
			if (!this.scroll.running) {
				var me = this;
				this.scroll.runnerID = setInterval(function () { me.doScrolling() }, this.opt.delay);
			}
			this.scroll.running = true
		} else this.scroll.running = false;
		
	},

	doScrolling:				function () {
		if (this.scroll.running) {
			var i;
			if (this.scroll.x) {
				this.div.scrollLeft += Math.round(this.scroll.x.power * this.opt.x_mul);
				for(i = 0; i < this.opt.xBar.length; i++) {
					this.opt.xBar[i].scrollLeft = this.div.scrollLeft;
				}
			}
			if (this.scroll.y) {
				this.div.scrollTop += Math.round(this.scroll.y.power * this.opt.y_mul);
				for(i = 0; i < this.opt.yBar.length; i++) {
					this.opt.yBar[i].scrollTop = this.div.scrollTop;
				}
			}
			
		} else if (this.scroll.runnerID) {
			clearInterval(this.scroll.runnerID);
			delete(this.scroll.runnerID);
		}
	},
	
	_setX:						function (x) {
		this.div.scrollLeft = x;
		for(i = 0; i < this.opt.xBar.length; i++) {
			this.opt.xBar[i].scrollLeft = this.div.scrollLeft;
		}
	},
	
	_setY:						function (y) {
		this.div.scrollTop = y;
		for(i = 0; i < this.opt.yBar.length; i++) {
			this.opt.yBar[i].scrollTop = this.div.scrollTop;
		}
	}
};
// ##########################
// File: /storage/www/yur/www/lib/Yur/Error.js
// ##########################



Yur.Error = function(aString,className) {
	
	this.string = aString
	this.className = className
	
}

Yur.Error.prototype.isa = function (className) {
	
	if(this.className != null && this.className.indexOf(className) != -1) {
		return true
	}
	
	return false
	
}

Yur.Error.prototype.asString = function () {
	if(this.className != null && this.className != "") {
		return this.className
	} else {
		return this.string;
	}
}

Yur.Error.prototype.defaultHandle = function () {
	
	return false
	
}
// ##########################
// File: /storage/www/yur/www/lib/Yur/Event.js
// ##########################
Yur_setUpNamespace(["Yur"]);


Yur.Event = function (e) {
	this.eventModel = e || window.event;
	if (!this.eventModel) throw "Konnte kein Event-Object finden!";
}

Yur.Event.prototype = {
	
	// Das Event wird nicht mehr weiter gereicht.
	stopPropagation:     function () {
		this.eventModel.cancelBubble = true;
		if (this.eventModel.stopPropagation) this.eventModel.stopPropagation();
	},
	
	/*
		relatedTarget
	    Beim mouseover das Element, das die Maus verlŠsst, wenn sie das Ereignis-auslšsende Element betritt,
	    beim mouseout-Ereignis das Element, das die Maus betritt, wenn sie das Ereignis-auslšsende Element verlŠsst.
	*/	
	toElement:           function () {
		return this.eventModel.relatedTarget || this.eventModel.toElement;
	}
}

// ##########################
// File: /storage/www/yur/www/lib/Yur/List.js
// ##########################
Yur_setUpNamespace(["Yur"])

Yur.List = function () {

	this.nodes = null;
}

Yur.List.prototype = {
	insert:  function (value) {
		var node = new Yur.List.Node(value);
		if (this.nodes == null) {
			this.nodes = node;
		} else {
			this.nodes = this.nodes.insert(node);
		}
	},
	
	remove:  function (value) {
		if (this.nodes == null) return;
		var node = new Yur.List.Node(value);
		this.nodes = this.nodes.remove(node);
	},
	
	length:  function () {
		if (this.nodes == null) return 0;
		return this.nodes.count();
	},
	
	isEmpty:  function () {
		if (this.nodes == null) return true;
		return false;
	},
	
	isIn:     function (value) {
		if (this.nodes == null) return false;
		return this.nodes.isIn(value);
	}
}


// Also Firefox bricht bei ca. 1000 Recursionen ab. :(
Yur.List.Node = function (value) {
	this.value = value;
	this.next = null;
}

Yur.List.Node.prototype = {	
	insert:   function (obj) {
		if (obj.value != this.value) {
			if (this.next == null) {
				this.next = obj;
			} else {
				this.next = this.next.insert(obj);
			}
		}
		return this;
	},

	remove:   function (obj) {
		if (obj.value == this.value) {
			return this.next;
		}
		if (this.next != null) this.next = this.next.remove(obj);
		return this;
	},
	
	count:   function () {
		if (this.next == null) return 1;
		return 1 + this.next.count();
	},
	
	isIn:    function (value) {
		if (this.value == value) return true;
		if (this.next != null) return this.next.isIn(value);
		return false;
	}
}



// ##########################
// File: /storage/www/yur/www/lib/Yur/Paras.js
// ##########################
// Generated: $now from config/*.ini (Yur::Paras)
Yur_setUpNamespace(["Yur"]);

Yur.Paras = {
  "Chart_Ranking_Default_Timing" : 1,
  "Email_Init_SendForm_Template" : "email/sendform.t.txt",
  "Error_Register__Untaint.Invalid.Format.Name__String" : "Das ist kein g&uuml;ltiger Name.",
  "Email_Init_ReportSpam_Kommentar_Template" : "email/report_spam_kommentar.t.txt",
  "Cast_Queue_Fillup_Threshold" : 1,
  "Template_Mail_Confirmation" : "",
  "Person_Ranking_By_OnAirZeit" : 4,
  "AktienPoints_Default_MaxSeconds_Per_Step_For_Counting" : 15,
  "Movie_Grade_Default" : 1,
  "Email_Init_SendForm_Subject" : "Frage",
  "Download_Status_Started" : 1,
  "Movie_Status_Deleted" : 140,
  "Person_Status_Aktiv" : 1,
  "Upload_Status_Started" : 1,
  "Person_Movies_Pagination_Entries_Per_Page" : 20,
  "LoginUsername" : "user_id",
  "URL_YurTV" : "http://www.yur.tv",
  "Chart_Ranking_Timing_2_Week_Before" : 3,
  "Yur_QueueItem_Veraltet_Sekunden" : 604800,
  "Movie_Upload_Type_Blip" : "blip",
  "AktienPoints_Default_MaxSeconds_For_Counting" : 360,
  "Cast_Queue_Status_Queued" : 1,
  "AktienPoints_Default_Wiederholung_Stepping_Liste" : [
    1,
    5,
    10
  ],
  "AktienPoints_Punkte_Pro_Aktie" : 200,
  "Person_Status_Deleted" : 140,
  "Person_Status_2_Grenze" : "50;",
  "Director_FillWithBestOf_number_of_best_of_clips" : 6,
  "Person_Ranking_Pagination_Entries_Per_Page" : 20,
  "Movie_Upload_Type_HTTP" : "http",
  "Chart_Ranking_Timing_ThisWeek" : 1,
  "Movie_Status_Reason_User_Complain" : 152,
  "Template_Register_Step1_frame" : "register_frame.t.html",
  "Error__Untaint.Invalid.Format.Date__String" : "Das Feld <strong>$(feldname)</strong> enth&auml;lt kein g&uuml;ltiges Datum.<br>Das Format sollte sein: TT.MM.JJJJ",
  "Movie_Voting_Delay_Seconds" : 1,
  "Yur_SessionActivity_Timeout_Sekunden" : 360,
  "Template_Movie_Download" : "howto/movie_download.t.html",
  "MyTV_Pagination_Steps_per_Page" : 5,
  "Yur_Default_Random_Password_Length_Integer" : 8,
  "Admin_Anzahl_Seiten_in_Navi" : 6,
  "Email_Default_Encoding" : "Base64",
  "Email_Init_ReportSpam_Guestbook_Template" : "email/report_spam_guestbook.t.txt",
  "Email_Init_ReportSpam_Kommentar_Subject" : "YUR.tv - Report Spam Kommentar",
  "Share_Status_Open" : 1,
  "Movie_Status_Reason_User_File_Exists" : 154,
  "URL_Reset_Passwd" : "http://www.yur.tv/rpw",
  "Guestbook_Status_Active" : 1,
  "Kommentar_Status_Active" : 1,
  "Vote_GongShow_Bar_Size_Pixel" : 20,
  "Email_Default_Notifications" : "info@yur.tv",
  "Error__Untaint.AlreadyInUse.Email__String" : "Ein Benutzer mit dieser E-Mail ist bereits in unserem System vorhanden.",
  "Share_Rank_New" : 1,
  "Select_Status_Mode_normal" : 2,
  "Email_ReportSpam_Adresse" : "frahm@schaffhausen.de",
  "Person_Ranking_Timing_ThisYear" : 1,
  "Email_Reset_Password_Subject" : "Passwort wurde resetet",
  "Email_Init_Reset_Password_Template" : "email/init_reset_passwd.t.txt",
  "Template_Register_Step3" : "register.t.html",
  "Error_Register__Untaint.Invalid.Format.PLZ__String" : "Das Feld <strong>$(feldname)</strong> enth&auml;lt keine g&uuml;ltige Postleitzahl.",
  "Formular_Feldname__Register.anrede" : "Geschlecht",
  "Formular_Feldname__Profile.passwd" : "Akt. Passwort",
  "Error_Register__Untaint.Invalid.Format.Date__String" : "Das Feld <strong>$(feldname)</strong> enth&auml;lt kein g&uuml;ltiges Datum.<br>Das Format sollte sein: TT.MM.JJJJ",
  "Email_Inappropriate_Email_Template" : "email/inappropriate.t.txt",
  "Email_NewShareOffer_Subject" : "Deine neue Aktie der YUR.tv AG",
  "URL_Confirm_Email" : "http://www.yur.tv/cem",
  "Formular_Feldname__Profile.anrede" : "Geschlecht",
  "Formular_Feldname__Profile.image" : "Portr&auml;t",
  "Movie_Upload_Type_MMS" : "mms",
  "Person_Ranking_Pagination_Max_Steps" : 4,
  "Person_Ranking_Timing_ThisWeek" : 3,
  "pdf_Zertifikat_Vorlage" : "/storage/www/yur/pdf/zertifikat.pdf",
  "Person_Ranking_ThreeMonth_Seconds" : 7776000,
  "Formular_Feldname__Movie.description" : "Beschreibung",
  "Upload_Status_Failed" : 3,
  "GongShow_MimimumVoteStabilitySeconds" : 8,
  "Person_Ranking_Timing_Overall" : 0,
  "Formular_Feldname__email" : "E-Mail",
  "Yur_Session_Veraltet_Sekunden" : 604800,
  "Email_Share_Subject" : "Kontakt - Aktion&auml;r",
  "MMS_Message_Prefix_Liste" : [
    "Yur",
    "Test"
  ],
  "LoggedInSessionIDName" : "yur_logged_in_session_id",
  "Movie_Status_DeactivateByUser" : 20,
  "Email_Share_Template" : "email/share_kontakt.t.txt",
  "Movie_Default_Queue_ID" : 1,
  "Person_Ranking_Pagination_First_Site_Entries" : 10,
  "Microsite_Status_Aktiv" : 1,
  "Person_Ranking_By_Platz" : 1,
  "Error_Register__Untaint.Invalid.Format.PLZ.FiveNumbers__String" : "Die Postleitzahl im Feld <strong>$(feldname)</strong> muss genau 5 Stellen haben.",
  "Person_Land_Oesterreich" : 2,
  "Adver_Min_Display_Seconds" : 60,
  "Email_Default_Type" : "text/plain",
  "Email_Init_Reset_Password_Subject" : "Passwort reseten",
  "Cast_Airtime_Status_Never_Played" : 150,
  "GongShow_Voting_Delay_Seconds" : 1,
  "System_Max_Visitors" : 1500,
  "Yur_SessionActivity_Veraltet_Sekunden" : 604800,
  "Formular_Feldname__password" : "Passwort",
  "Inappropriate_Noisy_Delay_Sekunden" : 3600,
  "AktienPoints_Default_MinSeconds_Per_Step_For_Counting" : 6,
  "Error_Register__Untaint.Invalid.Format.Alias__String" : "Dies ist kein g&uuml;ltiger Benutzername. Ein Benutzername sollte min. 3 und max. 15 Zeichen haben. Umlaute oder Sonderzeichen sind nicht erlaubt.",
  "Confirmation_Handy_PinLength_Integer" : 6,
  "GongShow_Min_Count_Votings" : 10,
  "Formular_Feldname__Register.image" : "Portr&auml;t",
  "Template_Profile" : "mytv/profile.t.html",
  "Person_Movies_Pagination_Max_Steps" : 5,
  "Person_Ranking_By_Punkte" : 2,
  "Email_Init_ReportSpam_Guestbook_Subject" : "YUR.tv - Report Spam Guestbook",
  "Formular_Feldname__plz" : "PLZ",
  "Queue_Pagination_Steps_Per_Page_Integer" : 5,
  "Error_Register__Untaint.Invalid.Format.Password__String" : "Das Feld <strong>$(feldname)</strong> enth&auml;lt kein g&uuml;ltiges Passwort. Ein Passwort sollte min. 6 Zeichen haben.",
  "Person_Ranking_Timing_Yesterday" : 4,
  "Person_Status_2_Text" : "Aktion&auml;r",
  "Microsite_Status_Inaktiv" : 0,
  "Share_Rank_Declined" : 2,
  "Person_Ranking_Timing_Liste" : [
    0,
    1,
    2,
    3,
    4,
    5,
    6
  ],
  "Email_SMS_Service_Domain" : "sms.basis-hh.de",
  "MyTV_Movies_per_Page" : 30,
  "Person_Ranking_Timing_SevenDays" : 6,
  "Email_Share_To_Adresse" : "bjoern@yur.tv",
  "Person_Ranking_OneDay_Seconds" : 86400,
  "Cast_Airtime_Status_Queued_For_Playing" : 1,
  "Podcast_Update_Period_Minutes" : 30,
  "Template_Register_Step1" : "register.t.html",
  "Vote_GongShow_Bar_Size_Pixel_fullscreen" : 102,
  "Download_Status_Failed" : 3,
  "Kommentar_Status_Inactive" : 10,
  "Guestbook_Status_Inactive" : 10,
  "Email_Reset_Password_Template" : "email/reset_passwd.t.txt",
  "Yur_LastVoteActivity_Timeout_Sekunden" : 3600,
  "Error__Untaint.Invalid.Pin__String" : "Die Kombination im Feld <strong>$(feldname)</strong> stimmt nicht.",
  "AktienPoints_Default_MinSeconds_Befor_Counting" : 15,
  "Movie_Status_Reason_User_Self" : 153,
  "Director_FillWithBestOf_best_of_age_seconds" : 7200,
  "Cast_Airtime_Status_Played" : 130,
  "Error__Untaint.Invalid.Format.HTTPUrl__String" : "Die Web-Adresse ist nicht OK",
  "Movie_Status_SystemMovie" : 10,
  "Chart_Ranking_Timing_4_Week_Before" : 5,
  "Cast_Airtime_Cancel_Negative_Vote" : 2,
  "Person_Land_2" : "&Ouml;sterreich",
  "System_Robot_UserAgent" : "lwp-request/2.07",
  "Person_Land_Schweiz" : 3,
  "Email_Default_SMTP" : "localhost",
  "Director_FillWithBestOf_best_of_length" : 40,
  "Formular_Feldname__Profile.geburtstag" : "Geburtsdatum",
  "Admin_Anzahl_Movies_pro_Seite" : 10,
  "Email_Verstoss_To_Adresse" : "info@yur.tv",
  "Template_Movie_Upload" : "howto/upload.t.html",
  "Email_Confirmation_Email_Subject" : "Best&auml;tigung Deiner E-Mail Adresse bei YUR.tv",
  "GongShow_MimimumPlayTimeSeconds" : 14,
  "Person_Land_Deutschland" : 1,
  "Debug_Mode" : 0,
  "Error_Profile__Untaint.UndefinedValue.ActivePassword__String" : "Um die &Auml;nderungen speichern zu k&ouml;nnen, wird das aktuelle Passwort ben&ouml;tigt.",
  "Formular_Feldname__Register.geburtstag" : "Geburtsdatum",
  "Share_Status_Declined" : 3,
  "Error__Untaint.AlreadyInUse.Handynumber__String" : "Ein Benutzer mit dieser Handynumber ist bereits in unserem System vorhanden.",
  "Movie_Status_Inappropriate" : 150,
  "Cast_Queue_Status_Airtime" : 2,
  "Transcode_Priority_Normal" : 1,
  "Movie_Status_Reason_Illegaler_Content" : 150,
  "Yur_LogTabel_Veraltet_Sekunden" : 2592000,
  "Error__Untaint.Invalid.PasswordRepeat__String" : "Die Wiederholung stimmt nicht mit dem Passwort &uuml;berein.",
  "Download_Status_Done" : 2,
  "Formular_Feldname__strasse" : "Stra&szlig;e",
  "Queue_Ausstrahlung_wochenende" : 9,
  "Share_Status_Accepted" : 2,
  "Email_Init_TellAFriend_Template" : "email/tell_a_friend.t.txt",
  "Movie_Status_Active" : 1,
  "Email_Inappropriate_Email_Subject" : "Ein Movie wurde als Unangemessen geflagt",
  "Cast_Queue_Standard" : 1,
  "Select_Status_Mode_archiv" : 1,
  "Queue_Movies_Per_Page_Integer" : 10,
  "Error__Untaint.Invalid.Format.Name__String" : "Das ist kein g&uuml;ltiger Name. Bitte gib deinen korrekten Vor- und Nachnamen an.",
  "Email_Init_TellAFriend_Subject" : "Tell A Friend",
  "Error__Untaint.Invalid.Format.Password__String" : "Das Feld <strong>$(feldname)</strong> enth&auml;lt kein g&uuml;ltiges Passwort. Ein Passwort sollte min. 8 Zeichen haben.",
  "Email_Verstoss_Absender_Adresse" : "info@yur.tv",
  "Person_Ranking_By_LetzterBeitrag" : 5,
  "Email_Channel_Abo_Subject" : "Abo",
  "Streaming_Host" : "streaming.yur.tv",
  "Formular_Feldname__Profile.zusatz" : "Adress-Zusatz",
  "Email_Init_Offence_Template" : "email/offence.t.txt",
  "Error__Untaint.Invalid.Format.Text.TooLong__String" : "Der Text im Feld <strong>$(feldname)</strong> ist zu lang.",
  "Confirmation_Type_Email_String" : "email",
  "Person_Ranking_By_Beitraege" : 3,
  "Email_Confirmation_Handy_Subject" : "Best&auml;tigung Deiner Handy Nummer bei YUR.tv",
  "Chart_Ranking_Timing_Overall" : 0,
  "Channel_Abo_Status_Delete" : 20,
  "Formular_Feldname__alias" : "Benutzername",
  "Channel_Abo_Status_Active" : 1,
  "Movie_Upload_Type_Flash" : "flash",
  "pdf_Zertifikat_Name" : "zertifikat_",
  "Error__Untaint__String" : "There is no definition for this kind of untainted error $(class).",
  "Formular_Feldname__Movie.title" : "Titel",
  "Error__Untaint.Invalid.Format.UnsignedInteger__String" : "In <strong>$(feldname)</strong> wird eine positive Zahl erwartet.",
  "Cast_Airtime_Cancel_Queue_End" : 3,
  "Error_Register__Untaint.AlreadyInUse.Handynumber__String" : "Ein Benutzer mit dieser Handynumber ist bereits in unserem System vorhanden.",
  "Template_Register_Step2" : "register.t.html",
  "Error__Untaint.Invalid.Format.PLZ__String" : "Das Feld <strong>$(feldname)</strong> enth&auml;lt keine g&uuml;ltige Postleitzahl.",
  "AktienPoints_Default_Seconds_Befor_Linear_Counting" : 180,
  "Vote_Queue_Bar_Size_Pixel" : 95,
  "Vote_Max_Score" : 2,
  "Person_Ranking_Default_Timing" : 6,
  "Email_Default_From" : "Yur.tv <noreply@yur.tv>",
  "Queue_Ausstrahlung_werktags" : 8,
  "Email_Confirmation_Handy_Template" : "email/confirmation_handy.t.txt",
  "Cast_Queue_No_Shuffle_Seconds_Before_Start" : 3600,
  "Upload_Status_Prepared" : 0,
  "Error_Register__Untaint.Invalid.Format.PLZ.FourNumbers__String" : "Die Postleitzahl im Feld <strong>$(feldname)</strong> muss genau 4 Stellen haben.",
  "Person_Ranking_Timing_ThisMonth" : 2,
  "Cast_Airtime_Cancel_Program_Failure" : 3,
  "Person_Ranking_Timing_Today" : 5,
  "Chart_Ranking_Timing_Liste" : [
    0,
    5,
    4,
    3,
    2,
    1
  ],
  "Transcode_Priority_Low" : 10,
  "AktienPoints_Doppelte_Punkte_Aktion" : 1,
  "Movie_Status_Reason_Copyright_Violation" : 151,
  "Person_Ranking_By_Position" : 8,
  "Error__Untaint.UndefinedValue__String" : "<strong>$(feldname)</strong> muss angegeben werden.",
  "Person_Land_3" : "Schweiz",
  "ExpireTime_Session_Seconds" : 900,
  "Error__Untaint.Invalid.Format.Handynumber__String" : "Das Feld <strong>$(feldname)</strong> enth&auml;lt keine g&uuml;ltige Handynummer.",
  "Person_Status_Gesperrt" : 100,
  "AktienPoints_Default_Wiederholung_Factor_Liste" : [
    0.5,
    0.25,
    0.1
  ],
  "HTTP_Host" : "www.yur.tv",
  "Person_Ranking_OneWeek_Seconds" : 604800,
  "Streaming_Offset_Seconds" : 1,
  "AktienPoints_Default_ActiveViewer_Stepping_Liste" : [
    2,
    50
  ],
  "Chart_Ranking_Timing_1_Week_Before" : 2,
  "Default_Ranking_Timing" : 6,
  "Email_NewShareOffer_Template" : "email/aktie_verschenken.t.txt",
  "Person_Land_1" : "Deutschland",
  "Select_Status_Mode_all" : 3,
  "Movie_Upload_Type_Download" : "down",
  "Person_Status_1_Grenze" : "10;",
  "Error_Register__Untaint.AlreadyInUse.Alias__String" : "Dieser Benutzername ist leider schon vergeben.",
  "Share_Rank_Accepted" : 2,
  "Confirmation_Type_Handy_String" : "handy",
  "Email_Channel_Abo_Template" : "email/channel_abo.t.txt",
  "Download_Status_Prepared" : 0,
  "Error_Profile__Untaint.Invalid.ActivePassword__String" : "Das angegebene aktuelle Passwort ist falsch.",
  "WebLink_Banner_Queue" : "/pics/banner/queue",
  "Chart_Ranking_Timing_3_Week_Before" : 4,
  "Cast_Airtime_Status_Cancelled" : 140,
  "Cast_Minimum_Queue_Size" : 1,
  "Cast_Airtime_Status_Playing" : 2,
  "LoginPassword" : "login_passwd",
  "Person_Status_3_Text" : "Gro&szlig;aktion&auml;r",
  "Formular_Feldname__Register.zusatz" : "Adress-Zusatz",
  "Email_Confirmation_Email_Template" : "email/confirmation_email.t.txt",
  "ITC_Testsystem" : 0,
  "SessionIDName" : "yur_session_id",
  "Cast_Airtime_Cancel_Inappropriate" : 1,
  "ExpireTime_Session_Eingeloggt_Seconds" : 900,
  "Error_Register__Untaint.Invalid.PasswordRepeat__String" : "Die Wiederholung stimmt nicht mit dem Passwort &uuml;berein.",
  "Error__Untaint.Invalid.Format.Email__String" : "Das ist keine g&uuml;ltige E-Mail-Adresse.",
  "Person_Status_1_Text" : "Kleinaktion&auml;r",
  "Upload_Status_Done" : 2
};
// ##########################
// File: /storage/www/yur/www/lib/Yur/Player.js
// ##########################
Yur_setUpNamespace(["Yur"])

Yur.Player = function (elementIdPrefix) {
	
	playerObj    = $(elementIdPrefix+"Movie")
	
	this.element = playerObj;
}



Yur.Player.prototype = {
	
	secondaryPlayerPlaying: function () {
		this.secondary_playing = true;
		this.mute();
	},
	
	secondaryPlayerPaused: function () {
		if(this.secondary_playing) {
			this.unMute();
		}
		this.secondary_playing = false;
	},
	
	mute: function () {
		/*var ele = this.element;
		if(ele != null) {
			ele.SetMute(true)
		}*/
	},

	unMute: function () {
		/*var ele = this.element;
		if(ele != null) {
			ele.SetMute(false)
		}*/
	},

	getStatus:  function() {
		return 1
	},
	
	fullOffset: function () {
		return 0
	},

	offsetMeasured: function () {
		$LOG("Player Streaming Offset = " + this.offset)
	},
	
	measureStreamingOffset:  function (s) {
	},
	
	doFallback:				function () {
	}
}




// ##########################
// File: /storage/www/yur/www/lib/Yur/Player/FlashWriter.js
// ##########################
Yur_setUpNamespace(["Yur","Player"])

Yur.Player.FlashWriter = function () {
	this.type("flash");
	
	this.aspectRatio(4/3);
	
	this.stream_name("yurtv");
}


Yur.Player.FlashWriter.prototype = {
	write:	function (id) {
		var so = new SWFObject("/flash/live_stream_version9.swf", "playerId", this.width(), this.height(), 8);
 		so.addVariable("url",         "yurtv.fc.llnwd.net/live/a1920");
  		so.addVariable("stream_name", this.stream_name());
   		so.addVariable("yurMakeAccessors", "");
   		so.addVariable("toJSONString", "");
   		
   		so.addVariable("clickTag",    this.href());

   		so.addVariable("buffer_time", this.buffer_time());
   
   		so.addParam("allowfullscreen", "true");
   		so.addParam("allowscriptaccess", "true");
   		so.addParam("wmode", "opaque");
   		
   		var curVersion = so.installedVer.major;
   		
   		/*if(curVersion == 8) {
   			so.setAttribute("swf","/flash/live_stream_version8.swf")
   		}*/
   		
   		so.write(id);
	},
	
	shrinkToAspectRatio: function () {
		var height = this.height();
		var width  = this.width();
		var ratio  = this.aspectRatio();
		
		if(width/height > ratio) { // too wide
			width = height * ratio
		} else {
			height = width / ratio
		}

		if (width < 557) {
			width = 557;
			height = width / ratio
		}
		
		this.height(Math.round(height))
		this.width(Math.round(width))
	},
	
	setFullscreenDimensions: function () {
		this.height(__Yur.windowHeight() - 140);
		this.width(__Yur.windowWidth() - 300);
		
		this.shrinkToAspectRatio()
	}
	
};


Yur.Player.FlashWriter.prototype.yurMakeAccessors("width", "height", "type", "id", "aspectRatio", "buffer_time", "href", "stream_name");
// ##########################
// File: /storage/www/yur/www/lib/Yur/Player/Writer.js
// ##########################
Yur_setUpNamespace(["Yur","Player"])

Yur.Player.Writer = function (type) {
	this.type("quicktime");
	this.autoplay(true);
	this.showController(false);
	
	this.aspectRatio(4/3);
	
	this.minVersion = 7;
}



Yur.Player.Writer.prototype = {
	write:	function (id) {
		//alert("Installed: "+this.isQTInstalled())
		//alert("Version: "+this.getQTVersion())
		var html = this.draw();
		//alert(html)
		if(id != null) {
			$(id).innerHTML = html
		} else {
			document.writeln(this.draw())
		}
	},
	
	draw: function () {
	
		var quicktime_html = "";
	
		if(this.isIE() || this.isSafari()) {
			
			if(this.href() != null) {
				quicktime_html = QT_GenerateOBJECTText(this.src(), this.width(), this.height(), '',
			  		"autoplay", this.autoplay(),
			  		"enablejavascript", "true",
			  		"controller", this.showController(),
			  		"SCALE", "Aspect",
			  		"target", "_parent",
			  		"href", this.href(),
			  		"id", this.id());
			} else {
				quicktime_html = QT_GenerateOBJECTText(this.src(), this.width(), this.height(), '',
			  		"autoplay", this.autoplay(),
			  		"enablejavascript", "true",
			  		"controller", this.showController(),
			  		"SCALE", "Aspect",
			  		"id", this.id());
			}
		} else {
			quicktime_html = '<object type="video/quicktime" data="'+this.src()+'" id="playerEmbed" width="'+this.width()+'" height="'+this.height()+'" >\n'+
			'<param name="autoplay" value="'+this.autoplay()+'" />\n'+
			'<param name="controller" value="'+this.showController()+'" />\n'+
			'<param name="SCALE" value="Aspect" />\n'+
			(this.href() != null ? '<param name="href" value="'+this.href()+'" />\n<param name="target" value="_parent" />\n' : "") + 
			'</object>'
		}    
		
	
		var download_html = '<table width='+this.width()+' height='+this.height()+' border=0 bgcolor="#DEDEDE" colspan=10><tr><td align=center>Um Yur.TV zu schauen ben&ouml;tigst Du <a target="_blank" href="http://www.apple.com/de/quicktime/download/">Apple QuickTime ab Version 7, dass Du hier kostenlos herunterladen</a> kannst.</td></tr></table>';
	
		if(this.isIE()) {
			
			if(!this.isQTInstalled()) { // active x kŸmmert sich
				window.urchinTracker("/quicktime/no/activex");
				return quicktime_html
			} else {
				var version = this.getQTVersion();
				if(version >= this.minVersion) {
					window.urchinTracker("/quicktime/yes");
					return quicktime_html
				} else {
					window.urchinTracker("/quicktime/no");
					return download_html;
				}
			}
			
		} else {
			
			if(this.isLinux()) {
				return quicktime_html
			}
			
			var version = this.getQTVersion();
			if(!this.isQTInstalled() || version < this.minVersion) {
				window.urchinTracker("/quicktime/no");
				return download_html
			} else {
				window.urchinTracker("/quicktime/yes");
				return quicktime_html    
			}
		}
	},
	
	shrinkToAspectRatio: function () {
		var height = this.height();
		var width  = this.width();
		var ratio  = this.aspectRatio();
		
		if(width/height > ratio) { // too wide
			width = height * ratio
		} else {
			height = width / ratio
		}

		if (width < 557) {
			width = 557;
			height = width / ratio
		}
		
		this.height(Math.round(height))
		this.width(Math.round(width))
	},
	
	setFullscreenDimensions: function () {
		this.height(__Yur.windowHeight() - 140);
		this.width(__Yur.windowWidth() - 300);
		
		this.shrinkToAspectRatio()
	},
	
	// Taken from http://wdirect.apple.com/global/scripts/browserdetect.js
	isQTInstalled:			function() {

		var qtInstalled=false;

		if(navigator.plugins&&navigator.plugins.length){

			for(var i=0;i<navigator.plugins.length;i++){

				var plugin=navigator.plugins[i];

				if(plugin.name.indexOf("QuickTime")>-1){
					qtInstalled=true;
				}
			}
		} else {
			qtObj=false;
			execScript('on error resume next: qtObj = IsObject(CreateObject("QuickTimeCheckObject.QuickTimeCheck.1"))','VBScript');
			qtInstalled=qtObj;
		}

		return qtInstalled;
	},
	
	isIE:	function () {
		return document.all != null && navigator.userAgent.indexOf("Opera") == -1
	},
	
	isLinux:	function () {
		return navigator.userAgent.indexOf("Linux") == -1
	},
	
	isSafari:	function () {
		return navigator.userAgent.indexOf("AppleWebKit") != -1
	},

	getQTVersion:function() {

		var version="0";

		if(navigator.plugins&&navigator.plugins.length){
			for(var i=0;i<navigator.plugins.length;i++){

				var plugin=navigator.plugins[i];


				var match=plugin.name.match(/quicktime\D*([\.\d]*)/i);
				if(match&&match[1]){
					version=match[1];
				}
			}
		} else {
			ieQTVersion=null;

			execScript('on error resume next: ieQTVersion = (Hex(CreateObject("QuickTimeCheckObject.QuickTimeCheck.1").QuickTimeVersion)/1000000)','VBScript');

			if(ieQTVersion){

				version=(ieQTVersion+"").split(/\./)[0];
			}
		}

		return 0+version;
	}

}
Yur.Player.Writer.prototype.yurMakeAccessors("width", "height", "type", "id", "src", "autoplay", "aspectRatio", "showController", "href")



// ##########################
// File: /storage/www/yur/www/lib/Yur/QuicktimePlayer.js
// ##########################
Yur_setUpNamespace(["Yur"])

Yur.QuicktimePlayer = function (elementIdPrefix) {
	
	playerObj    = $(elementIdPrefix+"Movie")
	
	this.element = playerObj;
}



Yur.QuicktimePlayer.prototype = {
	
	secondaryPlayerPlaying: function () {
		this.secondary_playing = true;
		this.mute();
	},
	
	secondaryPlayerPaused: function () {
		if(this.secondary_playing) {
			this.unMute();
		}
		this.secondary_playing = false;
	},
	
	mute: function () {
		var ele = this.element;
		if(ele != null) {
			ele.SetMute(true)
		}
	},

	unMute: function () {
		var ele = this.element;
		if(ele != null) {
			ele.SetMute(false)
		}
	},

	getStatus:  function() {
		var player = this.element;


		
	
		if (player != null && typeof(player.GetPluginStatus) != "undefined") {  // test for null of GetPLuginStatus is error in ie 7
			var status = player.GetPluginStatus();

			if (status == "Complete" || status == "Completed" || status == "Playable") {
	
				var time = player.GetTime();
				var totalTime = player.GetDuration();
				var rate = player.GetRate();
	
				if (time >= totalTime)
					return "Played";
				else if (rate > 0)
					return "Playing";
				else if (rate == 0)
					return "Paused";
				else
					return status;
			}
			else
				return status;
		}
	
		return "Undefined";
	},
	
	fullOffset: function () {
		return this.base_offset //+ this.offset
	},

	offsetMeasured: function () {
		$LOG("Player Streaming Offset = " + this.offset)
	},
	
	measureStreamingOffset:  function (s) {
		var start = s;
		if(start == null) {
			start = new Date().getTime();
		}
		var status = this.getStatus();
		$LOG("Player-Status: "+status)
		if(status == "Playing" || status == "Playable") {
			this.offset = ( (new Date().getTime()) - start ) / 1000;
			this.offsetMeasured();
		} else {
			if (status != null && status.match(/10060|503|403|3285/)) {
				this.doFallback();
			}
			// recurse after some time
			var me = this;
			window.setTimeout(function() { me.measureStreamingOffset(start) }, 10000)
		}
		
	},
	
	doFallback:				function () {
		if (__Yur.QuicktimePlayer_writer) {
			if (this.http_fallback_list.length) {
				var url = this.http_fallback_list.shift();
				$LOG("Player: doing quicktime fallback to [" + url + "]");
				
				__Yur.QuicktimePlayer_writer.src(url);
				__Yur.QuicktimePlayer_writer.write("playerContainer");
			} else {
				$LOG("no more URL's for quicktime fallback");
			}
		} else {
			$LOG("no player_writer object for fallback");
		}
	}
}



// ##########################
// File: /storage/www/yur/www/lib/Yur/Spotlight.js
// ##########################
Yur_setUpNamespace(["Yur"]);


Yur.Spotlight = function () {
	
	// only spotlight on these pages. Else do nothing
	if(__Yur.sitename != "homepage" && __Yur.sitename != "userchannel") {
		return
	}
	
	this.divs      = ["trans1", "trans1_bottom", "trans2", "trans3"]
	
	this.last_move = new Date();
	
	this.mode      = "off";
	
	var me         = this;
	
	document.body.onmousemove = function () { 
		me.last_move = new Date() 

		
		if(me.isOn()) {
			me.turnOff();
		}
	}
	

	
	setInterval(function () {
		
		if(!me.isOn()) {
		
			var now = new Date();

			if(now.getTimeSeconds() - me.last_move.getTimeSeconds() > 3) {
				me.turnOn()
			}
		}
		
	}, 2000)


}

Yur.Spotlight.prototype = {

	isOn:		function () {
		return this.mode == "on"
	},

	turnOn:	function () {
		this.mode = "on"
		//alert("Spotlight on");
		this.turn("transparenz_on")
	},
	
	turnOff:	function () {
		this.mode      = "off";
		//alert("Spotlight off")
		this.turn("transparenz_off")
	},
	
	turn:		function(className) {
		for(var i = 0; i < this.divs.length; i++) {
			var o = $(this.divs[i]) 
			if(o != null) {
				switchClassTo(o,className);
			}
		}
	}
	
}

// ##########################
// File: /storage/www/yur/www/lib/Yur/Toolbox.js
// ##########################
Yur_setUpNamespace(["Yur"])


Yur.Toolbox = function() {

}

var Yur_Toolbox_Mod_Counter = 0;


Yur.Toolbox.prototype = {
	modulo:	function (mod, zero, nonzero) {
	
		if(Yur_Toolbox_Mod_Counter++ % mod == 0) {
			$LOG(zero)
			return zero
		} else {
			$LOG(nonzero)
			return nonzero
		}
	},
	
	pad2: function (n) {
		if(new Number(n) < 10) {
			return "0" + n
		}
		return n
	},
	
	round: function(num, anzahl_stellen) {
		
		var stellen = anzahl_stellen;
		if(stellen == null) {
			stellen = 0;
		}
		
		var n = num * (10 * stellen);
		
		n = Math.round(n);
		
		return n / (10 * stellen)
	},
	
	format_time_period: function (s) {
		
		var seconds = Math.round(new Number (s));
		
		if(seconds < 0) {
			seconds = 0;
		}
		
		var hours = 0;
		var mins  = 0;
		
		/*if(seconds > 60 * 60) {
			hours    = Math.floor(seconds / 3600);
			seconds = seconds - hours * 3600;
		}*/
		if(seconds > 60) {
			mins     = Math.floor(seconds / 60);
			seconds     = seconds - mins * 60
		}
		
		/*var string = "" + seconds + " Sek.";
		
		string = "" + mins + " Min. " + string
		
		if(hours > 0) {
			string = "" + hours + " Min. " + string
		}
		
		return string
		*/
		
		return "" + this.pad2(mins) + ":" + this.pad2(seconds) + " Min."
	},
	
	format_hours_time_period:	function (s) {
		var seconds = Math.round(new Number (s));
		
		if(seconds <= 0) {
			return "00:00:00 Stunden";
		}
		
		var hours = 0;
		var mins  = 0;
		
		if(seconds > (60 * 60)) {
			hours    = Math.floor(seconds / (60 * 60));
			seconds = seconds - (hours * (60 * 60));
		}
		if(seconds > 60) {
			mins     = Math.floor(seconds / 60);
			seconds     = seconds - (mins * 60);
		}
		
		var seconds_str = ''+seconds; 
		var min_str = ''+mins;
		var hours_str = ''+hours;
		
		if (seconds < 10) {
			seconds_str = '0'+seconds_str
		}
		if (mins < 10) {
			min_str = '0'+min_str
		}
		if (hours < 10) {
			hours_str = '0'+hours_str
		}
	
		
		var string = "";
			string = "" + seconds_str + " Stunden";
			string = "" + min_str + ":" + string
			string = "" + hours_str + ":" + string
				
		return string
	},
	
		format_advanced_time_period:	function (s) {
		var seconds = Math.round(new Number (s));
		
		if(seconds <= 0) {
			return "0s";
		}
		
		var hours = 0;
		var mins  = 0;
		
		if(seconds > (60 * 60)) {
			hours    = Math.floor(seconds / (60 * 60));
			seconds = seconds - (hours * (60 * 60));
		}
		if(seconds > 60) {
			mins     = Math.floor(seconds / 60);
			seconds     = seconds - (mins * 60);
		}
		
		var string = "";
		if (seconds) {
			string = "" + seconds + "s";
		}
		if (mins) {
			string = "" + mins + "m " + string
		}
		if(hours) {
			string = "" + hours + "h " + string
		}
		
		return string
	},
	
	
	format_durchschnitt:		function (d) {
		d = new String(this.round(d,2));
		if (d >= 0.0) d = "+" + d;
		if(d.indexOf('.') < 0) {
			d = new String(d + '.00');
		} else if (d.indexOf('.') == (d.length - 2)) {
			d = new String(d + '0');
		}
		return "" + d.charAt(0) + ' ' + d.substr(1, d.indexOf('.') - 1) + ',' + d.substr(d.indexOf('.') + 1, 2)
	},
	
	format_sql_to_german:		function (date) {
		return "" + date.substr(8,2)+ '.' + date.substr(5,2)+ '.' + date.substr(0,4);
	},
	
	format_sql_datetime_to_german_time:		function (date) {
		return "" + date.substr(11,5);
	},
	
	format_sql_datetime_to_german:		function (date) {
		return "" + date.substr(8,2)+ '.' + date.substr(5,2)+ '.' + date.substr(0,4) + " " + date.substr(11,5);
	},
	
	format_karma:				function (k) {
		if(k >= 0.0) k = "+" + k;
		k = new String(k);
		return "" + k.charAt(0) + ' ' + k.substr(1, k.length - 1);
	},
	
	format_ranking_pagination_steps:	function (step, entries_per_page, total_entries) {
		var first = ((step - 1) * entries_per_page) + 1;
		var last  = step * entries_per_page;
		if (last > total_entries) last = total_entries;
		return first + '-' + last;
	},
	
	format_ranking_pagination_steps_with_first:	function (step, entries_per_page, total_entries, first_site_entries) {
		var first = 1;
		if (step > 1) {
			first = (((step - 1) * entries_per_page) + 1) - entries_per_page + first_site_entries;
		}
		var last  = (step * entries_per_page) - entries_per_page + first_site_entries;
		if (last > total_entries) last = total_entries;
		return first + '-' + last;
	},
	
	format_wert_in_aktien:	function (wert) {
		return Math.round(wert * 100000) / 100000;
	}
}


// ##########################
// File: /storage/www/yur/www/lib/Yur/TV/Charts.js
// ##########################
Yur_setUpNamespace(["Yur", "TV"])


Yur.TV.Charts = function() {
	
	this.options = {
		debug_fetcher:	0,
		cache_interval_seconds: 600
	};
	
	this.page = 1;
	this.timing = 1;
	this.sorting = 1;
	
	this.data = null;
	
	this.template = "charts_list.js.html";
	this.template_first3 = "charts_first3.js.html";
	
	this.something_requested = 0;
}


Yur.TV.Charts.prototype = {

	init:			function () {
		if (this.something_requested) return;
		this.fetchCharts();
		if (this.timing && this.timing == 1) {
			$('rankingHeadlineButtonThreeMonth').className = 'cursor act';
		} else if (this.timing && this.timing == 2) {
			$('rankingHeadlineButtonOneWeek').className = 'cursor act';
		} else if (this.timing && this.timing == 3) {
			$('rankingHeadlineButtonOneDay').className = 'cursor act';
		} else {
			var btn = $('rankingHeadlineButtonAllTime')
			if(btn != null)
				btn.className = 'cursor act';
		}
	},

	fetchCharts:	function (alias) {
		
		__Yur.adver.click()
	
		this.something_requested = 1;
	 	var me = this;
		var fetcher = new Yur.API("charts", function (data) { me.dataReceived(data); })
		fetcher.cached = true;
		fetcher.setCacheIntervalSeconds(this.options.cache_interval_seconds)
		fetcher.debug = this.options.debug_fetcher;
		if (alias == null) alias = "";
		fetcher.get({
			page: this.page,
			timing: this.timing,
			sorting: this.sorting,
			search: alias
			
		});
		if (alias == "") $('ChartsList').innerHTML = __Yur.loadingHTML("loading_hell");
	},
	
	dataReceived:	function (data) {
		if (data.not_found) {
			alert("Dieser Benutzername existiert nicht.");
		} else {
			if (data.person && !data.page) {
				this.hideSearch();
				__Yur.personDetails.person.saveResult(data.person);
				__Yur.personDetails._open();
			} else {
				if (data.found) this.hideSearch();
				this.draw(data)
			}
		}
	},
	
	draw:			function (data) {
		this.data = data;

		$('ChartsList').innerHTML = "";
		
		var html = Jemplate.process(this.template, {
			model: data,
			tool: __Yur.tool
		});
				
		var html2 = Jemplate.process(this.template_first3, {
			model: data,
			tool: __Yur.tool
		});
		
		$('ChartsList').innerHTML = html;
		if (data.page == 1) {
			$('Gewinner').innerHTML = html2;
		}
		if (data.found) {
			var pos = -1;
			for (var i = 0; i < data.list.length && pos < 0; i++) {
				if (data.list[i].id == data.person) pos = i;
			}
			if (pos >= 0) {
				$('ChartsList').scrollTop = (pos * 20);
			}
		}
	},
	
	show:			function () {
		
		$('Charts').style.display = 'inline';
		__Yur.nav('Charts').activate(this.timing);
		this.init();

	},
	
	hide:			function () {
		$('Charts').style.display = 'none';
	},
	
	showSearch:		function () {
		__Yur.personDetails.hide();
		__Yur.operatorBlende.show();
		$("Search").style.display = "inline";
		this.searchFocus();
	},
	
	hideSearch:		function () {
		__Yur.operatorBlende.hide();
		$("Search").style.display = "none";
		return true;
	},
	
	searchFocus:		function () {
		try {
			$("searchForm").alias.focus();
			$("searchForm").alias.select();
		 } catch(e) { /* Der IE kann keinem Element den Focus geben, wenn es unsichtbar ist... */}
	},
	
	search_form:		function (f) {
		this.fetchCharts(f.alias.value);
	},
	
	changeSorting:		function (sorting) {
		this.sorting = sorting;
		this.fetchCharts();
	},
	
	changeTiming:	function (timing) {
		this.timing = timing;
		this.page = 1; /* Wenn das Timing geaendert wird, wird immer auf die erste Seite gesprungen (auch Wichtig fuer die Gewinner!!) */
		this.fetchCharts();
		if (this.timing >= 0) {
			__Yur.nav('Charts').activate(this.timing);
		}

	},
	
	getPage:		function (page) {
		this.page = page;
		this.fetchCharts();
	},
	
	getPageForm:		function (name) {
		page = $(name).value;
		var ZugelasseneZeichen = '0123456789';
		for (var Pos = 0; Pos < page.length; Pos++) {
    		if (ZugelasseneZeichen.indexOf(page.charAt(Pos)) == -1) {
      			alert(unescape("Bitte geben Sie eine g%FCltige Seitenzahl ein."));
	   			return false;
      		}
 		}
		this.page = page;
		this.fetchCharts();
	}
	
}
// ##########################
// File: /storage/www/yur/www/lib/Yur/TV/Friends.js
// ##########################
Yur_setUpNamespace(["Yur", "TV"])


Yur.TV.Friends = function() {
	
	this.options = {
		debug_fetcher:	0
	};
	this.template = "friends.js.html";
}


Yur.TV.Friends.prototype = {

	fetchFriends:	function (alias,page) {
	 	var me = this;
		var fetcher = new Yur.API("friends", function (data) { me.dataReceived(data); })
		fetcher.cached = false;
		fetcher.setCacheIntervalSeconds(0)
		fetcher.debug = this.options.debug_fetcher;
		if (!alias) return;
		fetcher.get({
			alias: alias,
			page: page			
		});
		
		// Ladesymbol!!!!
		//$('kommentar').innerHTML = __Yur.loadingHTML("loading_hell");
	},
	
	dataReceived:	function (data) {
		this.draw(data)
	},
	
	draw:			function (data) {
		this.data = data;
		if ((data.gesamt) && $('friends') && $('friends_box')) {
			
			$('friends_box').innerHTML = "";
		
			var html = Jemplate.process(this.template, {
				model: data,
				tool: __Yur.tool
			});
				
			$('friends_box').innerHTML = html;
			$('friends').style.display = '';
		}
	}	
	
}
// ##########################
// File: /storage/www/yur/www/lib/Yur/TV/GenerallyContent.js
// ##########################
Yur_setUpNamespace(["Yur", "TV"])


Yur.TV.GenerallyContent = function() {
	this.person_movies = new Yur.BO.Person.Movies();
	this.meinyurtv_movies = new Yur.BO.Person.MeinYURMovies();
	this.archiv = 0;
}


Yur.TV.GenerallyContent.prototype = {

	show:			function () {
		if (__Yur.sitename == 'homepage') {
			__Yur.ranking.hide();
			__Yur.queue.hide();
			__Yur.howTo.hide();
			//__Yur.myTV.hide();
			__Yur.nav('operator').reset();
		}
		if (__Yur.sitename != 'meinyurtv') {
			__Yur.moviePreview.hide();
			__Yur.personDetails.hide();
		}
		this.container().style.display = 'inline';
	},
	
	hide:			function () {
		this.container().style.display = 'none';
	},
	
	container:		function () {
		return $('GenerallyContent');
	},
	
	loadPersonMovies:	function (person_id,page) {
		this.container().innerHTML = "";
		this.show();
		this.person_movies.requestData(person_id,page);
	},
	
	loadMeinYURtvMovies:	function (person_id,page) {
		this.container().innerHTML = "";
		this.show();
		this.meinyurtv_movies.requestData(person_id,page,this.archiv);
	},
	
	getPageForm:		function (name,id) {
		page = $(name).value;
		var ZugelasseneZeichen = '0123456789';
		for (var Pos = 0; Pos < page.length; Pos++) {
    		if (ZugelasseneZeichen.indexOf(page.charAt(Pos)) == -1) {
      			alert(unescape("Bitte geben Sie eine g%FCltige Seitenzahl ein."));
	   			return false;
      		}
 		}
		this.loadMeinYURtvMovies(id,page);
	}
	
}
// ##########################
// File: /storage/www/yur/www/lib/Yur/TV/HowTo.js
// ##########################
Yur_setUpNamespace(["Yur", "TV"])

Yur.TV.HowTo = function() {}

Yur.TV.HowTo.prototype = {
	show:		function () {
		if (__Yur.session.logged_in) {
			this._show();
		} else {
			var me = this;
			__Yur.session.showLogin(function () { me._show() });
		}
	},
	
	_show:		function () {
		if (!__Yur.session.hideLogin()) return;
		 //$('HowToIframe').src = '/howto/';
		//__Yur.personDetails.hide();
		__Yur.queue.hide();
		//__Yur.myTV.hide();
		__Yur.gcontent.hide();
		__Yur.ranking.hide();
		__Yur.moviePreview.hide();
		__Yur.nav('operator').activate(1);
		$('LiveInsTv').style.display = 'block';
		__Yur.tellAFriend.hide();
	},

	hide:			function () {
		if (__Yur.sitename == 'homepage') {
			$('LiveInsTv').style.display = 'none';
			//$('LiveInsTvInfo').style.display = 'none';
			//$('themaauswahloption').selected="selected";		
		 	//$('HowToIframe').src = '/blank.html';
		 }
	},
	
	mms_info_text:	function (text) {
		this.info_show();
		$('LiveInsTvHandyText').innerHTML = text;
	},
	
	set_sendung:	function (nr) {
		this.info_show();
		$('selectsendung').value = nr;
	},
	
	info_show: function() {
		$('LiveInsTvInfo').style.display = '';
	},
	
	info_hide: function() {
		//$('LiveInsTvInfo').style.display = 'none';
	}
	
}


// ##########################
// File: /storage/www/yur/www/lib/Yur/TV/LastKommentar.js
// ##########################
Yur_setUpNamespace(["Yur", "TV"])


Yur.TV.LastKommentar = function() {
	
	this.options = {
		debug_fetcher:	0
	};
	this.template = "last_kommentar.js.html";
}


Yur.TV.LastKommentar.prototype = {

	fetchKommentar:	function (movie_id,page) {
	 	var me = this;
		var fetcher = new Yur.API("last_kommentar", function (data) { me.dataReceived(data); })
		fetcher.cached = false;
		fetcher.setCacheIntervalSeconds(0)
		fetcher.debug = this.options.debug_fetcher;
		if (!movie_id) return;
		fetcher.get({
			movie_id: movie_id,
			page: page			
		});
		
		// Ladesymbol!!!!
		//$('kommentar').innerHTML = __Yur.loadingHTML("loading_hell");
	},
	
	dataReceived:	function (data) {
		this.draw(data)
	},
	
	showkommentaertextbox:			function (id) {
		if (__Yur.session.logged_in) {
			$('newkommentarschreiben'+id).style.display = '';
		} else {
			alert(unescape('Um ein Kommentar abgeben zu k%F6nnen, log dich bitte ein.'));
		}
	},
	
	hidekommentaertextbox:			function (id) {
		$('newkommentarschreiben'+id).style.display = 'none';
	},
	
	showantworttextbox:			function (id) {
		if (__Yur.session.logged_in) {
			$('antwortschreiben'+id).style.display = '';
		} else {
			alert(unescape('Um ein Kommentar abgeben zu k%F6nnen, log dich bitte ein.'));
		}
	},
	
	hideantworttextbox:			function (id) {
		$('antwortschreiben'+id).style.display = 'none';
	},
	
	draw:			function (data) {
		this.data = data;
		$('kommentar'+data.movie_id).innerHTML = "";
		
		var html = Jemplate.process(this.template, {
			model: data,
			tool: __Yur.tool
		});
				
		$('kommentar'+data.movie_id).innerHTML = html;
		
	},
	
	sendnew:	function (id) {
	
		var message = $('new_kommentar_text_'+id).value;
		
	 	var me = this;
		var fetcher = new Yur.API("last_kommentar/sendnew", function (data) { me.sendnewDataReceived(data); })
		fetcher.cached = false;
		fetcher.setCacheIntervalSeconds(0);
		fetcher.debug = false;
		fetcher.get({
			movie_id: id,
			message: message			
		});
	},

	sendnewDataReceived:	function (data) {
		if (data.error == 0) {
			this.hidekommentaertextbox(data.movie_id);
			$('newkommentarerfolgreich'+data.movie_id).style.display = '';
		} else {
		alert(unescape('Es ist zu einem %DCbertragungsfehler gekommen. Bitte versuch es sp%E4ter noch einmal.'));
		}
	},
	
	sendantwort:	function (k_id,m_id) {
	
		var message = $('antwort_text_'+k_id).value;
		
	 	var me = this;
		var fetcher = new Yur.API("last_kommentar/sendantwort", function (data) { me.sendantwortDataReceived(data); })
		fetcher.cached = false;
		fetcher.setCacheIntervalSeconds(0);
		fetcher.debug = false;
		fetcher.get({
			movie_id: m_id,
			kommentar_id: k_id,
			message: message			
		});
	},			
	
	sendantwortDataReceived:	function (data) {
		if (data.error == 0) {
			this.hideantworttextbox(data.kommentar_id);
			$('antworterfolgreich'+data.kommentar_id).style.display = '';
		} else {
		alert(unescape('Es ist zu einem %DCbertragungsfehler gekommen. Bitte versuch es sp%E4ter noch einmal.'));
		}
	},
	
	BewertungPositiv:	function (id) {
		this.fetchBewertung(id,1)
	},
	
		
	BewertungNegativ:	function (id) {
		this.fetchBewertung(id,-1)
	},
	
	fetchBewertung:	function (id,value) {
	 	var me = this;
		var fetcher = new Yur.API("last_kommentar/bewerte_kommentar", function (data) {me.BewertungDataReceived(data)})
		fetcher.cached = false;
		fetcher.setCacheIntervalSeconds(0)
		fetcher.debug = this.options.debug_fetcher;
		if (!id) return;
		fetcher.get({
			id: id,
			value: value			
		});
	},		
	
	
	BewertungDataReceived:	function (data) {
		if (data.id) {
			var result_str = "";
			if (data.result > 0) {result_str += "+"+data.result} else {result_str = data.result}
			$('kommentarbewertungsresult'+data.id).innerHTML = result_str;
		}
	}	
	
}
// ##########################
// File: /storage/www/yur/www/lib/Yur/TV/MeinYURtv.js
// ##########################
Yur_setUpNamespace(["Yur", "TV"])


Yur.TV.MeinYURtv = function() {
	this.template = "ranking_list.js.html";
	
	this.options = {
		debug:	0,
		cache_interval_seconds: 60
	};
}


Yur.TV.MeinYURtv.prototype = {

	showEdit:		function () {
		//__Yur.StreamingHTML = $('stream').innerHTML;
		//$('stream').innerHTML = '';
		$('change').style.display = "";
		$('Buttons').style.display = "";		
		$('static').style.display = "none";
		$('GenerallyContent').style.display = "none";
		$('navi1').style.display = "none";
		$('Navibottomleer').style.display = "";
		
	},	
	
	hideEdit:		function () {
		$('fehlerContainer').style.display = "none";
		$('change').style.display = "none";
		$('Buttons').style.display = "none";		
		$('static').style.display = "";
		$('GenerallyContent').style.display = "";
		$('navi1').style.display = "";
		$('Navibottomleer').style.display = "none";
		if (__Yur.UpdateError > 0) {
			__Yur.gcontent.loadMeinYURtvMovies(__Yur.current_id,1);
		}
		__Yur.UpdateError = 0;
		//$('stream').innerHTML = __Yur.StreamingHTML;
	},	
	
	showArchiv:		function() {
		__Yur.gcontent.archiv = 1;
		__Yur.gcontent.loadMeinYURtvMovies(__Yur.current_id,1);
	},
	
	showList:		function() {
		__Yur.gcontent.archiv = 0;
		__Yur.gcontent.loadMeinYURtvMovies(__Yur.current_id,1);
	},
	
	deactivateClip:	function (id) {
	 	var me = this;
		var fetcher = new Yur.API("movie/deactivate_by_user", function (data) { me.deactivateDataReceived(data,id); })
		fetcher.cached = true;
		fetcher.setCacheIntervalSeconds(this.options.cache_interval_seconds)
		fetcher.debug = this.options.debug;
		if (id == null) {
			alert('Fehler! Es wurde keine ID uebergeben.');
			return 0;
		}
		fetcher.get({
			id: id
		});
	},
	
	statusMessage:	function (id) {
	 	var me = this;
		var fetcher = new Yur.API("movie/status_message", function (data) { me.statusMessageDataReceived(data,id); })
		fetcher.cached = true;
		fetcher.setCacheIntervalSeconds(this.options.cache_interval_seconds)
		fetcher.debug = this.options.debug;
		if (id == null) {
			alert('Fehler! Es wurde keine ID uebergeben.');
			return 0;
		}
		fetcher.get({
			id: id
		});
	},
	
	
	activateClip:	function (id) {
	 	var me = this;
		var fetcher = new Yur.API("movie/activate", function (data) { me.activateDataReceived(data,id); })
		fetcher.cached = true;
		fetcher.setCacheIntervalSeconds(this.options.cache_interval_seconds)
		fetcher.debug = this.options.debug;
		if (id == null) {
			alert('Fehler! Es wurde keine ID uebergeben.');
			return 0;
		}
		fetcher.get({
			id: id
		});
	},
	
	ClipToArchiv:	function (id) {
	 	var me = this;
		var fetcher = new Yur.API("movie/clip_to_archiv", function (data) { me.ClipToArchivDataReceived(data,id); })
		fetcher.cached = true;
		fetcher.setCacheIntervalSeconds(this.options.cache_interval_seconds)
		fetcher.debug = this.options.debug;
		if (id == null) {
			alert('Fehler! Es wurde keine ID uebergeben.');
			return 0;
		}
		fetcher.get({
			id: id
		});
	},
	
	ClipToList:	function (id) {
	 	var me = this;
		var fetcher = new Yur.API("movie/clip_to_list", function (data) { me.ClipToListDataReceived(data,id); })
		fetcher.cached = true;
		fetcher.setCacheIntervalSeconds(this.options.cache_interval_seconds)
		fetcher.debug = this.options.debug;
		if (id == null) {
			alert('Fehler! Es wurde keine ID uebergeben.');
			return 0;
		}
		fetcher.get({
			id: id
		});
	},
		
	
	setMovieInactive:	function (id) {
		$('moviein'+id).style.display = '';
		$('moviein'+id).className = 'detailsinactiv';
		$('movie'+id).style.display = 'none';
		$('details'+id).style.display = 'none';
	},
	
	setMovieActive:	function (id) {
		$('moviein'+id).style.display = 'none';
		$('movie'+id).style.display = '';
		$('movie'+id).className = 'detailsclose';
	},	
	
	deactivateDataReceived:	function (data,id) {
		//this.setMovieInactive(id);
		//this.showMessage('Der Clip wurde erfolgreich vom Sender genommen!');
		location.href=location.href;
	},
	
	activateDataReceived:	function (data,id) {
		//this.setMovieActive(id);
		//this.showMessage('Der Clip wurde erfolgreich aktiviert!');
		location.href=location.href;
	},
	
	statusMessageDataReceived:	function (data,id) {
		//this.showMessage(data.statusmessage);
		alert(unescape(data.statusmessage));
	},
	
	ClipToArchivDataReceived:	function (data,id) {
		this.showMessageWithReload('Clip wurder erfolgreich ins Archiv verschoben.');
	},
	
	ClipToListDataReceived:	function (data,id) {
		this.showMessageWithReload('Clip wurder erfolgreich aus dem Archiv verschoben.');
	},
	
	showBlende:	function () {
		var theight = $("Container").offsetHeight;
		//var twidth = $("Container").offsetWidth;
		$("Blende").style.height = theight+"px";
		//$("Blende").style.width = twidth+"px";
		$("Blende").style.display = "inline";
	},
	
	hideBlende:	function () {
		$("Blende").style.display = "none";
	},
	
	showMessage:	function (message) {
		this.showBlende();
		$("messageText").innerHTML = message;
		$("messageBox").style.display = "block";
		$("messageBtn").style.display = "block";
		$("messageBtnReload").style.display = "none";
	},	
	
	showMessageWithReload:	function (message) {
		this.showMessage(message);
		$("messageBtn").style.display = "none";
		$("messageBtnReload").style.display = "block";
	},	
	
	hideMessage:	function () {
		$("messageBox").style.display = "none";
		this.hideBlende();		
	},
	
	hideMessageWithReload:	function () {
		this.hideMessage();		
		__Yur.gcontent.loadMeinYURtvMovies(__Yur.current_id,1);
	}
	
	
	
	
	
}
// ##########################
// File: /storage/www/yur/www/lib/Yur/TV/MoviePreview.js
// ##########################
Yur_setUpNamespace(["Yur", "TV"])


Yur.TV.MoviePreview = function() {
	this.movie = new Yur.BO.Movie();
	var me = this;
	this.movie.onSuccess = function (id) { me.aktuell = id };
	this.aktuell = null;
	this.preview_from = null;
}


Yur.TV.MoviePreview.prototype = {

	show: function (id, from) {
		if (id == null) return;
		if (!__Yur.session.hideLogin()) return;
		this.movie.preview_from = from;
		if (this.aktuell != id) {
			this.movie.requestData(id);
		} 
		this._open();
	},
	
	hide: function () {
		__Yur.player.secondaryPlayerPaused()
		this.movie.div().style.display = 'none';
		__Yur.unfreeze(this);
	},
	
	_open:		function () {
		__Yur.personDetails.hide();
		__Yur.session.hideLogin();
		if (__Yur.sitename == 'homepage') {
			__Yur.queue.hide();
			__Yur.howTo.hide();
			__Yur.gcontent.hide();
			__Yur.ranking.hide();
			//__Yur.myTV.hide();
			__Yur.nav('operator').reset();
		}
		this.movie.div().style.display = 'block';
		__Yur.freeze(this);
	}
	
}

// ##########################
// File: /storage/www/yur/www/lib/Yur/TV/MyTV.js
// ##########################
Yur_setUpNamespace(["Yur", "TV"])

Yur.TV.MyTV = function() {}

Yur.TV.MyTV.prototype = {
	show:			function () {
		if (__Yur.session.logged_in) {
			this._show();
		} else {
			var me = this;
			__Yur.session.showLogin(function () { me._show() });
		}
	},
	
	_show:			function (url) {
		if (!__Yur.session.hideLogin()) return;
		if (url == null) {
			$('MyTVIframe').src = '/mytv/movies'; // default
		} else {
			$('MyTVIframe').src = url;
		}
		__Yur.personDetails.hide();
		__Yur.queue.hide();
		__Yur.howTo.hide();
		__Yur.gcontent.hide();
		__Yur.ranking.hide();
		__Yur.moviePreview.hide();
		__Yur.nav('operator').activate(1);
		$('MyTV').style.display = 'inline';
	},
	
	showRegister:	function () {
		this._show('/register/step1');
	},
	
	hide:			function () {
		$('MyTV').style.display = 'none';
		$('MyTVIframe').src = '/blank.html';
	}
}


// ##########################
// File: /storage/www/yur/www/lib/Yur/TV/Navigation.js
// ##########################
Yur_setUpNamespace(["Yur", "TV"])

Yur.TV.Navigation = function(name) {
	this.name = name + 'ReiterDiv';
	this.active = null;
	this.root = '/pics/navi/'+name;
	
	var count = 0;
	
	while ($(this.name + "" + count) != null) count++;
	
	if (!count) throw "Keine Navigation mit dem Namen " + name + " gefunden!";
	
	this.anzahl_reiter = count;
	this.anzahl_divs = count;
		
	$LOG(count + " Reiter in '" + name + "' gefunden.");
}


Yur.TV.Navigation.prototype = {

	activate:			function (i) {
		if (this.active != null) this.reset();
		//if (i < 0 || i > (this.anzahl_reiter - 1)) throw "Invalid index " + i + " for " + this.name;
		var counter = 0;
		while (counter <= (this.anzahl_reiter-1)) {
			this._set(counter+"", false, false);
			counter++;
		}
		this.active = i;
		this._set(i, true, false);
		
		__Yur.adver.click();
		window.urchinTracker("/page/"+this.name);
	},

	over:			function (i) {
		var obj = $(this.name + "" + i);
		if (obj.className.indexOf('in') > -1) {
			this.active = i;
			this._set(i, true, true);
		}
		//urchinTracker("/page/"+this.name);
	},

	out:			function (i) {
		var obj = $(this.name + "" + i);
		if (obj.className.indexOf('over') > -1) {
			if (this.active != null) this.reset();
		}
	},
	
	reset:				function () {
		if (this.active == null) return;
		this._set(this.active, false, false);
		this.active = null;
	},

	_set:				function (i, to, over) {
		this._subSet(i, to,  0, over);
	},
	
	_subSet:			function (i, to, x, over) {
		var classname;

		if (to) {
			if (over) {classname = 'btnover'} else {classname = 'btnact'} 
		} else { 
			classname = 'btnin'
		}

		$LOG("i:"+i+"   x:"+x+"   name:"+name);

		var obj = $(this.name + "" + i);
		//alert(this.root + name + '.gif'+' ---- '+this.name + "" + i);
		//alert(obj.className +"  zu: "+classname+"     DIV: "+this.name + "" + i);
		obj.className = classname;
	}
	
}

// #### PRELOAD ######

Yur.TV.Navigation.picturesPreload = function () {
	var root = '/pics/navi/operator';
	var names = new Array('0_in.gif', '0_act.gif', '1_in.gif', '1_act.gif', '2_in.gif', '2_act.gif');
	if (!Yur.TV.Navigation.picturesPreloadArray) Yur.TV.Navigation.picturesPreloadArray = new Array();
	var i;
	for(i=0; i < names.length; i++) {
		var img = document.createElement('img');
		img.src = root + '/' + names[i];
		Yur.TV.Navigation.picturesPreloadArray[Yur.TV.Navigation.picturesPreloadArray.length] = img;
	}
}

Yur.TV.Navigation.picturesPreload();

// ###################



// ##########################
// File: /storage/www/yur/www/lib/Yur/TV/NowPlaying.js
// ##########################
Yur_setUpNamespace(["Yur", "TV"])


var lastQueue;
var lastQueueTyp;

var lastFeed;
var lastMovie;
var wasFeed = false;

Yur.TV.NowPlaying = function() {
	
	this.options = {
		debug_fetcher: false,
		cache_interval_seconds: 4
	};
	this.interaktionsfeld;
}


Yur.TV.NowPlaying.prototype = {
	getClassByTyp: function (queue_typ_value) {
	
		var queue_typ = queue_typ_value
		
		if(queue_typ == null || queue_typ == "") {
			queue_typ = "gongshow"
		}
		
		switch (queue_typ) {
			case "gongshow": 	return new Yur.TV.Voting.GongShow(); 
			case "hot_or_not": 	return new Yur.TV.Voting.HotOrNot();
			default: 			return new Yur.TV.Voting.Abstract();
		}
	},
	
	fetchData:	function () {
		var me = this;
		var fetcher = new Yur.API("now_playing", function (data) { me.dataReceived(data); })
		fetcher.cached = true;
		fetcher.debug = this.options.debug_fetcher;
		fetcher.setCacheIntervalSeconds(this.options.cache_interval_seconds);
		fetcher.get({ playlist_id: __Yur.playlist_id });
			
	},
	
	dataReceived: function (data) {
//		if (__Yur.freezing()) {
//			$LOG("Received " + data.length + " but freezed");
//		} else {
			$LOG("Received Airtime " + data.playing.id);
			this.draw(data);
//		}
	},
	
	
	draw: function (data) {
		var playing  = data.playing;
		var next     = data.next;
		var prev     = data.previous;
		if (__Yur.sitename == 'homepage' || __Yur.sitename == 'programmzeitschrift' || __Yur.sitename == 'standardCMS') {
			var nextqueue = new Yur.BO.NextQueue();
			nextqueue.fromData(data.nextqueue);
			if (nextqueue != null) {
				nextqueue.display()
			}
		}
		// ******** Aktueller Clip ***********
		var now      = new Yur.BO.Airtime();
		this.airtime = now;
		now.fromData(playing);
		
		if(now.is_special == 1) {
			if(next != null) {
				now      = new Yur.BO.Airtime()
				now.fromData(next)
			}
		}
		
		var offset = 0; //no more offset :) __Yur.player.fullOffset();
		
		now.time_remaining = new Number(now.time_remaining) + offset
		now.yur_sitename = __Yur.sitename;
		
	
		if(now.time_reamining < 0) {
			now.time_reamining = 0;
		}
			
		if (this.lastQueueTyp != now.optional_queue_item.queue_.queue_typ) {
			if (this.interaktionsfeld) {this.interaktionsfeld.hide()};
			this.interaktionsfeld = this.getClassByTyp(now.optional_queue_item.queue_.queue_typ);
			this.lastQueueTyp = now.optional_queue_item.queue_.queue_typ;
		}
		
		// nur fuer Triff deinen Star ******************
		if ($('triffdeinenstarranking')) {
			if (now.optional_queue_item.queue_.meta == 101) {
				$('triffdeinenstarranking').style.display='';
			} else { $('triffdeinenstarranking').style.display='none'; }
		}
		// **********************
		
		if (__Yur.sitename == 'homepage' || __Yur.sitename == 'remote' ) {
			if(now != null) {
				now.display()
				if(now.optional_queue_item != null) {
					__Yur.current_playing = now.optional_queue_item.movie_.id;
					this.interaktionsfeld.setMovie(__Yur.current_playing, now.gongshow);
				}
			} else {
				this.interaktionsfeld.setMovie();
				$LOG("No current clip")
			}
		
			this.interaktionsfeld.show();
		}
		this.drawBanner(now);
	},
	
	drawBanner: function (now) {
		if(now.optional_queue_item != null) {
			var queue = now.optional_queue_item.queue_;
			var movie = now.optional_queue_item.movie_;
			var feed  = movie.optional_podcast_feed;
			
			var div   = $("QueueBannerContent");
			var textdiv   = $("QueueText");		
			
			if(feed != null) { // ist ein Podcast
				if(feed.id != lastFeed) {
					wasFeed = true
					
					div.innerHTML = '<div class="blog"><a href="'+feed.blog_link+'" target="_blank">'+feed.title+'</a></div>';
					lastFeed = feed.id;
				}
			} else {
			
				
				if(lastQueue == null || lastQueue != queue.id || wasFeed) { 
					wasFeed       = false
					
					var width  = 190;
					var height = 50;
						
					var targetx = '';
					if (queue.banner_target) {targetx = ' target="'+queue.banner_target+'"'}
					
					div.innerHTML = '<div style="background-image:url(/pics/banner/queue/'+queue.meta+'.jpg); background-repeat:no-repeat">'+
										'<a href="'+queue.href+'"'+targetx+'><img src="/pics/shared/box_top_schatten_teaser.png" width="'+width+'" height="3" alt="" /><img src="/pics/shared/t.gif" width="'+width+'" height="'+height+'" alt="" /></a>'+
									'</div>';
					textdiv.innerHTML = queue.description;
					
					lastQueue     = queue.id;
				}
			}
			
		}
	}
}

// ##########################
// File: /storage/www/yur/www/lib/Yur/TV/NowPlayingForwarder.js
// ##########################
Yur_setUpNamespace(["Yur", "TV"])


var lastQueue;
var lastQueue2;
var lastFeed;
var wasFeed = false;

/*
var forwarder = new Yur.TV.NowPlayingForwarder();
forwarder.setForward(idOfTriffDeinenStar, "/triffdeinenstarMitPlayer")
forwarder.setForward(idOfTriffDeinenStar, function () {
	$("di")
})
forwarder.loop()
*/

Yur.TV.NowPlayingForwarder = function() {
	
	this.options = {
		debug_fetcher: false,
		cache_interval_seconds: 10
	};
	
	this.forwardMap = {};
	this.target_queue;
	this.backfunction;

	this.target     = window
}


Yur.TV.NowPlayingForwarder.prototype = {
	fetchData:	function () {
		var me = this;
		var fetcher = new Yur.API("now_playing", function (data) { me.dataReceived(data); })
		fetcher.cached = true;
		fetcher.debug = this.options.debug_fetcher;
		fetcher.setCacheIntervalSeconds(this.options.cache_interval_seconds);
		fetcher.get({ playlist_id: __Yur.playlist_id });
	
	},
	
	dataReceived: function (data) {
		$LOG("Received Airtime " + data.playing.id);
		this.draw(data);
	},
	
	setForward: function (queue_id, url, backfunction) {
		this.forwardMap[""+queue_id] = url;
		this.backfunction = backfunction;
		this.target_queue = queue_id;
	},
	
	loop: function () {
		var me = this;
		me.fetchData();
		
		this.timeout = window.setInterval( function () { me.fetchData() }, 4000 ) // fetchData every four seconds
	},
	
	
	draw: function (data) {
		var playing  = data.playing;
		var next     = data.next;
		var prev     = data.previous;
		
		var now      = new Yur.BO.Airtime();
		this.airtime = now;
	
		now.fromData(playing)
		
		if(now.optional_queue_item != null) {
			var queue_id = now.optional_queue_item.queue_.meta;
			
			var forward  = this.forwardMap[""+queue_id];
			
			if(forward != null && forward != "") {
				//this.forwardMap[""+queue_id] = null
			
				if(typeof forward == "function") {
					forward()
				} else {
					this.target.location.href = forward;
				}
			}
			if (this.target_queue != queue_id ) {
				this.backfunction()
			}

		}
		
	}
}

// ##########################
// File: /storage/www/yur/www/lib/Yur/TV/OperatorBlende.js
// ##########################
Yur_setUpNamespace(["Yur", "TV"])


Yur.TV.OperatorBlende = function() {
}


Yur.TV.OperatorBlende.prototype = {

	show: function (id) {
		$("operatorBlende").style.display = "inline";
		if (__Yur.sitename == 'homepage') {
			$("QueueItemList").style.overflow = "hidden";
			$("RankingList").style.overflow = "hidden";
			$("MoviePreview").style.overflow = "hidden";
		}
	},
	
	showFull: function (id) {
		$("operatorBlende").style.display = "inline";
	},

	hideFull: function () {
		$("operatorBlende").style.display = "none";
	},

	
	hide: function () {
		if (__Yur.sitename == 'homepage') {
			$("MoviePreview").style.overflow = "auto";
			$("RankingList").style.overflow = "auto";
			$("QueueItemList").style.overflow = "auto";
		}
		if (__Yur.sitename != 'login') {
			$("operatorBlende").style.display = "none";
		}
	}
	
}

// ##########################
// File: /storage/www/yur/www/lib/Yur/TV/PersonDetails.js
// ##########################
Yur_setUpNamespace(["Yur", "TV"])


Yur.TV.PersonDetails = function() {
	this.person = new Yur.BO.Person();
	var me = this;
	this.person.onSuccess = function () { me._open() };
	this.aktuell = null;
}


Yur.TV.PersonDetails.prototype = {

	show: function (id) {
		if (id == null) return;
		if (this.aktuell != id) {
			this.aktuell = id;
			this.person.requestData(id);
		} else {
			this._open();
		}
	},
	
	hide: function () {
		__Yur.operatorBlende.hide();
		this.person.div().style.display = 'none';
		this.aktuell = null;
		var tp = $('ThumbPlayerContainer');
		if(tp) tp.style.visibility = 'visible';
	},
	
	_open:		function () {
		if (!__Yur.session.hideLogin()) return;
		__Yur.operatorBlende.show();
		var tp = $('ThumbPlayerContainer');
		if(tp) tp.style.visibility = 'hidden';
		this.person.div().style.display = 'block';
	}
	
}

// ##########################
// File: /storage/www/yur/www/lib/Yur/TV/PreiseRaking.js
// ##########################
Yur_setUpNamespace(["Yur", "TV"])


Yur.TV.PreiseRanking = function() {
	
	this.options = {
		debug_fetcher:	0,
		cache_interval_seconds: 4
	};
	
	this.page = 1;
	this.queue = 74;
	this.timing = 0;
	this.data = null;
	
	this.template = "preise_ranking_list.js.html";
	
	this.something_requested = 0;
}


Yur.TV.PreiseRanking.prototype = {

	init:			function () {
		if (this.something_requested) return;
		this.fetchRanking();
	},

	setQueue:		function () {
		if (this.timing == 0) {this.queue = 74};
		if (this.timing == 1) {this.queue = 75};		
		if (this.timing == 2) {this.queue = 76};
		if (this.timing == 3) {this.queue = 77};
		if (this.timing == 4) {this.queue = 78};		
	},

	fetchRanking:	function (alias) {
		
		__Yur.adver.click()
	
		this.something_requested = 1;
	 	var me = this;
		var fetcher = new Yur.API("preiseranking", function (data) { me.dataReceived(data); })
		fetcher.cached = true;
		fetcher.setCacheIntervalSeconds(this.options.cache_interval_seconds)
		fetcher.debug = this.options.debug_fetcher;
		if (alias == null) alias = "";
		fetcher.get({
			page: this.page,
			queue: this.queue,
			search: alias
			
		});
		if (alias == "") $('RankingList').innerHTML = __Yur.loadingHTML("loading_hell");
	},
	
	dataReceived:	function (data) {
		if (data.not_found) {
			alert("Dieser Benutzername existiert nicht.");
		} else {
			if (data.person && !data.page) {
				this.hideSearch();
				__Yur.personDetails.person.saveResult(data.person);
				__Yur.personDetails._open();
			} else {
				if (data.found) this.hideSearch();
				this.draw(data)
			}
		}
	},
	
	draw:			function (data) {
		this.data = data;

		$('RankingList').innerHTML = "";
		
		var html = Jemplate.process(this.template, {
			model: data,
			tool: __Yur.tool
		});
				
		$('RankingList').innerHTML = html;
		
		if (data.found) {
			var pos = -1;
			for (var i = 0; i < data.list.length && pos < 0; i++) {
				if (data.list[i].id == data.person) pos = i;
			}
			if (pos >= 0) {
				$('RankingList').scrollTop = (pos * 20);
			}
		}
	},
	
	show:			function () {
		$('Ranking').style.display = 'inline';
		__Yur.nav('Ranking').activate(this.timing);
		this.init();
	},
	
	hide:			function () {
		$('Ranking').style.display = 'none';
	},
	
	showSearch:		function () {
		__Yur.personDetails.hide();
		__Yur.operatorBlende.show();
		$("Search").style.display = "inline";
		this.searchFocus();
	},
	
	hideSearch:		function () {
		__Yur.operatorBlende.hide();
		$("Search").style.display = "none";
		return true;
	},
	
	searchFocus:		function () {
		try {
			$("searchForm").alias.focus();
			$("searchForm").alias.select();
		 } catch(e) { /* Der IE kann keinem Element den Focus geben, wenn es unsichtbar ist... */}
	},
	
	search_form:		function (f) {
		this.fetchRanking(f.alias.value);
	},
	
	changeSorting:		function (sorting) {
		this.sorting = sorting;
		this.fetchRanking();
	},
	
	changeTiming:	function (timing) {
		this.timing = timing;
		this.page = 1; /* Wenn das Timing geaendert wird, wird immer auf die erste Seite gesprungen (auch Wichtig fuer die Gewinner!!) */
		this.setQueue();
		this.fetchRanking();
		if (this.timing >= 0) {
			__Yur.nav('Ranking').activate(this.timing);
		}

	},
	
	getPage:		function (page) {
		this.page = page;
		this.fetchRanking();
	},
	
	getPageForm:		function (name) {
		page = $(name).value;
		var ZugelasseneZeichen = '0123456789';
		for (var Pos = 0; Pos < page.length; Pos++) {
    		if (ZugelasseneZeichen.indexOf(page.charAt(Pos)) == -1) {
      			alert(unescape("Bitte geben Sie eine g%FCltige Seitenzahl ein."));
	   			return false;
      		}
 		}
		this.page = page;
		this.fetchRanking();
	}
	
}
// ##########################
// File: /storage/www/yur/www/lib/Yur/TV/Queue.js
// ##########################
Yur_setUpNamespace(["Yur", "TV"])


Yur.TV.Queue = function() {
	
	this.options = {
		pagination_template: 'queue_pagination.js.html',
		debug_fetcher: false
	};
	
	this.items = {};
	this.page = 1;
}


Yur.TV.Queue.prototype = {

	makeEmpty:	function () {
		for(var id in this.items) {
			if (typeof(this.items[id]) != "object") {
				continue
			}
		
			this.items[id].remove();
			delete(this.items[id]); // Mit delete verschwindet das Object wirklich aus dem Hash.
		}
		//this.hidePagination();
		//$('QueueLoading').style.display = 'none';
		//$('QueueEmptyText').style.display = 'block';
	},

	fetchData:	function () {
	 	var me = this;
	 	var page = this.page;
	 	var success = function (data) { me.dataReceived(data, page) };
	 	var failure = function () { me.makeEmpty() };
		var fetcher = new Yur.API("queue"+"/"+page, success, failure)
		fetcher.debug = this.options.debug_fetcher;
		fetcher.cached = true;
		fetcher.setCacheIntervalSeconds(4);
		fetcher.get({ playlist_id: __Yur.playlist_id });
	},
	
	dataReceived: function (data, page) {

		this.data = data

		if (__Yur.freezing()) {
			$LOG("Received " + data.length + " but freezed");
			return;
		}

		if (this.page != page && this.page != data.pagination.curr) return;
		
		$LOG("Received Queue " + data.items.length);
		if (data.items.length) this.draw(data)
		else this.makeEmpty();
	},
	
	showPagination:	function (bottom) {
		var p = this.pagination;
		
		var html = Jemplate.process(this.options.pagination_template, {
			pa: p,
			tool: __Yur.tool
		})
		
		if (p.curr > 1) {
			$('queuePaginationTop').innerHTML = html;
			$('queuePaginationTop').style.display = 'block';
		} else {
			$('queuePaginationTop').style.display = 'none';
		}
		
		if (p.entries_on_page > 4) {
			$('queuePaginationBottom').innerHTML = html;
			$('queuePaginationBottom').style.top = (bottom + 1) + 'px';
			$('queuePaginationBottom').style.display = 'block';
		} else {
			$('queuePaginationBottom').style.display = 'none';
		}
	},
	
	hidePagination:	function () {
		$('queuePaginationTop').style.display = 'none';
		$('queuePaginationBottom').style.display = 'none';
	},
	
	draw: function (data) {
	
		
		
	},
	
	show:			function () {
		if (!__Yur.session.hideLogin()) return;
		__Yur.queue_hide = 0;
		__Yur.personDetails.hide();
		__Yur.howTo.hide();
		__Yur.tellAFriend.hide();
			//__Yur.myTV.hide();
		__Yur.gcontent.hide();
			//__Yur.ranking.hide();
		__Yur.moviePreview.hide();
		__Yur.nav('operator').activate(0);
		$('OperatorBanner').style.display = 'block';
		if (__Yur.votespecial != 1) {
			__Yur.unfreeze("queue_hidden");
			$('QueueItemList').style.display = 'inline';
			$('OperatorContent').className = 'content';
			$('votespecial').style.display='none';
		} else {
			if (__Yur.sitename == 'homepage') {
				$('QueueItemList').style.display = 'none';
				__Yur.freeze("queue_hidden");
				//$('OperatorBanner').style.display = 'none';
				$('OperatorContent').className = 'content';
				$('votespecial').style.display='block';
			}
		}
		
	},
	
	hide:			function () {
		if (__Yur.sitename == 'homepage') {
			__Yur.queue_hide = 1;
			$('QueueItemList').style.display = 'none';
			__Yur.freeze("queue_hidden");
			$('OperatorBanner').style.display = 'none';
			$('OperatorContent').className = 'contentBig';
			$('kuechevital').style.display='none';
			$('votespecial').style.display='none';
		}
	}
	
}
// ##########################
// File: /storage/www/yur/www/lib/Yur/TV/Ranking.js
// ##########################
Yur_setUpNamespace(["Yur", "TV"])


Yur.TV.Ranking = function() {
	
	this.options = {
		debug_fetcher:	0,
		cache_interval_seconds: 600
	};
	
	this.page = 1;
	this.timing = 6;
	this.sorting = 1;
	
	this.data = null;
	
	this.template = "ranking_list.js.html";
	this.template_first3 = "ranking_first3.js.html";
	
	this.something_requested = 0;
}


Yur.TV.Ranking.prototype = {

	init:			function () {
		if (this.something_requested) return;
		this.fetchRanking();
		if (this.timing && this.timing == 1) {
			$('rankingHeadlineButtonThreeMonth').className = 'cursor act';
		} else if (this.timing && this.timing == 2) {
			$('rankingHeadlineButtonOneWeek').className = 'cursor act';
		} else if (this.timing && this.timing == 3) {
			$('rankingHeadlineButtonOneDay').className = 'cursor act';
		} else {
			var btn = $('rankingHeadlineButtonAllTime')
			if(btn != null)
				btn.className = 'cursor act';
		}
	},

	fetchRanking:	function (alias) {
		
		__Yur.adver.click()
	
		this.something_requested = 1;
	 	var me = this;
		var fetcher = new Yur.API("ranking", function (data) { me.dataReceived(data); })
		fetcher.cached = true;
		fetcher.setCacheIntervalSeconds(this.options.cache_interval_seconds)
		fetcher.debug = this.options.debug_fetcher;
		if (alias == null) alias = "";
		fetcher.get({
			page: this.page,
			timing: this.timing,
			sorting: this.sorting,
			search: alias
			
		});
		if (alias == "") $('RankingList').innerHTML = __Yur.loadingHTML("loading_hell");
	},
	
	dataReceived:	function (data) {
		if (data.not_found) {
			alert("Dieser Benutzername existiert nicht.");
		} else {
			if (data.person && !data.page) {
				this.hideSearch();
				__Yur.personDetails.person.saveResult(data.person);
				__Yur.personDetails._open();
			} else {
				if (data.found) this.hideSearch();
				this.draw(data)
			}
		}
	},
	
	draw:			function (data) {
		this.data = data;

		$('RankingList').innerHTML = "";
		
		var html = Jemplate.process(this.template, {
			model: data,
			tool: __Yur.tool
		});
				
		var html2 = Jemplate.process(this.template_first3, {
			model: data,
			tool: __Yur.tool
		});
		
		$('RankingList').innerHTML = html;
		if (data.page == 1) {
			$('Gewinner').innerHTML = html2;
		}
		if (data.found) {
			var pos = -1;
			for (var i = 0; i < data.list.length && pos < 0; i++) {
				if (data.list[i].id == data.person) pos = i;
			}
			if (pos >= 0) {
				$('RankingList').scrollTop = (pos * 20);
			}
		}
	},
	
	show:			function () {
		$('Ranking').style.display = 'inline';
		__Yur.nav('Ranking').activate(this.timing);
		this.init();
	},
	
	hide:			function () {
		$('Ranking').style.display = 'none';
	},
	
	showSearch:		function () {
		__Yur.personDetails.hide();
		__Yur.operatorBlende.show();
		$("Search").style.display = "inline";
		this.searchFocus();
	},
	
	hideSearch:		function () {
		__Yur.operatorBlende.hide();
		$("Search").style.display = "none";
		return true;
	},
	
	searchFocus:		function () {
		try {
			$("searchForm").alias.focus();
			$("searchForm").alias.select();
		 } catch(e) { /* Der IE kann keinem Element den Focus geben, wenn es unsichtbar ist... */}
	},
	
	search_form:		function (f) {
		this.fetchRanking(f.alias.value);
	},
	
	changeSorting:		function (sorting) {
		this.sorting = sorting;
		this.fetchRanking();
	},
	
	changeTiming:	function (timing) {
		this.timing = timing;
		this.page = 1; /* Wenn das Timing geaendert wird, wird immer auf die erste Seite gesprungen (auch Wichtig fuer die Gewinner!!) */
		this.fetchRanking();
		if (this.timing >= 0) {
			__Yur.nav('Ranking').activate(this.timing);
		}

	},
	
	getPage:		function (page) {
		this.page = page;
		this.fetchRanking();
	},
	
	getPageForm:		function (name) {
		page = $(name).value;
		var ZugelasseneZeichen = '0123456789';
		for (var Pos = 0; Pos < page.length; Pos++) {
    		if (ZugelasseneZeichen.indexOf(page.charAt(Pos)) == -1) {
      			alert(unescape("Bitte geben Sie eine g%FCltige Seitenzahl ein."));
	   			return false;
      		}
 		}
		this.page = page;
		this.fetchRanking();
	}
	
}
// ##########################
// File: /storage/www/yur/www/lib/Yur/TV/SendForm.js
// ##########################
Yur_setUpNamespace(["Yur", "TV"])

Yur.TV.SendForm = function() {}

Yur.TV.SendForm.prototype = {

	showOK:		function () {
		$('sendformok').style.display = 'block';
	},	

	hide:			function () {
		$('sendformbox').style.display = 'none';
	},

	send:	function () {
	
		var paras = {};
		
		var f = $('sendform');
		var error ='';
	
		error = validateForm(f, "name", "Name", "R", "email", "Email", "REmail");
		if (error != '') {
			publishError(error);
		}
	
		if (error == '') {
			paras["name"] = $('name').value;
			paras["email"] = $('email').value;
			paras["frage"] = $('frage').value;
			paras["site"] = $('site').value;

		 	var me = this;
			var fetcher = new Yur.API("sendform/send", function (data) { me.sendDataReceived(data); })
			fetcher.cached = false;
			fetcher.setCacheIntervalSeconds(0);
			fetcher.debug = false;
			fetcher.get(paras);
		}
	},
	
	sendDataReceived:	function (data) {
		this.hide();
		this.showOK();
	}
	
}


// ##########################
// File: /storage/www/yur/www/lib/Yur/TV/Session.js
// ##########################
Yur_setUpNamespace(["Yur", "TV"])

Yur.TV.Session = function() {
	this.logged_in = false;
	this.offset = null;
	this.requesting = false;
	this.person = null;
	this.options = {
		clear_password: true,
		activity_interval_seconds: (5 * 60 * 1000), // 5 Minuten

		// Debug der einzelnen Requests kann auch zur Laufzeit ein/aus geschaltet werden.
		debug_sync: 0,
		debug_activity: 0,
		debug_login: 0,
		debug_logout: 0,
		debug_reset_passwd: 0
	};
	this.temp = {};
	
	var me = this;
	this.activity_interval = setInterval(function () { me.activity() }, this.options.activity_interval_seconds)
}

Yur.TV.Session.prototype = {

	activity:		function () {
		var me = this;
		var fetcher = new Yur.API("session/activity", function (data) {})
		fetcher.debug = this.options.debug_activity;
		fetcher.get();
	},

	onSync: 		function (data) {},
	
	onLogin:		function () {
		if (__Yur.sitename == 'login') {
			location.href='/my';
		}	
	},
	
	onLogout:		function () { 
		$LOG("Ausgeloggt");
		location.href = "/logout_page"
	},

	sync:			function () {
		var me = this;
		var fetcher = new Yur.API("session/sync", function (data) { me.sync_dataReceived(data); }, function (error) { me.sync_error(error); })
		fetcher.debug = this.options.debug_sync;
		fetcher.post({ now: (new Date().getTimeSeconds()) });
	},

	sync_dataReceived:	function (data) {
		if (data.logged_in > 0) this.logged_in = true
		else this.logged_in = false;

		//this.offset		= data.offset;
		if (__Yur.sitename != 'fullscreen' && __Yur.sitename != 'remote') {
			if (this.logged_in) {
				this.person = data.person;
				if (__Yur.sitename != 'login' && __Yur.sitename != 'register_frame') {
					this.showLogoutButton();
				}
			} else {
				this.person = null; // Nur fŸr den Fall das da doch was komisch schief gelaufen ist...
				this.hideLogoutButton();
			}
		}
		__Yur.addVotes(data.votes);
		this.onSync(data);
	},

	sync_error:			function (error) {
		// Immo wei§ ich noch nicht so recht was passieren soll, wenn der Sync schief geht ....   (Eric)
		$LOG(error.string);
	},

	logout:				function () {
		if (this.requesting || !(this.logged_in)) return;
		this.requesting = true;
		var me = this;

		var onSuccess = function () {
			me.requesting = false;
			me.logged_in = false;
			me.person = null;
			if (me.temp.form && me.options.clear_password) me.temp.form.login_passwd.value = "";
			//me.hideLogoutButton();
			
			//if (!__Yur.fullscreen && __Yur.sitename != 'meinyurtv') __Yur.queue.show();
			//if (__Yur.sitename == 'homepage') __Yur.queue.show();
			me.onLogout();
		};

		var onFailure = function (error) {
			me.requesting = false
			// Logout fehlgeschlagen, was nu?     (Eric)
			alert(error.string)
		};

		var fetcher = new Yur.API("session/logout", onSuccess, onFailure);
		fetcher.debug = this.options.debug_logout;
		fetcher.get();
	},

	login_form :		function (form, onFailureExtra) {
		if (this.requesting) return;
		if(form == null) form = $('loginForm');
		var user = form.user_id.value;
		var pass = form.login_passwd.value;
		this.temp.form = form;
		this.login(user, pass, onFailureExtra);
	},

	login:				function (user, pass, onFailureExtra) {
		if (this.requesting) return;
		this.requesting = true;
		var me = this;
		var onSuccess = function (data) {
			me.logged_in = true;
			me.person = data.person;
			me.requesting = false;
			//me.hideLogin();
			__Yur.addVotes(data.votes);
			if (__Yur.sitename != 'login') {
				me.showLogoutButton();
			}
			me.onLogin();
			var loginobj      = new Yur.BO.Login();
			loginobj.fromData(data.person)
		};
		
		var onFailure = function (error) {
			me.requesting = false;
			$LOG(error.string);
			alert("Benutzername/Passwort falsch");
			onFailureExtra()
		};
		
		var fetcher = new Yur.API("session/login", onSuccess, onFailure)
		fetcher.debug = this.options.debug_login;
		fetcher.post({
			user_id:  user,
			login_passwd: pass
		});
	},
	
	showLogin:		function (f) {
		if (this.requesting) return;
		if (f) { this.onLogin = f; }
		else { this.onLogin = function () {}; }
		if (!__Yur.fullscreen) {
			//__Yur.personDetails.hide();
			var tp = $('ThumbPlayerContainer');
			if(tp) tp.style.visibility = 'hidden';
		}
		__Yur.operatorBlende.show();
		$("Login").style.display = "inline";
		this.loginFocus();
	},
	
	showLoginFull:		function (f) {
		if (this.requesting) return;
		if (f) { this.onLogin = f; }
		else { this.onLogin = function () {}; }
		__Yur.operatorBlende.showFull();
		$("Login").style.display = "inline";
		this.loginFocus();
	},
	
	loginFocus:		function () {
		try { $("loginForm").user_id.focus(); } catch(e) { /* Der IE kann keinem Element den Focus geben, wenn es unsichtbar ist... */}
	},
	
	resetPasswdFocus:	function () {
		try { $("resetPasswdForm").email.focus(); } catch(e) { /* Der IE kann keinem Element den Focus geben, wenn es unsichtbar ist... */}
	},
	
	hideLogin:		function () {
		if (__Yur.sitename != 'login') {
			if (this.requesting) return false;
			unlockButton($('loginBtn'));
			__Yur.operatorBlende.hide();
			this.hideResetPasswd();
			if (!__Yur.fullscreen) {
				var tp = $('ThumbPlayerContainer');
				if(tp) tp.style.visibility = 'visible';
			}
			$("Login").style.display = "none";
			return true;
		}
	},
	
	hideLoginFull:		function () {
		if (this.requesting) return false;
		unlockButton($('loginBtn'));
		__Yur.operatorBlende.hideFull();
		this.hideResetPasswd();
		$("Login").style.display = "none";
		return true;
	},
	
	
	showLogoutButton:	function () {
		if($("sessionLoggedInAlias")) {
			$("sessionLoggedInAlias").innerHTML = this.person.alias;
		}
		
		var loginobj      = new Yur.BO.Login();
		loginobj.fromData(this.person);
		loginobj.display();
	
		$("sessionLogin").style.display = "none";
		$("sessionLogout").style.display = "block";
		
	},
	
	hideLogoutButton:	function () {
		
		var logoutBtn = $("sessionLogout")
		var loginBtn  = $("sessionLogin")
	
		if(logoutBtn != null && loginBtn != null) {
			logoutBtn.style.display = "none";
			loginBtn.style.display = "block";
		}
	},
	
	showResetPasswd:	function () {
		if (__Yur.sitename != 'login') {
			$('LoginFrame').style.display = 'none';
			$('ResetPasswdFrame').style.display = 'block';
			this.resetPasswdFocus();
		}
	},

	hideResetPasswd:	function () {
	
			unlockButton($('resetBtn'));
			if (__Yur.sitename == 'login') {
				$('showpwvergessen').style.display = 'none';
			} else {
				$('ResetPasswdFrame').style.display = 'none';
				$('LoginFrame').style.display = 'block';
				this.loginFocus();
			}
		
	},
	
	resetPasswd_form:	function (form) {
		this.resetPasswd(form.email.value);
	},
	
	resetPasswd:		function (email) {
		if (this.reseting) return;
		var me = this;
		var fetcher = new Yur.API("session/reset/password", function (data) {
			me.reseting = false;
			if (data.success) {
				alert("Eine E-Mail mit weiteren Informationen wurde an Dich versendet.")
				location.href='/';
				//me.hideResetPasswd();
			} else {
				alert("Die angegebene E-Mail Adresse wurde im System nicht gefunden.")
			}
		}, function () {
			me.reseting = false;
		});
		fetcher.debug = this.options.debug_reset_passwd;
		fetcher.post({
			email:  email
		});
		this.reseting = true;
	},
	
	showRegisterpage:	function () {
		location.href='/register/step1';
	},
	
	showLoginPage:	function () {
		location.href='/login';
	}
}


// ##########################
// File: /storage/www/yur/www/lib/Yur/TV/Tag.js
// ##########################
Yur_setUpNamespace(["Yur", "TV"])


Yur.TV.Tag = function(movie, queueItem) {
	this.movie = movie;
	this.queueItem = queueItem;
	this.state = "closed";
	
	this.initInputField();
}


Yur.TV.Tag.prototype = {

	submitData:	function () {
		if (this.inputField().value == "") return;
		me = this;
		var fetcher = new Yur.API("tag_movie_save", function (data) { me.dataReceived(data); })
		fetcher.get({
			movie:      this.movie,
			tag_string: this.inputField().value
		});
		this.inputField().value = "";
	},

	initInputField:	function() {
		var me = this;
		this.inputField().onkeypress = function(e) {
			var keynum;
			if (window.event) { keynum = e.keyCode } else { keynum = e.which }
			//alert(keynum);
			if (keynum == 13) me.submitData();
		};
	},

	dataReceived: function () {
		this.hide();
	},

	inputField:	function () {
		return $('tagInput' + this.queueItem);
	},

	show: function () {
		if (this.state != "closed") return;
		$('movieTextContainer' + this.queueItem).style.display = "none";
		$('movieTagContainer' + this.queueItem).style.display = "block";
		__Yur.freeze(this);
		this.state = "open";
	},
	
	hide: function () {
		if (this.state != "open") return;
		$('movieTagContainer' + this.queueItem).style.display = "none";
		$('movieTextContainer' + this.queueItem).style.display = "block";
		__Yur.unfreeze(this);
		this.state = "closed";
	},
	
	focus: function () {
		this.inputField().focus();
	}
}

// ##########################
// File: /storage/www/yur/www/lib/Yur/TV/TellAFriend.js
// ##########################
Yur_setUpNamespace(["Yur", "TV"])

Yur.TV.TellAFriend = function() {}

Yur.TV.TellAFriend.prototype = {

	show:		function () {
		if (!__Yur.session.hideLogin()) return;
		__Yur.queue.hide();
		__Yur.gcontent.hide();
		__Yur.ranking.hide();
		__Yur.moviePreview.hide();
		__Yur.nav('operator').activate(2);
		__Yur.howTo.hide();
		$('TellAFriend').style.display = 'block';
	},
	
	showOK:		function () {
		$('TellAFriendOK').style.display = 'block';
	},	

	hide:			function () {
		if (__Yur.sitename == 'homepage') {
			$('TellAFriend').style.display = 'none';
			$('TellAFriendOK').style.display = 'none';
			$('addact1').style.display = '';
			$('addin1').style.display = 'none';
			$('anzahl').value = 1;
			$('deinname').value = '';
			$('deineemail').value = '';
			$('email1').value = '';
			$('name1').value = '';
			$('nachricht').value = '';

			this.hideAdress(2);
			this.hideAdress(3);
			this.hideAdress(4);
			this.hideAdress(5);
			this.hideAdress(6);
			this.hideAdress(7);
			this.hideAdress(8);
			this.hideAdress(9);
		 }
	},
	
	hideAdress:			function (nr) {
		var obj = $('adress'+nr);
		obj.innerHTML='';
		obj.style.display='none'; 
	},	
	
	addAdress: function (nr) {
		$('anzahl').value = nr;
		var obj = $('adress'+nr);
		var nextnr = nr;
		if (nr == '2') {nextnr = '3'}
		if (nr == '3') {nextnr = '4'}
		if (nr == '4') {nextnr = '5'}
		if (nr == '5') {nextnr = '6'}
		if (nr == '6') {nextnr = '7'}
		if (nr == '7') {nextnr = '8'}
		if (nr == '8') {nextnr = '9'}
		if (nr == '9') {nextnr = '9'}
		
		obj.style.display='';
		obj.innerHTML =	'<div style="padding-left:8px;">'
														+'<table cellspacing="0" cellpadding="0" border="0">'
															+'<tr>'
																+'<td colspan="3" height="7"><img src="pics/t.gif" width="1" height="1"></td>'
															+'</tr>'
															+'<tr>'
																+'<td width="156" class="bigtext" align="left">Name des Empf&auml;ngers <span class="smalltext">('+nr+')</span>:</td>'
																+'<td width="136"><input class="boxtext" id="name'+nr+'" name="name'+nr+'" type="text" style="width:130px;"></td>'
																+'<td width="25" align="center">&nbsp;</td>'
															+'</tr>'
															+'<tr>'
																+'<td colspan="3" height="4"><img src="pics/t.gif" width="1" height="1"></td>'
															+'</tr>'
															+'<tr>'
																+'<td width="156" class="bigtext" align="left">E-Mail des Empf&auml;ngers <span class="smalltext">('+nr+')</span>:</td>'
																+'<td width="136"><input class="boxtext" id="email'+nr+'" name="email'+nr+'" type="text" style="width:130px;"></td>'
																+'<td width="25" align="center"><a href="javascript:__Yur.tellAFriend.addAdress('+nextnr+'); hide(\'addact'+nr+'\'); show(\'addin'+nr+'\');"><img id="addact'+nr+'" src="pics/add_act.gif" border="0" /></a><img style="display:none" id="addin'+nr+'" src="pics/add_in.gif" border="0" /></td>'
															+'</tr>'
															+'<tr>'
																+'<td colspan="3" height="7"><img src="pics/t.gif" width="1" height="1"></td>'
															+'</tr>'
														+'</table>'														
													+'</div>'
													+'<div class="line"><img src="pics/t.gif" width="1" height="1"></div>';
	},
	
	send:	function () {
	
		var paras = {};
		var anzahl = $('anzahl').value;
		var counter = 1;
		
		var f = $('tellafriendform');
		var error ='';
	
		error = validateForm(f, "deinname", "Dein Name", "R", "deineemail", "Deine E-Mail", "REmail");
		if (error != '') {
			publishError(error);
		}
	
		while (counter <= anzahl && error == '') {
		
			error = validateForm(f, "name"+counter, "Name ("+counter+")", "R", "email"+counter, "E-Mail ("+counter+")", "REmail");
			if (error != '') {
				publishError(error);
			}
				
			paras["name"+counter] = $('name'+counter).value;
			paras["email"+counter] = $('email'+counter).value;
			counter++;
		}
		
		if (error == '') {
		
			paras["anzahl"] = anzahl;
			paras["deinname"] = $('deinname').value;
			paras["deineemail"] = $('deineemail').value;
			paras["nachricht"] = $('nachricht').value;

		 	var me = this;
			var fetcher = new Yur.API("tellafriend/send", function (data) { me.sendDataReceived(data); })
			fetcher.cached = false;
			fetcher.setCacheIntervalSeconds(0);
			fetcher.debug = false;
			fetcher.get(paras);
		}
	},
	
	sendDataReceived:	function (data) {
		this.hide();
		this.showOK();
	}
	
}


// ##########################
// File: /storage/www/yur/www/lib/Yur/TV/Voting.js
// ##########################
Yur_setUpNamespace(["Yur", "TV"]);




Yur.TV.Voting = function (id, movie, voting) {

	this.name = 'voteQueue';

	this.id = id;
	this.movie = movie;

	this.data = voting;

	this.options = {
		darf_vote: true,
		bar_width: 20,
		bar_steps: 5,
		scores: [-2,-1,0,1,2]
	}

	this.state = "closed";
}

Yur.TV.Voting.prototype = {
	
	remove:          function () {
		if (this.state == "open") this.close();
	},

	darfVoten:    function () {
		if (!this.options.darf_vote) return false;
		return __Yur.darfVoten(this.movie);
	},

	vote:      function (score) {
		if (!this.darfVoten()) return;
		var me = this;
		
		//urchinTracker("/vote/preview");

		var vote = new Yur.BO.Vote(this.movie, score);
		vote.onSuccess = function (data) { me.saveResult(data) };
		vote.submitData();

		__Yur.votes.insert(this.movie);
		this.options.darf_vote = false;
		this.options.darf_vote = true;
		this.close();
	},
	
	voteMax: function () {
		this.vote(2)
	},
	
	voteMin: function () {
		this.vote(-2)
	},
	
	saveResult:		function (data) {
		if (data.voting && (this.data == null || (this.data != null && this.data.timestamp < data.voting.timestamp))) {
			this.data = data.voting;
			this.update();
		}
	},
	
	open:           function () {
		if (this.state != "closed" || !this.darfVoten()) return;
		$LOG("ACTION: open");
		__Yur.freeze(this);
		$(this.name + 'Anzeige' + this.id).style.display = 'none';
		$(this.name + 'Edit' + this.id).style.display = 'block';
		this.state = "open";
	},
	
	close:          function () {
		if (this.state != "open") return;
		$LOG("ACTION: close");
		$(this.name + 'Anzeige' + this.id).style.display = 'block';
		$(this.name + 'Edit' + this.id).style.display = 'none';
		__Yur.unfreeze(this);
		this.state = "closed";
	},

	update:         function () {
		$LOG("Summe: "+this.data.sum+"  Count: "+this.data.count+"  Score: "+this.data.result);
	
		/*$(this.name + "Zeiger" + this.id).style.left = this.data.zeiger_position_queue + "px";
		$(this.name + "Text" + this.id).innerHTML = this._voteText();
		*/
	},

	_voteText: function () {
		var str = "" + this.data.count + " Vote";
		if (this.data.count != 1) str += "s";
		return str;
	},

	bar_mousemove:		function (e) {
		var pos;
		if ((pos = e.layerX) == null) pos = e.x;
		
		this.moveRegler(pos-4); // Minus 4, weil das TouchPad 4 Pixel weiter links als die Bar beginnt
	},

	bar_click:		function (e) {
		var pos;
		if ((pos = e.layerX) == null) pos = e.x;

		this.vote(this.options.scores[this._Pixel2Step(pos)]);
	},
	
	moveRegler:		function (x) {
		
		var step_size = this.options.bar_width / (this.options.bar_steps - 1);
		var step = this._Pixel2Step(x);

		$(this.name + "Regler" + this.id).style.left = Math.round(step * step_size) + "px";
	},
	
	_Pixel2Step:		function (x) {
		if (x > this.options.bar_width) x = this.options.bar_width
		else if (x < 0) x = 0;

		var parts = (this.options.bar_steps - 1) * 2;
		var half_step_size = this.options.bar_width / parts;
		
		x -= (x % half_step_size);
		
		var step = Math.round(x / half_step_size);
		if (step % 2) step++;

		return Math.round(step / 2);
	}
}





// ##########################
// File: /storage/www/yur/www/lib/Yur/TV/Voting/Abstract.js
// ##########################
Yur_setUpNamespace(["Yur", "TV", "Voting"]);

Yur.TV.Voting.Abstract = function () {

	this.name = 'voteGongShow';

	this.movie   = null;
	this.airtime = null;
	this.vote_result = 0;
	this.is_visible = 0;
	this.div_name = "abstract_box";

	this.options = {
		max_score: 2,
		min_score: -2
	};
}

Yur.TV.Voting.Abstract.prototype = {

	setMovie:		function (movie, voting, airtime) {
		if (this.movie != movie) {
			this.movie   = movie;
			this.voting  = voting;
			this.airtime = airtime
			this.reset_vote(movie);
		} else if (voting != null && (this.voting == null || this.voting.timestamp < voting.timestamp)) {
			this.voting = voting;
		}

		this.update();
	},

	vote:      function (score) {
		var me = this;

		var vote = new Yur.BO.Vote.GongShow(this.movie, score);
		vote.onSuccess = function (data) { me.saveResult(data) };
		vote.onFailure = function () {};
		vote.submitData();
	},

	saveResult:		function (data) {
		$LOG("Voting result:")
		if (!data || !data.voting || data.movie != this.movie) {
			return;
		}

		if (this.voting == null || (this.voting != null && this.voting.timestamp < data.voting.timestamp)) {
			this.voting = data.voting;
			this.update();
		}
	},

	update:         function () { },

	vote_good:		function () {
		this.vote(this.options.max_score);
		this.vote_result = this.options.max_score;
		__Yur.adver.click();
		window.urchinTracker("/vote/gongshow/top");
	},
	
	vote_sucks:		function () {
		this.vote(this.options.min_score);
		this.vote_result = this.options.min_score;
		__Yur.adver.click();
		window.urchinTracker("/vote/gongshow/flop");
	},
	
	reset_vote: function (movie) {},
	
	hide: function () {
		var o = $(this.div_name);
		if (!o) return;
		$(this.div_name).style.display = 'none';
		this.is_visible = 0;
	},
	
	show: function () {
		//alert(this.div_name);
		var o = $(this.div_name);
		if (!o) return;
		$(this.div_name).style.display = 'block';
		this.is_visible = 1;
		
	},	
	
	update_buttons:	function () {}
	
}


// ##########################
// File: /storage/www/yur/www/lib/Yur/TV/Voting/GongShow.js
// ##########################
Yur_setUpNamespace(["Yur", "TV", "Voting"]);

Yur.TV.Voting.GongShow = function () {

	this.name = 'voteGongShow';
	this.div_name = "gonshow_box";
	this.movie   = null;
	this.airtime = null;
	this.vote_result = 0;
	this.is_visible = 0;
	
	this.options = {
		max_score: 2,
		min_score: -2
	};
}

Yur.TV.Voting.GongShow.prototype = {


	update:         function () {
		var zeiger_pos = 0;
		if (this.voting) {
			zeiger_pos = this.voting.zeiger_position_gongshow;
		}
		if($('BarResult')) {
			$('BarResult').innerHTML = '<img src="/pics/shared/gongshow/'+ zeiger_pos +'.gif" alt="Flop" name="gongshowresult" width="177" height="19" border="0" id="gongshowresult" />';
		}

		this.update_buttons();
	},

	
	reset_vote: function (movie) {
		var me = this;
		var vote = new Yur.BO.Vote.GongShowResult(movie);
		vote.onSuccess = function (data) { me.vote_result = data.result; me.update_buttons();};
		vote.onFailure = function () {};
		vote.submitData();
	},
	
	update_buttons:	function () {
		if (!$(this.name + "BtnBleibtImgAct")) return; // Keine Ahnung wo, aber irgendwo giebt es diese Button halt nicht ...
		if (this.vote_result == 0) {
			$(this.name + "BtnBleibtImgAct").style.display = 'block';
			$(this.name + "BtnRausImgAct").style.display = 'block';	
			$(this.name + "BtnBleibtImgDef").style.display = 'none';
			$(this.name + "BtnRausImgDef").style.display = 'none';
		} else if (this.vote_result == this.options.max_score) {
			$(this.name + "BtnBleibtImgAct").style.display = 'none';
			$(this.name + "BtnRausImgAct").style.display = 'block';	
			$(this.name + "BtnBleibtImgDef").style.display = 'block';
			$(this.name + "BtnRausImgDef").style.display = 'none';
		} else if (this.vote_result == this.options.min_score) {
			$(this.name + "BtnBleibtImgAct").style.display = 'block';
			$(this.name + "BtnRausImgAct").style.display = 'none';	
			$(this.name + "BtnBleibtImgDef").style.display = 'none';
			$(this.name + "BtnRausImgDef").style.display = 'block';
		}		
	}
	
}

Yur.inherit(Yur.TV.Voting.Abstract, Yur.TV.Voting.GongShow)

// ##########################
// File: /storage/www/yur/www/lib/Yur/TV/Voting/HotOrNot.js
// ##########################
Yur_setUpNamespace(["Yur", "TV", "Voting"]);

Yur.TV.Voting.HotOrNot = function () {

	this.name = 'voteHotOrNot';
	this.div_name = "hot_or_not_box";
	this.movie   = null;
	this.airtime = null;
	this.vote_result = 0;
	this.is_visible = 0;

	this.options = {
		max_score: 5,
		min_score: -4
	};
}

Yur.TV.Voting.HotOrNot.prototype = {

	voteAndChange:	function(vote, obj) {
		this.vote(vote);
	}

	/*update:		function () {
		
	},
	
	reset_vote: function (movie) {
		var me = this;
		
	},
	*/
}

Yur.inherit(Yur.TV.Voting.Abstract, Yur.TV.Voting.HotOrNot)

// ##########################
// File: /storage/www/yur/www/lib/Yur/TV/Voting/VoteBefor.js
// ##########################
Yur_setUpNamespace(["Yur", "TV", "Voting"]);




Yur.TV.Voting.VoteBefor = function () {

	this.name = 'voteGongShow';

	this.movie   = null;
	this.waiting = false;
	this.airtime = null;

	this.timeout = null;

	this.options = {
		max_score: 2,
		min_score: -2,
		bar_width: 308, /* Der 1 Pixel breite dunkle Balken in der Mitte der Bar wird nicht mitgezŠhlt! */
		bar_width_fullscreen: 102
	};
}

Yur.TV.Voting.VoteBefor.prototype = {

	setMovie:		function (movie, voting, airtime) {
		if (this.movie != movie) {
			this.movie   = movie;
			this.voting  = voting;
			this.airtime = airtime
			this.setWaiting(false);
		} else if (voting != null && (this.voting == null || this.voting.timestamp < voting.timestamp)) {
			this.voting = voting;
		}

		this.update();
	},

	darfVoten:    function () {
		$LOG("Voting: "+this.waiting+(this.movie != null))
		return (!this.waiting && this.movie != null);
	},

	vote:      function (score) {
		if (!this.darfVoten()) return;
		this.setWaiting(true);
		var me = this;
		$('voteoff').style.display='block';
		var vote = new Yur.BO.Vote(this.movie, score);
		vote.onSuccess = function (data) { me.saveResult(data) };
		vote.onFailure = function () { 
			//me.setWaiting(false);
			$('voteoff').style.display='none' 
		};
		vote.submitData();
	},

	saveResult:		function (data) {
		$LOG("Voting result:")
		if (!data || !data.voting || data.movie != this.movie) {
			return;
		}

		if (this.voting == null || (this.voting != null && this.voting.timestamp < data.voting.timestamp)) {
			this.voting = data.voting;
			this.update();
		}

		this.delay = data.delay;
		if (data.delay) {
			var me = this;
			var delay = new Number(data.delay);
			$LOG("Voting: Setting Timeout");
			//this.timeout = setTimeout(function () { me.setWaiting(false) }, delay * 1000); // delay kommt in Sekunden
		}
	},

	update:         function () {
		var bar_width = this.options.bar_width;
		
		var zeiger_pos;
		if (this.voting) {
			zeiger_pos = this.voting.zeiger_position_gongshow;
		}
		if (__Yur.sitename == 'fullscreen') {
			bar_width = this.options.bar_width_fullscreen;
			if (this.voting) {
				zeiger_pos = this.voting.zeiger_position_gongshow_fullscreen;
			}
		}
		var middle = Math.round(bar_width / 2);
	
		var pos = middle;
		if (this.voting && zeiger_pos != null) {
			pos =  zeiger_pos
			if (pos > bar_width) pos = bar_width
			else if (pos < 0) pos = 0;
		}

		var size = pos - middle;
		
		if (size < 0) {
			$(this.name + 'BarBleibt').style.display = 'none';
			$(this.name + 'BarBleibt').style.width = '0px';
			$(this.name + 'BarRaus').style.width = (size*-1) + 'px';
			$(this.name + 'BarRaus').style.display = 'block';
		} else if (size > 0) {
			$(this.name + 'BarRaus').style.display = 'none';
			$(this.name + 'BarRaus').style.width = '0px';
			$(this.name + 'BarBleibt').style.width = size + 'px';
			$(this.name + 'BarBleibt').style.display = 'block';
		} else {
			$(this.name + 'BarRaus').style.display = 'none';
			$(this.name + 'BarBleibt').style.display = 'none';
		}
		
		return size;
	},

	setWaiting:		function (waiting) {
		$LOG("Voting: Waiting="+waiting)
		this.waiting = waiting;
		if(!waiting && this.timeout != null) {
			clearTimeout(this.timeout);
			this.timeout = null;
		}
		this.update_buttons();
	},
	
	vote_good:		function () {
		this.vote(this.options.max_score);
		
		
		__Yur.adver.click();
		window.urchinTracker("/vote/gongshow/top");
	},
	
	vote_sucks:		function () {
		this.vote(this.options.min_score);
		
		__Yur.adver.click();
		window.urchinTracker("/vote/gongshow/flop");
	},
	
	update_buttons:	function () {
		var vis = 'block';
		if (this.waiting || this.movie == null) {
			vis = 'none'
		}
		else {
			this.onmouseout();
		}
		$(this.name + "BtnBleibt").style.display = vis;
		$(this.name + "BtnRaus").style.display = vis;
	},
	
	onmouseover:	function (where) {
		if (!this.darfVoten()) return;
		var theOther = 'Bleibt';
		if (where == 'Bleibt') theOther = 'Raus';
		$(this.name + "Btn" + where + "ImgDef").style.display = 'none';
		$(this.name + "Btn" + where + "ImgAct").style.display = 'block';
		$(this.name + "Btn" + theOther + "ImgAct").style.display = 'none';
		$(this.name + "Btn" + theOther + "ImgDef").style.display = 'block';
	},
	
	onmouseout:		function () {
		if (!this.darfVoten()) return;
		$(this.name + "BtnBleibtImgAct").style.display = 'none';
		$(this.name + "BtnBleibtImgDef").style.display = 'block';
		$(this.name + "BtnRausImgAct").style.display = 'none';
		$(this.name + "BtnRausImgDef").style.display = 'block';
	}
		
}




