// Breite des Tickers
var ntv_height = 300;
// Grössere Zahlen -> langsamer
var ntv_speed = 20;
var ntv_step = 1;
// Positionsangaben des Tickers
var posLeftV = 0;
var posRightV = 0;
var posTopV = 0;
var posBottomV = 0;
// Content aus Datenbank holen
var ntv_content = '
---
Neu ! Neu!
Von Montag bis Freitag Degustationsmenü im Weinberg mit den passenden Weinen!
* * *
Unser Tagesmenü
--- ';
var ntv_textheight = 0
var ntv_timer = 0;
var ntv_clipleft = 0;
var ntv_clipright = 0;
var ntv_cliptop = 0;
var ntv_clipbottom = 15;
var ntv_dom = document.all || document.getElementById;
var ntv_actualtop = 0;
function fctSetContentVertical(p_leftv, p_topv, p_widthv, p_heightv)
{
posLeftV = p_leftv;
posRightV = posLeftV + p_widthv;
posTopV = 0;
posBottomV = p_heightv;
ntv_width = p_widthv;
ntv_clipbottom = p_heightv;
if(ntv_dom)
{
document.getElementById("eu_ntContentVertical").innerHTML = ntv_content;
document.getElementById("eu_ntContentVertical").style.top = posBottomV + "px";
ntv_actualtop = posBottomV;
}
else
{
document.eu_ntContentVertical.document.write(''+ntv_content);
document.eu_ntContentVertical.document.close();
ntv_textwidth = document.eu_ntContentVertical.document.height;
document.eu_ntContentVertical.top = posBottomV;
}
if(document.all)
{
ntv_speed = 20;
}
else
{
ntv_speed = 40;
}
setInterval( "fctScrollVertical()", ntv_speed );
}
function fctScrollVertical()
{
if(ntv_dom)
{
if(document.all)
{
ntv_textheight = document.getElementById("eu_ntContentVertical").scrollHeight;
}
else
{
ntv_textheight = document.getElementById("eu_ntContentVertical").offsetHeight;
}
if (ntv_actualtop >= posTopV - ntv_textheight)
{
ntv_actualtop -= ntv_step;
document.getElementById("eu_ntContentVertical").style.top = ntv_actualtop + "px";
}
else
{
document.getElementById("eu_ntContentVertical").style.top = posBottomV + "px";
ntv_actualtop = posBottomV;
}
}
else
{
if (document.eu_ntContentVertical.top >= posTopV - ntv_textheight)
{
document.eu_ntContentVertical.top -= ntv_step;
document.eu_ntContentVertical.clip.bottom += ntv_step;
if (document.eu_ntContentVertical.clip.top > ntv_height)
{
document.eu_ntContentVertical.clip.bottom += ntv_height;
}
var ntv_timer=setTimeout("fctScrollVertical()",ntv_speed);
}
else
{
document.eu_ntContentVertical.top = posBottomV;
document.eu_ntContentVertical.clip.top = 0;
document.eu_ntContentVertical.clip.bottom = 0;
fctScrollVertical();
}
}
}