WXforum.net
June 19, 2013, 08:18:14 AM *
Welcome, Guest. Please login or register.

Login with username, password and session length
Members: 6695  •  Posts: 181366  •  Topics: 18410
Please welcome KD0RII, our newest member.
Welcome to the the new hosting for WXforum.net.
 
   Home   Help Search Login Register  
Pages: [1]   Go Down
  Print  
Author Topic: Can the day of the week name be expanded?  (Read 643 times)
0 Members and 1 Guest are viewing this topic.
dan43
Member
*
Offline Offline

Posts: 7



WWW
« on: March 26, 2010, 02:38:18 PM »

Hi there, I'm doing an experimental weather page for my Oregon Scientific WMR928 unit, and I've just put together a scrolling weather marquee on my page to print out how you would hear the current weather on a weather radio station, just for fun.  However, when it comes to displaying the 5-day forecast, each day is displaying as "Sun" for Sunday "Mon" for Monday, "Tue" for Tuesday and so on... is there a tag that will allow me to display the full name of the day of the week instead of shortforms?

Thanks,
Dan
Logged
Impala88
Senior Member
**
Offline Offline

Posts: 69



WWW
« Reply #1 on: March 26, 2010, 09:14:21 PM »

I used JavaScript to display the full day of the week name for my 5-day forecast.  You can try copying the below referenced tag and insert it into your .htx file in place of the tag.  You would have to modify it to suit your needs depending on where you will be using it.

<SCRIPT LANGUAGE="JavaScript">
<!--
var day="^forecast_day1_1^";
if (day=="Sun")
document.write ("Sunday");
//-->
</SCRIPT>
<SCRIPT LANGUAGE="JavaScript">
<!--
var day="^forecast_day1_1^";
if (day=="Mon")
document.write ("Monday");
//-->
</SCRIPT>
<SCRIPT LANGUAGE="JavaScript">
<!--
var day="^forecast_day1_1^";
if (day=="Tue")
document.write ("Tuesday");
//-->
</SCRIPT>
<SCRIPT LANGUAGE="JavaScript">
<!--
var day="^forecast_day1_1^";
if (day=="Wed")
document.write ("Wednesday");
//-->
</SCRIPT>
<SCRIPT LANGUAGE="JavaScript">
<!--
var day="^forecast_day1_1^";
if (day=="Thu")
document.write ("Thursday");
//-->
</SCRIPT>
<SCRIPT LANGUAGE="JavaScript">
<!--
var day="^forecast_day1_1^";
if (day=="Fri")
document.write ("Friday");
//-->
</SCRIPT>
<SCRIPT LANGUAGE="JavaScript">
<!--
var day="^forecast_day1_1^";
if (day=="Sat")
document.write ("Saturday");
//-->
</SCRIPT>
« Last Edit: March 26, 2010, 09:16:28 PM by Impala88 » Logged

dan43
Member
*
Offline Offline

Posts: 7



WWW
« Reply #2 on: April 01, 2010, 11:23:17 AM »

This could work Impala88, thanks very much... I'll see what I can do with it and if everything works out, I'll post the URL where I'm using it.

Cheers,
Dan
Logged
Pages: [1]   Go Up
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.18 | SMF © 2013, Simple Machines Valid XHTML 1.0! Valid CSS!
Page created in 0.116 seconds with 19 queries.