var w = window;
function openWin(url) {
w = open(url, "info", "width=640,height=505,toolbar=no,menubar=no");
w.focus();
}

var pages = 0;
var mot = 0;
var moto = 0;
var PageArea = 600;
var IntervalPoint = 100;
var max = 0;
var Timer;
var doneFlag=1;

function MoveAreaNext(){
if (moto<PageArea) {
mot-=IntervalPoint;
moto+=IntervalPoint;
if(mot < max){mot=0;moto=PageArea+1;}
if (document.all) {this.stage.style.pixelLeft = mot;}
if (!document.all && document.getElementById){
this.document.getElementById('stage').style.left = mot;
}
if (document.layers) {this.document.stage.left = mot;}

Timer = setTimeout('MoveAreaNext()', 100);
}else{doneFlag=1;clearTimeout(Timer)}

}

function MoveAreaBack(){
if (moto<PageArea) {
mot+=IntervalPoint;
moto+=IntervalPoint;
if(mot > 0){mot=max;moto=PageArea+1;}
if (document.all) {this.stage.style.pixelLeft = mot;}
if (!document.all && document.getElementById){
this.document.getElementById('stage').style.left = mot;
}
if (document.layers) {this.document.stage.left = mot;}

Timer = setTimeout('MoveAreaBack()', 100);
}else{doneFlag=1;clearTimeout(Timer)}
}

function scroller(move,pages){
max = -(PageArea*(pages-1));
if (doneFlag==1){
moto = 0;
doneFlag=0;
move? MoveAreaNext():MoveAreaBack();}
}

