Weather Forecasts, Doppler Radar Reports and Weather
Weather Forecasts, Doppler Radar Reports and Weather
Weather Forecasts, Doppler Radar Reports and Weather
';
Element.update(container, htmlStr);
cnnShowCityMatches('cnnWeatherFindWeatherResultsPop');
function displayNoMatch(val)
var container='weatherLookup';
var htmlStr='
';
Element.update(container, htmlStr);
function urlEncode(str)
str=trimWS(str);
str=str.replace(/st./i,'saint');
str=str.replace(/mt./i,'mount');
str=escape(str);
return str;
function urlDecode(str)
return unescape(str);
function checkZip(str)
str=trimWS(str.toString());
return bool;
function trimWS(str)
str=str.replace(/,/g,' ');
str=str.replace(/^s*(S+)*s*$/,"$1");
str=str.replace(/(s1)s*/g,"$1");
return str;
function updateWithNewData(name,zip,locCode)
function getUSCities(selectB)
var validatorUrl='/weather/drillDown';
checkInput(qryArg,validatorUrl, validatorArgs,callBack);
function getInternationalCities(selectB)
var validatorUrl='/weather/drillDown';
checkInput(qryArg,validatorUrl, validatorArgs,callBack);
function getUSStates(selectB)
var validatorUrl='/weather/drillDown';
checkInput(qryArg,validatorUrl, validatorArgs,callBack);
function processUSRegions(selectB)
var validatorUrl='/weather/drillDown';
checkInput(qryArg,validatorUrl, validatorArgs,callBack);
function processInternationalCountries(options,idStr)
marker = document.getElementById("cnnWeatherStateBox");
marker.innerHTML = "";
div = document.createElement("div");
div.id = 'cnnDDWeatherState_wrap';
div.className = 'cnnPad8Top';
marker.appendChild( div );
form = document.createElement("form");
countrySelect = document.createElement("select");
countrySelect.className = "cnnWeatherStateOptions";
countrySelect.id = "cnnDDWeatherState_list";
opt = document.createElement("option");
opt.value = "0";
countrySelect.appendChild(opt);
processResponseAsSelect(countrySelect,options);
form.appendChild(countrySelect);
marker.appendChild(form);
countrySelect.onchange = function()
if(countrySelect.selectedIndex != 0)
getInternationalCities(countrySelect);
function doInternationalCountrySearch(selectB)
if(selectB.selectedIndex != 0)
var validatorUrl='/weather/drillDown';
checkInput(qryArg,validatorUrl, validatorArgs,callBack);
function processResponseAsSelect(ss,options)
for(i=0; i 0)
else
if(locations.length != 1) cnnShowCityMatches('cnnWeatherFindWeatherResultsPop');
//AjaxFunction
try
xmlHttp=new XMLHttpRequest();
xmlHttp=new ActiveXObject("Msxml2.XMLHTTP");
catch (e)
try
xmlHttp=new ActiveXObject("Microsoft.XMLHTTP");
catch (e)
return false;
if(url)
xmlHttp.open("GET",url,true);
if(fnc)
xmlHttp.onreadystatechange = fnc;
else
xmlHttp.send(null);
function showCityMatches(whichLayer)ie)
tipobj.style.visibility="visible";
// document.getElementById('cnnWeatherRegionBox').style.display="none";
// document.getElementById('cnnWeatherStateBox').style.display="none";
// document.getElementById('cnnWeatherCityBox').style.display="none";
// return false;
function hideCityMatches(whichLayer)ie)
tipobj.style.visibility="hidden";
Enter city name or zip code to get forecasts for cities around the world
http://weather.cnn.com/weather/forecast.jsp?zipCode=92602