Why JavaScript?

Skip to main content
The weather portion of this website updates itself with current information every 15 minutes, around the clock.

The current and historical web pages consist of 8 HTML text files. The clickable portions of these pages require another 14 HTML text files, for a total of 22 essentially static files, with only the current data ever changing.

Updating and uploading all of these files every 15 minutes wasted a lot of time and bandwidth. So, we modified these 22 files to all load and run one Javascript file, called "Data.txt". This file plows through the currently-displayed HTML file looking for specially-marked text fields (like "outsideDewPt"), and populates those fields with its current data; it's also responsible for some "special effects", like the text strikethough when the wind chill and heat index (which Davis' software _always_ generates, no matter what) are actually invalid.

By using "Data.txt", in addition to files called "CurrentTicker.txt" and "HistoricTicker.txt" that supply the data for the "current" and "highs/lows" at the top of most pages, we reduce the number of HTML text files which much be updated every 15 minutes from 25 to 3, and reduce the total upload size of these text files from over 100KB to under 21KB.

Please note that clicking on either the Davis logo or the "Click here for..." at the top of any main page (normally redirecting you to Davis' website or the indicated text, respectively) also won't work with JavaScript disabled (as we use "onclick=" for each area).

Thanks for your interest in why we do what we do. Use this "comments welcome!" link (or the one on the bottom of any of our main pages) if you'd like more information.

Valid html 4.01 Transitional Valid CSS W3C WAI Accessibility 2.0, Triple-A conformance WE are FlashFREE Viewable With Any Browser