Traditional Culture Encyclopedia - Weather forecast - Please add weather forecast code to the website
Please add weather forecast code to the website
The following paragraph is its source file
Tuesday 17:02 pm
var day = new Array("Sunday","Monday","Tuesday" , "Wednesday", "Thursday", "Friday", "Saturday");
function showDate()
{
font = document.getElementById( "dateFont");
var now = new Date();
var str = "";
var hours = now.getHours() + " ";
if(hours.length < 2)
{
hours = "0" + hours;
} p>
var minutes = now.getMinutes() + "";
if(minutes.length < 2)
{
minutes = " 0" + minutes;
}
var seconds = now.getSeconds() + "";
if(seconds.length < 2)
{
seconds = "0" + seconds;
}
str += "" + now.getFullYear() + "Year" + (now.getMonth() + 1) + "Month" + now.getDate() + "Day
" + day[now.getDay()] + " " + hours + ":" + minutes + ":" + seconds + "
";
font.innerHTML = str;
}
setInterval("showDate()" , 1000);
< /script>
Cloudy to showers? 25℃~34℃
< /td>

< /p>
I would like to recommend another code that displays different regions according to different IPs:
Try them all Bar
- Related articles
- A beautiful sentence for a circle of friends at the end of the working holiday.
- How to cancel the synchronization between Apple phone and ipad?
- Whispering that autumn insects are particularly loud, no matter how big the typhoon is, it is also weather.
- Why not eat more when the weather is hot?
- The weather in Zhangjiajie
- How to describe the cloudy weather in spring?
- What snacks are the hottest in summer stalls?
- How about Shenyang?
- It's really hot recently. What's a good word to describe the hot weather in summer?
- A book "The Fish King"