WXforum.net

Web Weather => Weather Website PHP/AJAX scripting => Custom Website Templates => Topic started by: saratogaWX on January 10, 2018, 04:41:46 PM

Title: Saratoga template - CoCoRaHS map display
Post by: saratogaWX on January 10, 2018, 04:41:46 PM
I've had a couple of requests to share my CoCoRaHS map (https://saratoga-weather.org/cocorahs.php) page, so I decided to generalize it as an add-on to a USA Saratoga template.  At present, only the old-style CoCoRaHS maps available from https://www.cocorahs.org/Maps/ViewMap.aspx?state=usa can be displayed.

See https://saratoga-weather.org/wxtemplates/plugins.php#cocorahs for download

Edit: USA stations only - Lower 48+Alaska -- Hawaii uses the new maps only :(
Title: Re: Saratoga template - CoCoRaHS map display
Post by: PaulMy on January 10, 2018, 06:14:46 PM
Hi Ken,
I have added it but the map is not displaying www.komokaweather.ca/wxcocorahs.php.  This is my settings:
Code: [Select]
# ------ SETTINGS -------------------
# CoCoRaHS settings:
$CCstation =    'CAN-ON-31';  // Your CoCoRaHS Station identifier (like CA-SC-15 )
$CCcountyName = 'Komoka 2.8 W'; // Your County/Parish name
$CCreportTime = '9:00am'; // Your CoCoRaHS reporting time
$CCstarted =    '01-Feb-2014'; // When you started reporting to CoCoRaHS (for display)
$CCdateAllow =  '2014-02-01'; // YYYY-MM-DD for first date with your CoCoRaHS data
$legendText =   'Komoka, ON Canada'; // Your City name
$legendPos  =   '173,80';   // The top,left pixels offset to display the $legendText over map
#
# ------ END SETTINGS ---------------
I did not change the default $legendPoss = '173,80';

Is there something else I should do?

Thanks,
Paul
Title: Re: Saratoga template - CoCoRaHS map display
Post by: saratogaWX on January 10, 2018, 06:35:11 PM
Hi Paul,
The script will only display the old-style maps clickable in https://www.cocorahs.org/Maps/ViewMap.aspx?state=usa for now.

The Canadian and Bahama stations only display on the new-style Google maps at http://data.cocorahs.org/cocorahs/maps/?country=CAN

I may try to get the Google map version working in the future..
Title: Re: Saratoga template - CoCoRaHS map display
Post by: PaulMy on January 10, 2018, 06:58:10 PM
Thanks Ken,
I will watch for in the future.

Regards,
Paul
Title: Re: Saratoga template - CoCoRaHS map display
Post by: CNYWeather on January 11, 2018, 05:45:42 AM
Ken, i tried downloading the Zip this AM and Windows kept giving me a "Failed - Virus detected" error

Title: Re: Saratoga template - CoCoRaHS map display
Post by: saratogaWX on January 11, 2018, 10:31:33 AM
It's a Windows Defender false positive.  There is no virus in the .zip.
Title: Re: Saratoga template - CoCoRaHS map display
Post by: Maumelle Weather on January 11, 2018, 10:31:42 AM
Just downloaded the script without any issues. Using Malwarebytes Premium and Avast as my A/V.
Title: Re: Saratoga template - CoCoRaHS map display
Post by: saratogaWX on January 11, 2018, 10:45:14 AM
And I'm using Webroot with no issues spotted.  I ran it through virustotal.com with no detected malware.
Title: Re: Saratoga template - CoCoRaHS map display
Post by: CNYWeather on January 11, 2018, 12:16:03 PM
It's a Windows Defender false positive.  There is no virus in the .zip.
Ah ok. I didnt think so. I'll try and download it with Firefox or here at work.
I wan't able to download it due to the warning.
Title: Re: Saratoga template - CoCoRaHS map display
Post by: W3DRM on January 13, 2018, 01:06:08 AM
Hi Ken,

Downloaded and installed fine. No issues at all! Another great package from the Saratoga hall of fame...  =D> \:D/