//Free JavaScripts on http://www.ScriptBreaker.com
var speed = 10
var step = 5
var width = 277
var delay = 2000
var pointer = 0
var stop;
var offset

var newsarray = [
"<img src=\"photos/plane_small.gif\" width=\"64\"> Atlanta",
"<img src=\"photos/plane_small.gif\" width=\"64\"> Bangkok",
"<img src=\"photos/plane_small.gif\" width=\"64\"> Beijng",
"<img src=\"photos/plane_small.gif\" width=\"64\"> Buenos Aires",
"<img src=\"photos/plane_small.gif\" width=\"64\"> Capetown",
"<img src=\"photos/plane_small.gif\" width=\"64\"> Chili",
"<img src=\"photos/plane_small.gif\" width=\"64\"> Delhi",
"<img src=\"photos/plane_small.gif\" width=\"64\"> Dubai",
"<img src=\"photos/plane_small.gif\" width=\"64\"> Dublin",
"<img src=\"photos/plane_small.gif\" width=\"64\"> Guatemala",
"<img src=\"photos/plane_small.gif\" width=\"64\"> Hong Kong",
"<img src=\"photos/plane_small.gif\" width=\"64\"> Jakarta",
"<img src=\"photos/plane_small.gif\" width=\"64\"> Johannesburg",
"<img src=\"photos/plane_small.gif\" width=\"64\"> Kuala Lumpur",
"<img src=\"photos/plane_small.gif\" width=\"64\"> Los Angelos",
"<img src=\"photos/plane_small.gif\" width=\"64\"> Manilla",
"<img src=\"photos/plane_small.gif\" width=\"64\"> Mexico",
"<img src=\"photos/plane_small.gif\" width=\"64\"> Miami",
"<img src=\"photos/plane_small.gif\" width=\"64\"> Mumbai",
"<img src=\"photos/plane_small.gif\" width=\"64\"> New York",
"<img src=\"photos/plane_small.gif\" width=\"64\"> Oporto",
"<img src=\"photos/plane_small.gif\" width=\"64\"> Osaka",
"<img src=\"photos/plane_small.gif\" width=\"64\"> Sao Paulo",
"<img src=\"photos/plane_small.gif\" width=\"64\"> Seoul",
"<img src=\"photos/plane_small.gif\" width=\"64\"> Shanghai",
"<img src=\"photos/plane_small.gif\" width=\"64\"> Singapore",
"<img src=\"photos/plane_small.gif\" width=\"64\"> Taipei",
"<img src=\"photos/plane_small.gif\" width=\"64\"> Tel Aviv",
"<img src=\"photos/plane_small.gif\" width=\"64\"> Tokyo",
"<img src=\"photos/plane_small.gif\" width=\"64\"> Uruqua"
]

function pad(id,nr)
{
 document.getElementById(id).style.left=nr;
 nr-=step;
 if(nr < - offset) setText(id)
 else {
 if((nr < 5) &&(stop == false))  {stop=true;setTimeout("pad('"+id+"',"+nr+")",delay);}
 else setTimeout("pad('"+id+"',"+nr+")",speed);

 }
}
function setText(id)
{
  stop = false
  document.getElementById("context").innerHTML = newsarray[pointer];
  offset = document.getElementById("context").offsetWidth;
  pointer++;
  if(pointer >= newsarray.length) pointer = 0;
  pad(id,width);
}
