function showDiv( id ) {

    document.getElementById( id ).style.visibility = "visible";

}

function hideDiv( id ) {

    document.getElementById( id ).style.visibility = "hidden";

}

var timer;

function scrLeft( id, inc, max ) {

    var hpos = parseInt(document.getElementById( id ).style.left);
    if ( hpos > max ) {

        hpos -= inc;
        document.getElementById( id ).style.left = hpos + "px";

    }

}

function scrRight( id, inc, max ) {

    var hpos = parseInt(document.getElementById( id ).style.left);
    if ( hpos < max ) {

        hpos += inc;
        document.getElementById( id ).style.left = hpos + "px";

    }

}

function startScrLeft( id, inc, speed, max ) {

    timer = setInterval( "scrLeft('" + id + "'," + inc + "," + max + ")", speed );

}

function startScrRight( id, inc, speed, max ) {

    timer = setInterval( "scrRight('" + id + "'," + inc + "," + max + ")", speed );

}

function stopScr() {

    clearInterval( timer );

}


