Meteogram time
- danville
- Observer

- Posts: 10
- Joined: Tue Jan 02, 2018 1:42 pm
- Location: New York
- Station model: Davis Vantage Pro 2
- Software: WeeWx
- Contact:
Meteogram time
The meteorgram (block) time is ahead by 7 hours and I have made certain that all setup time information is correct. What might need to be done to correct this?
- Gus
- Observer

- Posts: 10
- Joined: Sun Aug 20, 2017 11:17 pm
- Location: Halethorpe, Maryland
- Station model: Davis Vantage Pro 2+
- Software: Weather Display
- Contact:
Re: Meteogram time
Open /homepage/blocks/meteogram/meteogramBlock.php and go to around line 80 and replace the global settings with...
<script>
Highcharts.setOptions({ // Fix for forecast timeline
global: { // useUTC: true is the default setting and graph is x hrs off,
useUTC: false, // change to false and add timezoneOffset : echo($offset * -60)
timezoneOffset: <?php echo $offset*-60?> // value of $offset is calculated in config.php, *-60 to change east-west designation
},
This seems to correct the UTC/ local time problem.
Gus
<script>
Highcharts.setOptions({ // Fix for forecast timeline
global: { // useUTC: true is the default setting and graph is x hrs off,
useUTC: false, // change to false and add timezoneOffset : echo($offset * -60)
timezoneOffset: <?php echo $offset*-60?> // value of $offset is calculated in config.php, *-60 to change east-west designation
},
This seems to correct the UTC/ local time problem.
Gus
- Ken Good
- Advisor

- Posts: 62
- Joined: Thu Dec 28, 2017 4:10 am
- Location: Tyler, Texas
- Station model: Davis Vantage Pro 2 Plus
- Software: Meteobridge
- Contact:
Re: Meteogram time
I am having the same issue. I tried to make the changes suggested and keep getting error messages. Is this the language:
<script>
Highcharts.setOptions({
global: {
useUTC: true
},
lang: {
months: ['<?php echo lang('january','c')?>', '<?php echo lang('february','c')?>', '<?php echo lang('march','c')?>', '<?php echo lang('april','c')?>', '<?php echo lang('may','c')?>', '<?php echo lang('june','c')?>', '<?php echo lang('july','c')?>', '<?php echo lang('august','c')?>', '<?php echo lang('september','c')?>', '<?php echo lang('october','c')?>', '<?php echo lang('november','c')?>', '<?php echo lang('december','c')?>'],
shortMonths: ['<?php echo lang('janAbbr','c')?>', '<?php echo lang('febAbbr','c')?>', '<?php echo lang('marAbbr','c')?>', '<?php echo lang('aprAbbr','c')?>', '<?php echo lang('mayAbbr','c')?>', '<?php echo lang('junAbbr','c')?>', '<?php echo lang('julAbbr','c')?>', '<?php echo lang('augAbbr','c')?>', '<?php echo lang('sepAbbr','c')?>', '<?php echo lang('octAbbr','c')?>', '<?php echo lang('novAbbr','c')?>', '<?php echo lang('decAbbr','c')?>'],
weekdays: ['<?php echo lang('sundayAbbr','c')?>', '<?php echo lang('mondayAbbr','c')?>', '<?php echo lang('tuesdayAbbr','c')?>', '<?php echo lang('wednesdayAbbr','c')?>', '<?php echo lang('thursdayAbbr','c')?>', '<?php echo lang('fridayAbbr','c')?>', '<?php echo lang('saturdayAbbr','c')?>'],
resetZoom: ['<?php echo lang('default zoom','c')?>']
}
});
</script>
I am UTC -6. How should this be changed?
Thanks in advance.
<script>
Highcharts.setOptions({
global: {
useUTC: true
},
lang: {
months: ['<?php echo lang('january','c')?>', '<?php echo lang('february','c')?>', '<?php echo lang('march','c')?>', '<?php echo lang('april','c')?>', '<?php echo lang('may','c')?>', '<?php echo lang('june','c')?>', '<?php echo lang('july','c')?>', '<?php echo lang('august','c')?>', '<?php echo lang('september','c')?>', '<?php echo lang('october','c')?>', '<?php echo lang('november','c')?>', '<?php echo lang('december','c')?>'],
shortMonths: ['<?php echo lang('janAbbr','c')?>', '<?php echo lang('febAbbr','c')?>', '<?php echo lang('marAbbr','c')?>', '<?php echo lang('aprAbbr','c')?>', '<?php echo lang('mayAbbr','c')?>', '<?php echo lang('junAbbr','c')?>', '<?php echo lang('julAbbr','c')?>', '<?php echo lang('augAbbr','c')?>', '<?php echo lang('sepAbbr','c')?>', '<?php echo lang('octAbbr','c')?>', '<?php echo lang('novAbbr','c')?>', '<?php echo lang('decAbbr','c')?>'],
weekdays: ['<?php echo lang('sundayAbbr','c')?>', '<?php echo lang('mondayAbbr','c')?>', '<?php echo lang('tuesdayAbbr','c')?>', '<?php echo lang('wednesdayAbbr','c')?>', '<?php echo lang('thursdayAbbr','c')?>', '<?php echo lang('fridayAbbr','c')?>', '<?php echo lang('saturdayAbbr','c')?>'],
resetZoom: ['<?php echo lang('default zoom','c')?>']
}
});
</script>
I am UTC -6. How should this be changed?
Thanks in advance.
- Gus
- Observer

- Posts: 10
- Joined: Sun Aug 20, 2017 11:17 pm
- Location: Halethorpe, Maryland
- Station model: Davis Vantage Pro 2+
- Software: Weather Display
- Contact:
Re: Meteogram time
That is the correct area. Replace...
global: {
useUTC: true
},
with...
global: {
useUTC: false,
timezoneOffset: <?php echo $offset*-60?>
},
See if that works. Also remember to clear the cache files after making change.
Gus
global: {
useUTC: true
},
with...
global: {
useUTC: false,
timezoneOffset: <?php echo $offset*-60?>
},
See if that works. Also remember to clear the cache files after making change.
Gus
- Ken Good
- Advisor

- Posts: 62
- Joined: Thu Dec 28, 2017 4:10 am
- Location: Tyler, Texas
- Station model: Davis Vantage Pro 2 Plus
- Software: Meteobridge
- Contact:
Re: Meteogram time
Thanks that worked. I was all around it but did not know the programing language. My shots in the dark all fell flat. Thanks again.
Ken
Ken
- Jachym
- Site Admin

- Posts: 1686
- Joined: Fri Aug 18, 2017 10:12 pm
- Location: Brno, Czech Republic
- Station model: WH1080
- Software: Meteobridge
- Contact:
Re: Meteogram time
Thanks Gus, you are right, I will update the block for everyone