Я постоянно получаю непойманные синтаксис ошибка: неверный или неизвестный элемент в HTML код.
Я не понимаю, что мне нужно здесь делать, нужна помощь в этом для моего научного финала, если я этого не сделаю, то потерплю неудачу...
<html> <head> h2{ text-align:center } <h2>Rainfall Predictor </h2> <title> Rainfall </title> var AirTemp var DewPoint var WindVelocity var AirPressure var Trend var Ratio var HourlyRain var TrendPick var DayTotal var StormPeriod // prediction engine function GetTrend(){ TrendPick = document.forms.f.Trend.selectedIndex; return } function compute() { // calculate DewPoint/AirTemp ratio Ratio = document.forms.f.DewPoint.value/document.forms.f.AirTemp.value; Ratio = parseFloat(Ratio).toFixed(2); StormPeriod= 62.5/(document.forms.f.WindVelocity.value*1.852); //precipatation hours s time storm to travel 62.5 km // assumption is made that typical storm cell or band is 100km or 62.5 miles wide if (Ratio < 0.86) //0.86 is lower limit of dewpoint/air temperature curves { Ratio = 0.86; } // students create code here to limit the Ration from being more than 1.0 if (TrendPick==1){ // calculate hourly rainfall steady barometer HourlyRain=(); // students fill in the function between the () HourlyRain=parseFloat(HourlyRain).toFixed(2); DayTotal = HourlyRain*StormPeriod; document.forms.f.DayRate.value = DayTotal; } else if (TrendPick==2){ // calculate hourly rainfall rising barometer HourlyRain = (2.5725*Math.pow(Ratio,2)-(4.433*Ratio) +1.9106); HourlyRain =parseFloat(HourlyRain).toFixed(2); DayTotal = HourlyRain*StormPeriod; document.forms.f.DayRate.value = DayTotal; } else if (TrendPick==3){ // calculate hourly rainfall falling barometer HourlyRain = (1.797*Math.pow(Ratio,20.356)); HourlyRain = parseFloat(HourlyRain).toFixed(2); DayTotal = HourlyRain*StormPeriod; document.forms.f.DayRate.value = DayTotal; } else{ } //document.write ('DewPoint/Temp ='+ Ratio); //document.write(" "); //document.write(' Hourly rainfall = '+ HourlyRain); //document.write ('TrendPick= '+TrendPick); document.forms.f.HourRate.value = 'Hourly rate(in./hr.) = '+HourlyRain; document.forms.f.DayRate.value = 'Day total (in.) = ' + DayTotal; } <div align="center"> <table><tbody><tr><td> Enter Air Temperature Degrees C </td></tr><tr><td> Enter Dew Point Degrees C </td></tr><tr><td>Enter Wind Velocity Knots </td></tr><tr><td>Enter Air Pressure Millibars </td></tr><tr><td>Choose Air Pressure Trend Choose Steady Rising Falling </td></tr><tr></tr><tr><td> </td></tr></tbody></table> </div>
Что я уже пробовал:
вот на чем он говорит нам сосредоточиться
// students create code here to limit the Ration from being more than 1.0 if (TrendPick==1){ // calculate hourly rainfall steady barometer HourlyRain=(); // students fill in the function between the ()