Doesn't work for me, if I select London & SE from your drop down and then return to the page later it displays UK and not my London & SE.mcrossley wrote:What, like this?: http://weather.wilmslowastro.com/test/t ... mes24h.phpduke wrote:Mark, just a thought, is it possible to store the selected region in a cookie so a returning visitor automatically sees their last choice? Presumably in most cases this would be the region they live in.
Welcome to the Cumulus Support forum.
Latest Cumulus MX V3 release 3.28.6 (build 3283) - 21 March 2024
Cumulus MX V4 beta test release 4.0.0 (build 4019) - 03 April 2024
Legacy Cumulus 1 release 1.9.4 (build 1099) - 28 November 2014
(a patch is available for 1.9.4 build 1099 that extends the date range of drop-down menus to 2030)
Download the Software (Cumulus MX / Cumulus 1 and other related items) from the Wiki
Latest Cumulus MX V3 release 3.28.6 (build 3283) - 21 March 2024
Cumulus MX V4 beta test release 4.0.0 (build 4019) - 03 April 2024
Legacy Cumulus 1 release 1.9.4 (build 1099) - 28 November 2014
(a patch is available for 1.9.4 build 1099 that extends the date range of drop-down menus to 2030)
Download the Software (Cumulus MX / Cumulus 1 and other related items) from the Wiki
UK Extremes from the MetOffice
Moderator: daj
Re: UK Extremes from the MetOffice
Re: UK Extremes from the MetOffice
Sorry Mark, ok, using WaterFox/FireFox with cookies enabled. I'm not even seeing a cookie for your site in the list. Also just tried with IE and Chrome with similar result.mcrossley wrote:Cookies disabled? Which browser?
- mcrossley
- Posts: 12766
- Joined: Thu 07 Jan 2010 9:44 pm
- Weather Station: Davis VP2/WLL
- Operating System: Bullseye Lite rPi
- Location: Wilmslow, Cheshire, UK
- Contact:
Re: UK Extremes from the MetOffice
Odd, works in Chrome and IE for me on both my test page and my today/yesterday page...
You do not have the required permissions to view the files attached to this post.
-
- Posts: 86
- Joined: Thu 10 Nov 2011 8:14 pm
- Weather Station: VP2+SHT31+DFars+Solar+AeroCone
- Operating System: Windows 10
- Location: Hemel Hempstead, Hertfordshire, UK
Re: UK Extremes from the MetOffice
Firefox remembers for me (version 33.1.1. cookies enabled) My smart TV which uses linux and safari also remembers
Colin
Colin
- marfanuk
- Posts: 43
- Joined: Wed 06 Nov 2013 5:27 pm
- Weather Station: Davis Vantage Vue
- Operating System: Raspbian on the Raspberry Pi 2
- Location: Nantwich, United Kingdom
- Contact:
Re: UK Extremes from the MetOffice
I've fiddled for ages to try and get the extremes script to work, but with no success.
Heres my link to the script - http://www.nantwich-weather.co.uk/ukExtremes24h.php
My settings -
also Mark met office weather forecast script is looking good, look forward to trying it.
Heres my link to the script - http://www.nantwich-weather.co.uk/ukExtremes24h.php
My settings -
Code: Select all
class ukExtremes24h {
// Data Source
private $urlBase = 'http://datapoint.metoffice.gov.uk/public/data/txt/wxobs/ukextremes/json/';
private $apiKey = '2a7383b4-52a6-4c81-a0b8-77795464f1af'; // Your Met Office DataPoint API key
private $cachePath = 'cache'; // Cache directory without trailing slash
private $cacheFile = 'ukExtremes24h.json'; // Cache file name
private $cacheTime = 3600; // Cache expiration time Default: 3600 seconds = 1 Hour
private $logging = true; // Logs information messages as comments in your HTML
private $rawData = array(); // Used internally to hold status and raw DataPoint data
private $cache = 'cache'; // Used internally to hold full cache file name
- mcrossley
- Posts: 12766
- Joined: Thu 07 Jan 2010 9:44 pm
- Weather Station: Davis VP2/WLL
- Operating System: Bullseye Lite rPi
- Location: Wilmslow, Cheshire, UK
- Contact:
Re: UK Extremes from the MetOffice
Hi Darren, nothing is being sent back to the browser, so you need to check the php error log on your server to see what is going on.
Re: UK Extremes from the MetOffice
I have the cookie in Chrome and FireFox but it does not remember my choice.mcrossley wrote:Odd, works in Chrome and IE for me on both my test page and my today/yesterday page...
You do not have the required permissions to view the files attached to this post.
- mcrossley
- Posts: 12766
- Joined: Thu 07 Jan 2010 9:44 pm
- Weather Station: Davis VP2/WLL
- Operating System: Bullseye Lite rPi
- Location: Wilmslow, Cheshire, UK
- Contact:
Re: UK Extremes from the MetOffice
What are the cookie contents? It should just be the two character code for the selected region.
- marfanuk
- Posts: 43
- Joined: Wed 06 Nov 2013 5:27 pm
- Weather Station: Davis Vantage Vue
- Operating System: Raspbian on the Raspberry Pi 2
- Location: Nantwich, United Kingdom
- Contact:
Re: UK Extremes from the MetOffice
Hi Mark, bit of a delay in replying to You.mcrossley wrote:Hi Darren, nothing is being sent back to the browser, so you need to check the php error log on your server to see what is going on.
I've now got logging activated by my ISP and this is what i get back:
Code: Select all
88.104.86.206 - - [04/Apr/2015:16:06:08 +0100] "GET /ukExtremes24h.php HTTP/1.0" 200 - "-" "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/41.0.2272.118 Safari/537.36"
http://www.nantwich-weather.co.uk/ukExtremes24h.php
- mcrossley
- Posts: 12766
- Joined: Thu 07 Jan 2010 9:44 pm
- Weather Station: Davis VP2/WLL
- Operating System: Bullseye Lite rPi
- Location: Wilmslow, Cheshire, UK
- Contact:
Re: UK Extremes from the MetOffice
Hi Darren, it looks like that is the HTTP access log from the web server, you need the error log to see if anything is going wrong in PHP.
You can try adding the following lines to the top of the PHP script - just after the "<?php" line. The problem is they may not show anything if the script is failing to parse/compile for some reason.
You can try adding the following lines to the top of the PHP script - just after the "<?php" line. The problem is they may not show anything if the script is failing to parse/compile for some reason.
Code: Select all
error_reporting(E_ALL);
ini_set('display_errors', '1');
-
- Posts: 104
- Joined: Sun 29 Jul 2012 11:46 am
- Weather Station: Davis Vantage Pro2 Plus DFARS
- Operating System: Windows 10 64 bit
- Location: Ashurst Bridge, Hampshire UK
- Contact:
UK Extremes from the MetOffice cannot select.
I have the test script for UK extremes working for UK and region SE England here. http://www.tottonweather.co.uk/testUkExtremes24h.phpHowever when a region is selected from the dropdown box nothing happens!
This was the case with the original download.
Is some further coding needed here? Any help appreciated.![Very Happy :D](./images/smilies/icon_e_biggrin.gif)
This was the case with the original download.
Is some further coding needed here? Any help appreciated.
![Very Happy :D](./images/smilies/icon_e_biggrin.gif)
- mcrossley
- Posts: 12766
- Joined: Thu 07 Jan 2010 9:44 pm
- Weather Station: Davis VP2/WLL
- Operating System: Bullseye Lite rPi
- Location: Wilmslow, Cheshire, UK
- Contact:
Re: UK Extremes from the MetOffice
Your page is missing the jquery script. It has...
but jquery.js is not found on your server.
Code: Select all
<script src="public_html/js/jquery.js" type="text/javascript"></script>
-
- Posts: 104
- Joined: Sun 29 Jul 2012 11:46 am
- Weather Station: Davis Vantage Pro2 Plus DFARS
- Operating System: Windows 10 64 bit
- Location: Ashurst Bridge, Hampshire UK
- Contact:
Re: UK Extremes from the MetOffice
That's really odd because it is in there checking Filezilla. Here is a copy from the server
You do not have the required permissions to view the files attached to this post.
- mcrossley
- Posts: 12766
- Joined: Thu 07 Jan 2010 9:44 pm
- Weather Station: Davis VP2/WLL
- Operating System: Bullseye Lite rPi
- Location: Wilmslow, Cheshire, UK
- Contact:
Re: UK Extremes from the MetOffice
I'm on my phone so can't easily check things, but I suspect you need to remove the "public_html" bit from the URL.