// JavaScript Document
var timerID = 0;
var which = 0;
var rotate_time = 3250;
function write_buttons()
{
document.getElementById('buttons').innerHTML = '';
}
function start(type) {
if(type == 'click' && timerID < 1)
{
which += 1;
rotate_story();
timerID = setTimeout('start("continue")', rotate_time);
//write the stop button
document.getElementById('stop_play').innerHTML = '
';
}
else if(type == 'start' || type == 'continue' )
{
if(type == 'continue')
{
which += 1;
}
rotate_story();
timerID = setTimeout('start("continue")', rotate_time);
//write the play button
//document.getElementById('stop_play').innerHTML = '
';
}
}
function stop() {
if(timerID) {
clearTimeout(timerID);
timerID = 0;
}
//write the play button
document.getElementById('stop_play').innerHTML = '
';
}
function next(){
stop();
which += 1;
rotate_story();
}
function previous(){
stop();
//which = which - 1;
which -= 1;
rotate_story();
}
function rotate_story() {
var story = new Array();
// the stories
story[0] = '
Bethel will host the last of three lectures in the Colloquia Lecture Series this semester on Friday, Apr. 9 at 4...
'; story[1] = 'In his 12th season as the head women’s basketball coach at Bethel College, Jody Martinez won his 300th game...
'; story[2] = 'Bethel College will host “Lectures in Philosophy” on Mar. 23 and 24, lead by Michael Rea, Ph.D., professor...
'; story[3] = 'Bethel College will present the spring Jazz and Percussion Night Apr. 16 at 7:30 p.m. in the Everest-Rohrer Chapel/Fine...
'; story[4] = 'The Bethel College Chamber Orchestra and Chamber Ensembles will present time-honored classics and modern gems in...
'; story[5] = 'The Bethel College Adult Studies program in Elkhart will host a college/education fair in connection with the Bristol...
'; story[6] = 'For the second consecutive year, Bethel received recognition in the 2009 President’s Higher Education Community...
'; if(which > (story.length - 1) ) { which = 0; } else if(which < 0) { which = (story.length - 1); } document.getElementById('NewsScroll').innerHTML = story[which]; }