
/**********************************************************************
This script is made by and copyrighted to Thomas Brattli
at www.bratta.com and may be used freely as long as this 
message is left intact.
Visit www.bratta.com for more great scripts.
**********************************************************************/

//Set these variables:

//The pixel value of where you want the layer to start (from the top)
lstart=350

//Set this to false if you just want it to go one time
loop=true 

//Set the speed, lower value gives more speed
speed=100

//Set this to how many pixels you want it to go for each step, this also changes the speed.    
pr_step=5
	
/**********************************************************************
You don't have to change anything below this
**********************************************************************/

//Browsercheck
	var n = (document.layers) ? 1:0;
	var ie = (document.all) ? 1:0;

//Object constructor
function makeObj(obj,nest){
    nest=(!nest) ? '':'document.'+nest+'.'
    this.css=(n) ? eval(nest+'document.'+obj):eval(obj+'.style')
	this.scrollHeight=n?this.css.document.height:eval(obj+'.offsetHeight')
	this.up=goUp
    this.obj = obj + "Object"
    eval(this.obj + "=this")
    return this
}
//Makes the layer slide up
function goUp(speed){
	if(parseInt(this.css.top)>-this.scrollHeight){
		this.css.top=parseInt(this.css.top)-pr_step
		setTimeout(this.obj+".up("+speed+")",speed)
	}else if(loop) {
		this.css.top=lstart
		eval(this.obj+".up("+speed+")")
	  }
}
//Calls the object constructor,makes the slide object and starts the sliding.
	function slideInit(){
		oSlide=makeObj('divNews','divCont')
		oSlide.css.top=lstart
		oSlide.up(speed)
		
	}


// DHTML NAVIGATION ROLLOVERS

 if (document.layers)
     var doc = 'document.', vis = '.visibility';
 if (document.all)
    var doc = 'document.all.', vis = '.style.visibility';

 function show(object) {
     if (document.layers || document.all)
         eval(doc + object + vis + ' = "visible"');
 }

 function hide(object) {
     if (document.layers || document.all)
         eval(doc + object + vis + ' = "hidden"');
 }

 function hideAll() {
     hide('image1c');
     hide('image1p');
     hide('image1sp');
     hide('image1es');
     hide('image1n');
     hide('image1e');

     hide('image2c');
     hide('image2p');
     hide('image2sp');
     hide('image2es');
     hide('image2n');
     hide('image2e');

 }
