JavaScript with IE Browser

This script works beautifully on broswer platforms that are not IE. (even my blackberry). It is probably something that only needs another set of eyes.  Deadline is past so I am giving 500 points if you can solve it.
<SCRIPT>
 var tick;
 function stop() {
   clearTimeout(tick);
   }
 function simpleClock() {
  var yr = 2009;
var m = 9;
var d = 30;
var forecast = 17118000000; 
//change the text below to reflect your own,
var montharray=new Array("Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec");
var dayarray = new Array(31,28,31,39,31,30,31,31,30,31,30,31);
 
 
var today=new Date();
 
var todayy = today.getFullYear();
// getMonth is from 0 - 11
var todaym=today.getMonth() + 1 ;
var todayd=today.getDate();
 
 
var todayH=today.getHours();
hoursleft = 23 - todayH;
 
var todayMin=today.getMinutes();
minleft = 59 - todayMin;
 
///var todaystring=montharray[todaym]+" "+todayd+", "+todayy
var futurestring=montharray[m-1]+" "+d+", "+ yr;
// days left in this month
var daysleft = dayarray[todaym] - todayd;
 
//seconds left
var todays = 59 - today.getSeconds();
 
//days left in this year
for (var i=todaym; i<m; i++)
{
	daysleft = daysleft + dayarray[i];
}
 
// accounting for year differences
if (yr != todayy)
{
 daysleft = (31 + 28 + 31 + 30 + 31 + 30 + 31 + 31 + 30 + 31 + 30 + 31)*( yr - todayy);
}
 
//consider minutes left in current day
minutesleft = (daysleft*24*60) + (hoursleft*60) + minleft;
 
secondsleft = (minutesleft*60) + todays;
 
 
// forecast is a parameter
revenue = (forecast - ((1463 / 60)*secondsleft)).toFixed(2);
 
 
 
 
  
 
document.getElementById('days').innerHTML=daysleft;
document.getElementById('minutes').innerHTML=minutesleft;
document.getElementById('revenue').innerHTML=revenue;   
   document.getElementById('seconds').innerHTML=todays;
   tick=setTimeout("simpleClock()",1000);    
   }
</SCRIPT>

Open in new window

techguy20170Asked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Muhammad Ousama GhazaliSolution Analyst & ArchitectCommented:
1. use var revenue on line 57.
2. If days, minutes, revenue and seconds are textboxes, try using .value instead of innerHTML.
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
techguy20170Author Commented:
it was the "VAR" Missing.  Thanks.
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Web Browsers

From novice to tech pro — start learning today.