Author Topic: Issues in Customizing HTML Codes in WeatherLink  (Read 4225 times)

0 Members and 1 Guest are viewing this topic.

Offline ilee1

  • Member
  • *
  • Posts: 13
Issues in Customizing HTML Codes in WeatherLink
« on: July 17, 2007, 02:46:40 AM »
Hi there,

I had issues in customizing htx coding.

1. My intention is to get a long date (British format) as 17-Jul-2007 in WeatherLink. So far I know there is a HTML tag <!--Date-->.
Is there any HTML tag for Long Date? How to change the settings from US to UK format? Is it grabbing date info from OS settings?

2. I want to perform some simple aritmatic operation such as multiply.
Eg. I had a tag <!--WindSpeed--> and I want to convert to other unit by multiplying a constant, let's say: 3.6 (to change from m/s to km/h).
The intention is that I want to display various units at a time, so I couldn't change it from "Setup>Select Units". I guess this will only use METRIC at a time or otherwise. Correct me if I'm wrong....
By knowing this, I try to customise from htx. How should I go about doing it? Maybe you have some sample code..??  :)

Thanks.....Cheers..............
 :)

Offline Anole

  • Forecaster
  • *****
  • Posts: 585
    • http://pineislandweather.com
Re: Issues in Customizing HTML Codes in WeatherLink
« Reply #1 on: July 17, 2007, 07:23:20 AM »
Quote from: "ilee1"


1. My intention is to get a long date (British format) as 17-Jul-2007 in WeatherLink. So far I know there is a HTML tag <!--Date-->.
Is there any HTML tag for Long Date? How to change the settings from US to UK format? Is it grabbing date info from OS settings?


No tag for long date that I'm aware of and I don't think there is a way to manipulate the date format from within weatherlink.

Quote from: "ilee1"

2. I want to perform some simple aritmatic operation such as multiply.
Eg. I had a tag <!--WindSpeed--> and I want to convert to other unit by multiplying a constant, let's say: 3.6 (to change from m/s to km/h).
The intention is that I want to display various units at a time, so I couldn't change it from "Setup>Select Units". I guess this will only use METRIC at a time or otherwise. Correct me if I'm wrong....


You are not wrong.

Quote from: "ilee1"


By knowing this, I try to customise from htx. How should I go about doing it? Maybe you have some sample code..??  :)  :)


You are going to have to do some manipulation of the data using a scripting language like PHP, PERL or Javascript. With any of these you can manipulate the date to display as you want it, and perform calculations on the data to display in any units you'd like. Plain old html markup  cannot do this. I'd recommend using PHP for these type of functions on a web page.

Offline ncpilot

  • Forecaster
  • *****
  • Posts: 937
    • Monkey Junction Weather
Re: Issues in Customizing HTML Codes in WeatherLink
« Reply #2 on: July 17, 2007, 09:12:20 AM »
I believe he's only creating his webpage locally, i.e., he's not uploading to any type of server. (per his other thread...)

In this case, wouldn't javascript be the best/easiest solution? Just embed the code in the .htx template file. No need to worry about installing php or perl...?
Marc
Wilmington, NC
"Monkey Junction Weather"
Davis VP2 wireless, WeatherLink

Offline ilee1

  • Member
  • *
  • Posts: 13
Re: Issues in Customizing HTML Codes in WeatherLink
« Reply #3 on: July 17, 2007, 09:17:07 AM »
Hi,

Thanks for the reply.
Then I have to look for Javascript sample code on this?
Can anybody give a hand...?    :cry:

Thanks........again...

Offline Curly

  • Forecaster
  • *****
  • Posts: 724
    • Michiana Weather
Re: Issues in Customizing HTML Codes in WeatherLink
« Reply #4 on: July 22, 2007, 05:40:57 PM »
Check the date on this page. It's javascript.
http://mysite.verizon.net/res8sscu/weather.htm

Is that what you are looking for in your issue #1?

Offline Cienega32

  • Forecaster
  • *****
  • Posts: 2635
    • East Mesa Weather
Re: Issues in Customizing HTML Codes in WeatherLink
« Reply #5 on: July 22, 2007, 07:16:29 PM »
That's an outstanding looking page and I love the mouse-over trend graphs.


Nice job!

Pat ~ Davis VP2 6153-Weatherlink-Weather Display-StartWatch-VirtualVP-Win7 Pro-64bit
www.LasCruces-Weather.com   www.EastMesaWeather.com

 

anything