if (rolloverunderline == 0) { var rp_rof = 'none';}
else {var rp_rof = 'underline';}
if (font_underline==1) { var rp_fu = 'underline';}
else {var rp_fu = 'none';}
if (fontbold==1) { var rp_fb = 'bold';}
else {var rp_fb = 'normal';}
if (zeitkursiv==1) { var dz_kur = 'italic';}
else {var dz_kur = 'none';}
function Lauf(name, id, ssp, itv)
{
  this.name     = name;
  this.id       = id;
  this.shiftBy  = ssp ? ssp : 1;
  this.interval = itv ? itv : 100;
  this.runId	= null;
  this.div = document.getElementById(id);
  var node = this.div.firstChild;
  var next;
  while (node)
  {
    next = node.nextSibling;
    if (node.nodeType == 3)
      this.div.removeChild(node);
    node = next;
  }
  this.left = 0;
  this.shiftLeftAt = this.div.firstChild.offsetWidth;
  this.div.style.height	= this.div.firstChild.offsetHeight;
  this.div.style.width = 2 * screen.availWidth;
  this.div.style.visibility = 'visible';
}

function startTicker()
{
  this.stop();
  this.left -= this.shiftBy;
  if (this.left <= -this.shiftLeftAt)
  {
    this.left = 0;
    this.div.appendChild(this.div.firstChild);
    this.shiftLeftAt = this.div.firstChild.offsetWidth;
  }
  this.div.style.left = (this.left + 'px');
  this.runId = setTimeout(this.name + '.start()', this.interval);
}

function stopTicker()
{
  if (this.runId)
    clearTimeout(this.runId);
  this.runId = null;
}

function changeTickerInterval(newinterval)
{
  if (typeof(newinterval) == 'string')
    newinterval =  parseInt('0' + newinterval, 10); 
  if (typeof(newinterval) == 'number' && newinterval > 0)
    this.interval = newinterval;
    this.stop();
    this.start();
}

Lauf.prototype.start = startTicker;
Lauf.prototype.stop = stopTicker;
Lauf.prototype.changeInterval = changeTickerInterval;

var ticker = null;
function go()
{
ticker = new Lauf('ticker', 'lb', 1, scrollspeed);
ticker.start();
}

document.open();
document.write('<style type=\"text/css\">');            
document.write('.h:link{color:'+fontcolor+';text-decoration:'+rp_fu+';font-weight:'+rp_fb+';font-family:'+font+';font-size:'+fontsize+'px;}'); 
document.write('.h:visited{color:'+fontcolor+';text-decoration:'+rp_fu+';font-weight:'+rp_fb+';font-family:'+font+';font-size:'+fontsize+'px;}'); 
document.write('.h:hover{color:'+rollovercolor+';text-decoration:'+rp_rof+';font-weight:'+rp_fb+';font-family:'+font+';font-size:'+fontsize+'px;}'); 
document.write('.h:active{color:'+fontcolor+';text-decoration:none;font-weight:'+rp_fb+';font-family:'+font+';font-size:'+fontsize+'px;}'); 
document.write('.tt{color:'+rollovercolor+';text-decoration:none;font-weight:'+rp_fb+';font-family:'+font+';font-size:'+fontsize+'px;}'); 
document.write('.zeit{color:'+fontcolor+';text-decoration:none;font-weight:none;font-style:'+dz_kur+';font-family:'+zeitfont+';font-size:'+zeitfontsize+'px;}'); 
document.write('.co{position:relative;height:'+tickerheight+';width:'+tickerwidth+'px;overflow:hidden;background-color:'+tickercolor+';}');
document.write('.ti{position:relative;visibility:hidden;border-width:0px;border-style:none;font-size:11px;font-weight:bold;width:'+tickerwidth+'px;height:'+tickerheight+';vertical-align:bottom;}'); 
document.write('</style>');
document.close();

var i;
temp = new Array();
var cnt = 2;

var show;
if (no >= 10) show = 10;
if (no < 0) show = 0; else show = no;
switch(tickerart)
 {
  case 3:
  var wwholemessage='<nobr>';
  for(i = 0; i < show; i++)
   {
    switch(zeitposition)
    {
    	case 2:
    	wwholemessage=wwholemessage+'<span class="zeit">'+zeitkapselung.slice(0,1)+ndt[i].slice(0,10)+zeitkapselung.slice(1,2)+' - '+'</span>';
    	break;
    	case 4:
    	wwholemessage=wwholemessage+'<span class="zeit">'+zeitkapselung.slice(0,1)+ndt[i]+zeitkapselung.slice(1,2)+' - '+'</span>';
    	break;
    }
    wwholemessage=wwholemessage+'<a class="h" href="'+nfn[i]+'" target="_blank">'+nh[i];
    wwholemessage=wwholemessage+'</a>';
    switch(zeitposition)
    {
    	case 1:
    	wwholemessage=wwholemessage+'<span class="zeit">'+' - '+zeitkapselung.slice(0,1)+ndt[i].slice(0,16)+zeitkapselung.slice(1,2)+'</span>';
    	break;
    	case 3:
    	wwholemessage=wwholemessage+'<span class="zeit">'+' - '+zeitkapselung.slice(0,1)+ndt[i]+zeitkapselung.slice(1,2)+'</span>';
    	break;
    }
    wwholemessage=wwholemessage+'&nbsp;&nbsp;<span class="h">'+trenner+'</span>&nbsp;&nbsp;';
   }
  wwholemessage=wwholemessage+'</nobr>';
  document.open();
  document.write("<div align='left' class='co'>");
  document.write("<div class='ti' id='lb' onMouseOver='ticker.stop();' onMouseOut='ticker.start();'>");
  document.write("<nobr>");
  document.write(wwholemessage);
  document.write("</nobr>");
  document.write("</div>");
  document.write("</div>");
  document.close();
  go();
  break;
 }