From: Steve Sutton Date: Fri, 9 Nov 2018 15:18:19 +0000 (-0500) Subject: Updating member plugin with City Weather X-Git-Tag: v2.11.0^2~58 X-Git-Url: http://cvs2.gaslightmedia.com/gitweb/?a=commitdiff_plain;h=580216bf45de3248451fe7a4641229516ac7ef58;p=WP-Plugins%2Fglm-member-db.git Updating member plugin with City Weather Adding icons from NOAA. City weather shortcode created to fetch the city weather using lat lon from each city. Updating shortcode description. Removing extra end table tag from description. --- diff --git a/assets/WeatherIcons/.directory b/assets/WeatherIcons/.directory new file mode 100644 index 00000000..55fdf2e2 --- /dev/null +++ b/assets/WeatherIcons/.directory @@ -0,0 +1,3 @@ +[Dolphin] +Timestamp=2018,11,7,16,24,18 +Version=4 diff --git a/assets/WeatherIcons/bkn.jpg b/assets/WeatherIcons/bkn.jpg new file mode 100644 index 00000000..9ae5b400 Binary files /dev/null and b/assets/WeatherIcons/bkn.jpg differ diff --git a/assets/WeatherIcons/blizzard.jpg b/assets/WeatherIcons/blizzard.jpg new file mode 100644 index 00000000..160dd67b Binary files /dev/null and b/assets/WeatherIcons/blizzard.jpg differ diff --git a/assets/WeatherIcons/blizzard10.jpg b/assets/WeatherIcons/blizzard10.jpg new file mode 100644 index 00000000..57e985a0 Binary files /dev/null and b/assets/WeatherIcons/blizzard10.jpg differ diff --git a/assets/WeatherIcons/blizzard100.jpg b/assets/WeatherIcons/blizzard100.jpg new file mode 100644 index 00000000..c94c2d08 Binary files /dev/null and b/assets/WeatherIcons/blizzard100.jpg differ diff --git a/assets/WeatherIcons/blizzard20.jpg b/assets/WeatherIcons/blizzard20.jpg new file mode 100644 index 00000000..050d2f05 Binary files /dev/null and b/assets/WeatherIcons/blizzard20.jpg differ diff --git a/assets/WeatherIcons/blizzard30.jpg b/assets/WeatherIcons/blizzard30.jpg new file mode 100644 index 00000000..d26dd950 Binary files /dev/null and b/assets/WeatherIcons/blizzard30.jpg differ diff --git a/assets/WeatherIcons/blizzard40.jpg b/assets/WeatherIcons/blizzard40.jpg new file mode 100644 index 00000000..8919a967 Binary files /dev/null and b/assets/WeatherIcons/blizzard40.jpg differ diff --git a/assets/WeatherIcons/blizzard50.jpg b/assets/WeatherIcons/blizzard50.jpg new file mode 100644 index 00000000..eaeb11eb Binary files /dev/null and b/assets/WeatherIcons/blizzard50.jpg differ diff --git a/assets/WeatherIcons/blizzard60.jpg b/assets/WeatherIcons/blizzard60.jpg new file mode 100644 index 00000000..1b027247 Binary files /dev/null and b/assets/WeatherIcons/blizzard60.jpg differ diff --git a/assets/WeatherIcons/blizzard70.jpg b/assets/WeatherIcons/blizzard70.jpg new file mode 100644 index 00000000..40627c2a Binary files /dev/null and b/assets/WeatherIcons/blizzard70.jpg differ diff --git a/assets/WeatherIcons/blizzard80.jpg b/assets/WeatherIcons/blizzard80.jpg new file mode 100644 index 00000000..25528eeb Binary files /dev/null and b/assets/WeatherIcons/blizzard80.jpg differ diff --git a/assets/WeatherIcons/blizzard90.jpg b/assets/WeatherIcons/blizzard90.jpg new file mode 100644 index 00000000..5d3a4069 Binary files /dev/null and b/assets/WeatherIcons/blizzard90.jpg differ diff --git a/assets/WeatherIcons/br.jpg b/assets/WeatherIcons/br.jpg new file mode 100644 index 00000000..3e6b95a9 Binary files /dev/null and b/assets/WeatherIcons/br.jpg differ diff --git a/assets/WeatherIcons/cold.jpg b/assets/WeatherIcons/cold.jpg new file mode 100644 index 00000000..cb44d094 Binary files /dev/null and b/assets/WeatherIcons/cold.jpg differ diff --git a/assets/WeatherIcons/du.jpg b/assets/WeatherIcons/du.jpg new file mode 100644 index 00000000..81a636e2 Binary files /dev/null and b/assets/WeatherIcons/du.jpg differ diff --git a/assets/WeatherIcons/dust.jpg b/assets/WeatherIcons/dust.jpg new file mode 100644 index 00000000..81a636e2 Binary files /dev/null and b/assets/WeatherIcons/dust.jpg differ diff --git a/assets/WeatherIcons/few.jpg b/assets/WeatherIcons/few.jpg new file mode 100644 index 00000000..69d0612a Binary files /dev/null and b/assets/WeatherIcons/few.jpg differ diff --git a/assets/WeatherIcons/fg.jpg b/assets/WeatherIcons/fg.jpg new file mode 100644 index 00000000..2be8ee4c Binary files /dev/null and b/assets/WeatherIcons/fg.jpg differ diff --git a/assets/WeatherIcons/fu.jpg b/assets/WeatherIcons/fu.jpg new file mode 100644 index 00000000..9c921c7e Binary files /dev/null and b/assets/WeatherIcons/fu.jpg differ diff --git a/assets/WeatherIcons/fzra.jpg b/assets/WeatherIcons/fzra.jpg new file mode 100644 index 00000000..cb89c095 Binary files /dev/null and b/assets/WeatherIcons/fzra.jpg differ diff --git a/assets/WeatherIcons/fzra10.jpg b/assets/WeatherIcons/fzra10.jpg new file mode 100644 index 00000000..db066f1b Binary files /dev/null and b/assets/WeatherIcons/fzra10.jpg differ diff --git a/assets/WeatherIcons/fzra100.jpg b/assets/WeatherIcons/fzra100.jpg new file mode 100644 index 00000000..365a1e71 Binary files /dev/null and b/assets/WeatherIcons/fzra100.jpg differ diff --git a/assets/WeatherIcons/fzra20.jpg b/assets/WeatherIcons/fzra20.jpg new file mode 100644 index 00000000..a9cd1639 Binary files /dev/null and b/assets/WeatherIcons/fzra20.jpg differ diff --git a/assets/WeatherIcons/fzra30.jpg b/assets/WeatherIcons/fzra30.jpg new file mode 100644 index 00000000..afccbc0e Binary files /dev/null and b/assets/WeatherIcons/fzra30.jpg differ diff --git a/assets/WeatherIcons/fzra40.jpg b/assets/WeatherIcons/fzra40.jpg new file mode 100644 index 00000000..ce7da3b0 Binary files /dev/null and b/assets/WeatherIcons/fzra40.jpg differ diff --git a/assets/WeatherIcons/fzra50.jpg b/assets/WeatherIcons/fzra50.jpg new file mode 100644 index 00000000..16e6eab0 Binary files /dev/null and b/assets/WeatherIcons/fzra50.jpg differ diff --git a/assets/WeatherIcons/fzra60.jpg b/assets/WeatherIcons/fzra60.jpg new file mode 100644 index 00000000..27b797b1 Binary files /dev/null and b/assets/WeatherIcons/fzra60.jpg differ diff --git a/assets/WeatherIcons/fzra70.jpg b/assets/WeatherIcons/fzra70.jpg new file mode 100644 index 00000000..18b7f9cf Binary files /dev/null and b/assets/WeatherIcons/fzra70.jpg differ diff --git a/assets/WeatherIcons/fzra80.jpg b/assets/WeatherIcons/fzra80.jpg new file mode 100644 index 00000000..174e7d53 Binary files /dev/null and b/assets/WeatherIcons/fzra80.jpg differ diff --git a/assets/WeatherIcons/fzra90.jpg b/assets/WeatherIcons/fzra90.jpg new file mode 100644 index 00000000..ec928857 Binary files /dev/null and b/assets/WeatherIcons/fzra90.jpg differ diff --git a/assets/WeatherIcons/fzrara.jpg b/assets/WeatherIcons/fzrara.jpg new file mode 100644 index 00000000..12bb8a9c Binary files /dev/null and b/assets/WeatherIcons/fzrara.jpg differ diff --git a/assets/WeatherIcons/hazy.jpg b/assets/WeatherIcons/hazy.jpg new file mode 100644 index 00000000..7f87c648 Binary files /dev/null and b/assets/WeatherIcons/hazy.jpg differ diff --git a/assets/WeatherIcons/hi_bkn.jpg b/assets/WeatherIcons/hi_bkn.jpg new file mode 100644 index 00000000..3fcb99f5 Binary files /dev/null and b/assets/WeatherIcons/hi_bkn.jpg differ diff --git a/assets/WeatherIcons/hi_few.jpg b/assets/WeatherIcons/hi_few.jpg new file mode 100644 index 00000000..fd1ec329 Binary files /dev/null and b/assets/WeatherIcons/hi_few.jpg differ diff --git a/assets/WeatherIcons/hi_nbkn.jpg b/assets/WeatherIcons/hi_nbkn.jpg new file mode 100644 index 00000000..9cc92c33 Binary files /dev/null and b/assets/WeatherIcons/hi_nbkn.jpg differ diff --git a/assets/WeatherIcons/hi_nfew.jpg b/assets/WeatherIcons/hi_nfew.jpg new file mode 100644 index 00000000..bc75cb14 Binary files /dev/null and b/assets/WeatherIcons/hi_nfew.jpg differ diff --git a/assets/WeatherIcons/hi_nsct.jpg b/assets/WeatherIcons/hi_nsct.jpg new file mode 100644 index 00000000..36d7b33c Binary files /dev/null and b/assets/WeatherIcons/hi_nsct.jpg differ diff --git a/assets/WeatherIcons/hi_nshwrs.jpg b/assets/WeatherIcons/hi_nshwrs.jpg new file mode 100644 index 00000000..99294522 Binary files /dev/null and b/assets/WeatherIcons/hi_nshwrs.jpg differ diff --git a/assets/WeatherIcons/hi_nshwrs10.jpg b/assets/WeatherIcons/hi_nshwrs10.jpg new file mode 100644 index 00000000..31313a44 Binary files /dev/null and b/assets/WeatherIcons/hi_nshwrs10.jpg differ diff --git a/assets/WeatherIcons/hi_nshwrs100.jpg b/assets/WeatherIcons/hi_nshwrs100.jpg new file mode 100644 index 00000000..12bc025f Binary files /dev/null and b/assets/WeatherIcons/hi_nshwrs100.jpg differ diff --git a/assets/WeatherIcons/hi_nshwrs20.jpg b/assets/WeatherIcons/hi_nshwrs20.jpg new file mode 100644 index 00000000..c106375c Binary files /dev/null and b/assets/WeatherIcons/hi_nshwrs20.jpg differ diff --git a/assets/WeatherIcons/hi_nshwrs30.jpg b/assets/WeatherIcons/hi_nshwrs30.jpg new file mode 100644 index 00000000..be004676 Binary files /dev/null and b/assets/WeatherIcons/hi_nshwrs30.jpg differ diff --git a/assets/WeatherIcons/hi_nshwrs40.jpg b/assets/WeatherIcons/hi_nshwrs40.jpg new file mode 100644 index 00000000..99f067ab Binary files /dev/null and b/assets/WeatherIcons/hi_nshwrs40.jpg differ diff --git a/assets/WeatherIcons/hi_nshwrs50.jpg b/assets/WeatherIcons/hi_nshwrs50.jpg new file mode 100644 index 00000000..1c4a10ae Binary files /dev/null and b/assets/WeatherIcons/hi_nshwrs50.jpg differ diff --git a/assets/WeatherIcons/hi_nshwrs60.jpg b/assets/WeatherIcons/hi_nshwrs60.jpg new file mode 100644 index 00000000..9bc1178c Binary files /dev/null and b/assets/WeatherIcons/hi_nshwrs60.jpg differ diff --git a/assets/WeatherIcons/hi_nshwrs70.jpg b/assets/WeatherIcons/hi_nshwrs70.jpg new file mode 100644 index 00000000..2db2001e Binary files /dev/null and b/assets/WeatherIcons/hi_nshwrs70.jpg differ diff --git a/assets/WeatherIcons/hi_nshwrs80.jpg b/assets/WeatherIcons/hi_nshwrs80.jpg new file mode 100644 index 00000000..8af4b3d9 Binary files /dev/null and b/assets/WeatherIcons/hi_nshwrs80.jpg differ diff --git a/assets/WeatherIcons/hi_nshwrs90.jpg b/assets/WeatherIcons/hi_nshwrs90.jpg new file mode 100644 index 00000000..b145cb8b Binary files /dev/null and b/assets/WeatherIcons/hi_nshwrs90.jpg differ diff --git a/assets/WeatherIcons/hi_nskc.jpg b/assets/WeatherIcons/hi_nskc.jpg new file mode 100644 index 00000000..cfaa6355 Binary files /dev/null and b/assets/WeatherIcons/hi_nskc.jpg differ diff --git a/assets/WeatherIcons/hi_ntsra.jpg b/assets/WeatherIcons/hi_ntsra.jpg new file mode 100644 index 00000000..833ab678 Binary files /dev/null and b/assets/WeatherIcons/hi_ntsra.jpg differ diff --git a/assets/WeatherIcons/hi_ntsra10.jpg b/assets/WeatherIcons/hi_ntsra10.jpg new file mode 100644 index 00000000..6f963eae Binary files /dev/null and b/assets/WeatherIcons/hi_ntsra10.jpg differ diff --git a/assets/WeatherIcons/hi_ntsra100.jpg b/assets/WeatherIcons/hi_ntsra100.jpg new file mode 100644 index 00000000..35949dd4 Binary files /dev/null and b/assets/WeatherIcons/hi_ntsra100.jpg differ diff --git a/assets/WeatherIcons/hi_ntsra20.jpg b/assets/WeatherIcons/hi_ntsra20.jpg new file mode 100644 index 00000000..cf2c8074 Binary files /dev/null and b/assets/WeatherIcons/hi_ntsra20.jpg differ diff --git a/assets/WeatherIcons/hi_ntsra30.jpg b/assets/WeatherIcons/hi_ntsra30.jpg new file mode 100644 index 00000000..50a44b85 Binary files /dev/null and b/assets/WeatherIcons/hi_ntsra30.jpg differ diff --git a/assets/WeatherIcons/hi_ntsra40.jpg b/assets/WeatherIcons/hi_ntsra40.jpg new file mode 100644 index 00000000..eb422d02 Binary files /dev/null and b/assets/WeatherIcons/hi_ntsra40.jpg differ diff --git a/assets/WeatherIcons/hi_ntsra50.jpg b/assets/WeatherIcons/hi_ntsra50.jpg new file mode 100644 index 00000000..a6c0c7a0 Binary files /dev/null and b/assets/WeatherIcons/hi_ntsra50.jpg differ diff --git a/assets/WeatherIcons/hi_ntsra60.jpg b/assets/WeatherIcons/hi_ntsra60.jpg new file mode 100644 index 00000000..c41ab5c5 Binary files /dev/null and b/assets/WeatherIcons/hi_ntsra60.jpg differ diff --git a/assets/WeatherIcons/hi_ntsra70.jpg b/assets/WeatherIcons/hi_ntsra70.jpg new file mode 100644 index 00000000..c20a5931 Binary files /dev/null and b/assets/WeatherIcons/hi_ntsra70.jpg differ diff --git a/assets/WeatherIcons/hi_ntsra80.jpg b/assets/WeatherIcons/hi_ntsra80.jpg new file mode 100644 index 00000000..f8577e5e Binary files /dev/null and b/assets/WeatherIcons/hi_ntsra80.jpg differ diff --git a/assets/WeatherIcons/hi_ntsra90.jpg b/assets/WeatherIcons/hi_ntsra90.jpg new file mode 100644 index 00000000..7483f771 Binary files /dev/null and b/assets/WeatherIcons/hi_ntsra90.jpg differ diff --git a/assets/WeatherIcons/hi_sct.jpg b/assets/WeatherIcons/hi_sct.jpg new file mode 100644 index 00000000..42598169 Binary files /dev/null and b/assets/WeatherIcons/hi_sct.jpg differ diff --git a/assets/WeatherIcons/hi_shwrs.jpg b/assets/WeatherIcons/hi_shwrs.jpg new file mode 100644 index 00000000..d9d146d7 Binary files /dev/null and b/assets/WeatherIcons/hi_shwrs.jpg differ diff --git a/assets/WeatherIcons/hi_shwrs10.jpg b/assets/WeatherIcons/hi_shwrs10.jpg new file mode 100644 index 00000000..1bccd5a1 Binary files /dev/null and b/assets/WeatherIcons/hi_shwrs10.jpg differ diff --git a/assets/WeatherIcons/hi_shwrs100.jpg b/assets/WeatherIcons/hi_shwrs100.jpg new file mode 100644 index 00000000..3497aca0 Binary files /dev/null and b/assets/WeatherIcons/hi_shwrs100.jpg differ diff --git a/assets/WeatherIcons/hi_shwrs20.jpg b/assets/WeatherIcons/hi_shwrs20.jpg new file mode 100644 index 00000000..0bc44812 Binary files /dev/null and b/assets/WeatherIcons/hi_shwrs20.jpg differ diff --git a/assets/WeatherIcons/hi_shwrs30.jpg b/assets/WeatherIcons/hi_shwrs30.jpg new file mode 100644 index 00000000..9cf58f58 Binary files /dev/null and b/assets/WeatherIcons/hi_shwrs30.jpg differ diff --git a/assets/WeatherIcons/hi_shwrs40.jpg b/assets/WeatherIcons/hi_shwrs40.jpg new file mode 100644 index 00000000..4f764dea Binary files /dev/null and b/assets/WeatherIcons/hi_shwrs40.jpg differ diff --git a/assets/WeatherIcons/hi_shwrs50.jpg b/assets/WeatherIcons/hi_shwrs50.jpg new file mode 100644 index 00000000..5c29a4b1 Binary files /dev/null and b/assets/WeatherIcons/hi_shwrs50.jpg differ diff --git a/assets/WeatherIcons/hi_shwrs60.jpg b/assets/WeatherIcons/hi_shwrs60.jpg new file mode 100644 index 00000000..26bbe51b Binary files /dev/null and b/assets/WeatherIcons/hi_shwrs60.jpg differ diff --git a/assets/WeatherIcons/hi_shwrs70.jpg b/assets/WeatherIcons/hi_shwrs70.jpg new file mode 100644 index 00000000..09124b83 Binary files /dev/null and b/assets/WeatherIcons/hi_shwrs70.jpg differ diff --git a/assets/WeatherIcons/hi_shwrs80.jpg b/assets/WeatherIcons/hi_shwrs80.jpg new file mode 100644 index 00000000..9cd15601 Binary files /dev/null and b/assets/WeatherIcons/hi_shwrs80.jpg differ diff --git a/assets/WeatherIcons/hi_shwrs90.jpg b/assets/WeatherIcons/hi_shwrs90.jpg new file mode 100644 index 00000000..2b9b8b36 Binary files /dev/null and b/assets/WeatherIcons/hi_shwrs90.jpg differ diff --git a/assets/WeatherIcons/hi_skc.jpg b/assets/WeatherIcons/hi_skc.jpg new file mode 100644 index 00000000..c7c713c7 Binary files /dev/null and b/assets/WeatherIcons/hi_skc.jpg differ diff --git a/assets/WeatherIcons/hi_tsra.jpg b/assets/WeatherIcons/hi_tsra.jpg new file mode 100644 index 00000000..6e031603 Binary files /dev/null and b/assets/WeatherIcons/hi_tsra.jpg differ diff --git a/assets/WeatherIcons/hi_tsra10.jpg b/assets/WeatherIcons/hi_tsra10.jpg new file mode 100644 index 00000000..c2cb8f4a Binary files /dev/null and b/assets/WeatherIcons/hi_tsra10.jpg differ diff --git a/assets/WeatherIcons/hi_tsra100.jpg b/assets/WeatherIcons/hi_tsra100.jpg new file mode 100644 index 00000000..cf809dfb Binary files /dev/null and b/assets/WeatherIcons/hi_tsra100.jpg differ diff --git a/assets/WeatherIcons/hi_tsra20.jpg b/assets/WeatherIcons/hi_tsra20.jpg new file mode 100644 index 00000000..6bd010e6 Binary files /dev/null and b/assets/WeatherIcons/hi_tsra20.jpg differ diff --git a/assets/WeatherIcons/hi_tsra30.jpg b/assets/WeatherIcons/hi_tsra30.jpg new file mode 100644 index 00000000..ed3b207b Binary files /dev/null and b/assets/WeatherIcons/hi_tsra30.jpg differ diff --git a/assets/WeatherIcons/hi_tsra40.jpg b/assets/WeatherIcons/hi_tsra40.jpg new file mode 100644 index 00000000..64389163 Binary files /dev/null and b/assets/WeatherIcons/hi_tsra40.jpg differ diff --git a/assets/WeatherIcons/hi_tsra50.jpg b/assets/WeatherIcons/hi_tsra50.jpg new file mode 100644 index 00000000..5204d639 Binary files /dev/null and b/assets/WeatherIcons/hi_tsra50.jpg differ diff --git a/assets/WeatherIcons/hi_tsra60.jpg b/assets/WeatherIcons/hi_tsra60.jpg new file mode 100644 index 00000000..51bd42c1 Binary files /dev/null and b/assets/WeatherIcons/hi_tsra60.jpg differ diff --git a/assets/WeatherIcons/hi_tsra70.jpg b/assets/WeatherIcons/hi_tsra70.jpg new file mode 100644 index 00000000..692ea1d9 Binary files /dev/null and b/assets/WeatherIcons/hi_tsra70.jpg differ diff --git a/assets/WeatherIcons/hi_tsra80.jpg b/assets/WeatherIcons/hi_tsra80.jpg new file mode 100644 index 00000000..329ecfe5 Binary files /dev/null and b/assets/WeatherIcons/hi_tsra80.jpg differ diff --git a/assets/WeatherIcons/hi_tsra90.jpg b/assets/WeatherIcons/hi_tsra90.jpg new file mode 100644 index 00000000..47f620ad Binary files /dev/null and b/assets/WeatherIcons/hi_tsra90.jpg differ diff --git a/assets/WeatherIcons/hot.jpg b/assets/WeatherIcons/hot.jpg new file mode 100644 index 00000000..0285bf2e Binary files /dev/null and b/assets/WeatherIcons/hot.jpg differ diff --git a/assets/WeatherIcons/ip.jpg b/assets/WeatherIcons/ip.jpg new file mode 100644 index 00000000..cc5db3e9 Binary files /dev/null and b/assets/WeatherIcons/ip.jpg differ diff --git a/assets/WeatherIcons/ip10.jpg b/assets/WeatherIcons/ip10.jpg new file mode 100644 index 00000000..4ed7f515 Binary files /dev/null and b/assets/WeatherIcons/ip10.jpg differ diff --git a/assets/WeatherIcons/ip100.jpg b/assets/WeatherIcons/ip100.jpg new file mode 100644 index 00000000..69383817 Binary files /dev/null and b/assets/WeatherIcons/ip100.jpg differ diff --git a/assets/WeatherIcons/ip20.jpg b/assets/WeatherIcons/ip20.jpg new file mode 100644 index 00000000..04f8e525 Binary files /dev/null and b/assets/WeatherIcons/ip20.jpg differ diff --git a/assets/WeatherIcons/ip30.jpg b/assets/WeatherIcons/ip30.jpg new file mode 100644 index 00000000..67e06961 Binary files /dev/null and b/assets/WeatherIcons/ip30.jpg differ diff --git a/assets/WeatherIcons/ip40.jpg b/assets/WeatherIcons/ip40.jpg new file mode 100644 index 00000000..732b3430 Binary files /dev/null and b/assets/WeatherIcons/ip40.jpg differ diff --git a/assets/WeatherIcons/ip50.jpg b/assets/WeatherIcons/ip50.jpg new file mode 100644 index 00000000..57cb5abb Binary files /dev/null and b/assets/WeatherIcons/ip50.jpg differ diff --git a/assets/WeatherIcons/ip60.jpg b/assets/WeatherIcons/ip60.jpg new file mode 100644 index 00000000..645bb9fb Binary files /dev/null and b/assets/WeatherIcons/ip60.jpg differ diff --git a/assets/WeatherIcons/ip70.jpg b/assets/WeatherIcons/ip70.jpg new file mode 100644 index 00000000..c480b0eb Binary files /dev/null and b/assets/WeatherIcons/ip70.jpg differ diff --git a/assets/WeatherIcons/ip80.jpg b/assets/WeatherIcons/ip80.jpg new file mode 100644 index 00000000..c6635789 Binary files /dev/null and b/assets/WeatherIcons/ip80.jpg differ diff --git a/assets/WeatherIcons/ip90.jpg b/assets/WeatherIcons/ip90.jpg new file mode 100644 index 00000000..d96b4dd5 Binary files /dev/null and b/assets/WeatherIcons/ip90.jpg differ diff --git a/assets/WeatherIcons/mist.jpg b/assets/WeatherIcons/mist.jpg new file mode 100644 index 00000000..475acaf9 Binary files /dev/null and b/assets/WeatherIcons/mist.jpg differ diff --git a/assets/WeatherIcons/mix.jpg b/assets/WeatherIcons/mix.jpg new file mode 100644 index 00000000..84ad6956 Binary files /dev/null and b/assets/WeatherIcons/mix.jpg differ diff --git a/assets/WeatherIcons/mix10.jpg b/assets/WeatherIcons/mix10.jpg new file mode 100644 index 00000000..56e77afe Binary files /dev/null and b/assets/WeatherIcons/mix10.jpg differ diff --git a/assets/WeatherIcons/mix100.jpg b/assets/WeatherIcons/mix100.jpg new file mode 100644 index 00000000..475ff362 Binary files /dev/null and b/assets/WeatherIcons/mix100.jpg differ diff --git a/assets/WeatherIcons/mix20.jpg b/assets/WeatherIcons/mix20.jpg new file mode 100644 index 00000000..fa8d1528 Binary files /dev/null and b/assets/WeatherIcons/mix20.jpg differ diff --git a/assets/WeatherIcons/mix30.jpg b/assets/WeatherIcons/mix30.jpg new file mode 100644 index 00000000..4158702f Binary files /dev/null and b/assets/WeatherIcons/mix30.jpg differ diff --git a/assets/WeatherIcons/mix40.jpg b/assets/WeatherIcons/mix40.jpg new file mode 100644 index 00000000..2e81758b Binary files /dev/null and b/assets/WeatherIcons/mix40.jpg differ diff --git a/assets/WeatherIcons/mix50.jpg b/assets/WeatherIcons/mix50.jpg new file mode 100644 index 00000000..11b5b8e3 Binary files /dev/null and b/assets/WeatherIcons/mix50.jpg differ diff --git a/assets/WeatherIcons/mix60.jpg b/assets/WeatherIcons/mix60.jpg new file mode 100644 index 00000000..c7cba733 Binary files /dev/null and b/assets/WeatherIcons/mix60.jpg differ diff --git a/assets/WeatherIcons/mix70.jpg b/assets/WeatherIcons/mix70.jpg new file mode 100644 index 00000000..961d273f Binary files /dev/null and b/assets/WeatherIcons/mix70.jpg differ diff --git a/assets/WeatherIcons/mix80.jpg b/assets/WeatherIcons/mix80.jpg new file mode 100644 index 00000000..36e913fb Binary files /dev/null and b/assets/WeatherIcons/mix80.jpg differ diff --git a/assets/WeatherIcons/mix90.jpg b/assets/WeatherIcons/mix90.jpg new file mode 100644 index 00000000..a15aea95 Binary files /dev/null and b/assets/WeatherIcons/mix90.jpg differ diff --git a/assets/WeatherIcons/nbkn.jpg b/assets/WeatherIcons/nbkn.jpg new file mode 100644 index 00000000..0b4bbddc Binary files /dev/null and b/assets/WeatherIcons/nbkn.jpg differ diff --git a/assets/WeatherIcons/nfew.jpg b/assets/WeatherIcons/nfew.jpg new file mode 100644 index 00000000..bba1d84f Binary files /dev/null and b/assets/WeatherIcons/nfew.jpg differ diff --git a/assets/WeatherIcons/nfg.jpg b/assets/WeatherIcons/nfg.jpg new file mode 100644 index 00000000..bf177363 Binary files /dev/null and b/assets/WeatherIcons/nfg.jpg differ diff --git a/assets/WeatherIcons/nmix.jpg b/assets/WeatherIcons/nmix.jpg new file mode 100644 index 00000000..d21400ca Binary files /dev/null and b/assets/WeatherIcons/nmix.jpg differ diff --git a/assets/WeatherIcons/novc.jpg b/assets/WeatherIcons/novc.jpg new file mode 100644 index 00000000..52c5e5ec Binary files /dev/null and b/assets/WeatherIcons/novc.jpg differ diff --git a/assets/WeatherIcons/nra.jpg b/assets/WeatherIcons/nra.jpg new file mode 100644 index 00000000..e00d1076 Binary files /dev/null and b/assets/WeatherIcons/nra.jpg differ diff --git a/assets/WeatherIcons/nra10.jpg b/assets/WeatherIcons/nra10.jpg new file mode 100644 index 00000000..2c2fa115 Binary files /dev/null and b/assets/WeatherIcons/nra10.jpg differ diff --git a/assets/WeatherIcons/nra100.jpg b/assets/WeatherIcons/nra100.jpg new file mode 100644 index 00000000..a3ce985d Binary files /dev/null and b/assets/WeatherIcons/nra100.jpg differ diff --git a/assets/WeatherIcons/nra20.jpg b/assets/WeatherIcons/nra20.jpg new file mode 100644 index 00000000..2b5d0232 Binary files /dev/null and b/assets/WeatherIcons/nra20.jpg differ diff --git a/assets/WeatherIcons/nra30.jpg b/assets/WeatherIcons/nra30.jpg new file mode 100644 index 00000000..3967a3d8 Binary files /dev/null and b/assets/WeatherIcons/nra30.jpg differ diff --git a/assets/WeatherIcons/nra40.jpg b/assets/WeatherIcons/nra40.jpg new file mode 100644 index 00000000..d964baf2 Binary files /dev/null and b/assets/WeatherIcons/nra40.jpg differ diff --git a/assets/WeatherIcons/nra50.jpg b/assets/WeatherIcons/nra50.jpg new file mode 100644 index 00000000..bbd19ca6 Binary files /dev/null and b/assets/WeatherIcons/nra50.jpg differ diff --git a/assets/WeatherIcons/nra60.jpg b/assets/WeatherIcons/nra60.jpg new file mode 100644 index 00000000..a16693b1 Binary files /dev/null and b/assets/WeatherIcons/nra60.jpg differ diff --git a/assets/WeatherIcons/nra70.jpg b/assets/WeatherIcons/nra70.jpg new file mode 100644 index 00000000..0f52e5d7 Binary files /dev/null and b/assets/WeatherIcons/nra70.jpg differ diff --git a/assets/WeatherIcons/nra80.jpg b/assets/WeatherIcons/nra80.jpg new file mode 100644 index 00000000..31a36516 Binary files /dev/null and b/assets/WeatherIcons/nra80.jpg differ diff --git a/assets/WeatherIcons/nra90.jpg b/assets/WeatherIcons/nra90.jpg new file mode 100644 index 00000000..913fc598 Binary files /dev/null and b/assets/WeatherIcons/nra90.jpg differ diff --git a/assets/WeatherIcons/nraip.jpg b/assets/WeatherIcons/nraip.jpg new file mode 100644 index 00000000..1faf5419 Binary files /dev/null and b/assets/WeatherIcons/nraip.jpg differ diff --git a/assets/WeatherIcons/nraip10.jpg b/assets/WeatherIcons/nraip10.jpg new file mode 100644 index 00000000..834cab4b Binary files /dev/null and b/assets/WeatherIcons/nraip10.jpg differ diff --git a/assets/WeatherIcons/nraip100.jpg b/assets/WeatherIcons/nraip100.jpg new file mode 100644 index 00000000..462e563d Binary files /dev/null and b/assets/WeatherIcons/nraip100.jpg differ diff --git a/assets/WeatherIcons/nraip20.jpg b/assets/WeatherIcons/nraip20.jpg new file mode 100644 index 00000000..ed48109d Binary files /dev/null and b/assets/WeatherIcons/nraip20.jpg differ diff --git a/assets/WeatherIcons/nraip30.jpg b/assets/WeatherIcons/nraip30.jpg new file mode 100644 index 00000000..1191c1e0 Binary files /dev/null and b/assets/WeatherIcons/nraip30.jpg differ diff --git a/assets/WeatherIcons/nraip40.jpg b/assets/WeatherIcons/nraip40.jpg new file mode 100644 index 00000000..d911224d Binary files /dev/null and b/assets/WeatherIcons/nraip40.jpg differ diff --git a/assets/WeatherIcons/nraip50.jpg b/assets/WeatherIcons/nraip50.jpg new file mode 100644 index 00000000..8daacc8a Binary files /dev/null and b/assets/WeatherIcons/nraip50.jpg differ diff --git a/assets/WeatherIcons/nraip60.jpg b/assets/WeatherIcons/nraip60.jpg new file mode 100644 index 00000000..2fd2b673 Binary files /dev/null and b/assets/WeatherIcons/nraip60.jpg differ diff --git a/assets/WeatherIcons/nraip70.jpg b/assets/WeatherIcons/nraip70.jpg new file mode 100644 index 00000000..788c2a6f Binary files /dev/null and b/assets/WeatherIcons/nraip70.jpg differ diff --git a/assets/WeatherIcons/nraip80.jpg b/assets/WeatherIcons/nraip80.jpg new file mode 100644 index 00000000..0867d010 Binary files /dev/null and b/assets/WeatherIcons/nraip80.jpg differ diff --git a/assets/WeatherIcons/nraip90.jpg b/assets/WeatherIcons/nraip90.jpg new file mode 100644 index 00000000..923a8737 Binary files /dev/null and b/assets/WeatherIcons/nraip90.jpg differ diff --git a/assets/WeatherIcons/nrasn.jpg b/assets/WeatherIcons/nrasn.jpg new file mode 100644 index 00000000..198d857d Binary files /dev/null and b/assets/WeatherIcons/nrasn.jpg differ diff --git a/assets/WeatherIcons/nrasn10.jpg b/assets/WeatherIcons/nrasn10.jpg new file mode 100644 index 00000000..52ed6f93 Binary files /dev/null and b/assets/WeatherIcons/nrasn10.jpg differ diff --git a/assets/WeatherIcons/nrasn100.jpg b/assets/WeatherIcons/nrasn100.jpg new file mode 100644 index 00000000..e2324002 Binary files /dev/null and b/assets/WeatherIcons/nrasn100.jpg differ diff --git a/assets/WeatherIcons/nrasn20.jpg b/assets/WeatherIcons/nrasn20.jpg new file mode 100644 index 00000000..505e7692 Binary files /dev/null and b/assets/WeatherIcons/nrasn20.jpg differ diff --git a/assets/WeatherIcons/nrasn30.jpg b/assets/WeatherIcons/nrasn30.jpg new file mode 100644 index 00000000..baab7a48 Binary files /dev/null and b/assets/WeatherIcons/nrasn30.jpg differ diff --git a/assets/WeatherIcons/nrasn40.jpg b/assets/WeatherIcons/nrasn40.jpg new file mode 100644 index 00000000..d065d7ab Binary files /dev/null and b/assets/WeatherIcons/nrasn40.jpg differ diff --git a/assets/WeatherIcons/nrasn50.jpg b/assets/WeatherIcons/nrasn50.jpg new file mode 100644 index 00000000..c2c43b14 Binary files /dev/null and b/assets/WeatherIcons/nrasn50.jpg differ diff --git a/assets/WeatherIcons/nrasn60.jpg b/assets/WeatherIcons/nrasn60.jpg new file mode 100644 index 00000000..3e5da3c1 Binary files /dev/null and b/assets/WeatherIcons/nrasn60.jpg differ diff --git a/assets/WeatherIcons/nrasn70.jpg b/assets/WeatherIcons/nrasn70.jpg new file mode 100644 index 00000000..bd07b955 Binary files /dev/null and b/assets/WeatherIcons/nrasn70.jpg differ diff --git a/assets/WeatherIcons/nrasn80.jpg b/assets/WeatherIcons/nrasn80.jpg new file mode 100644 index 00000000..5efc6d1f Binary files /dev/null and b/assets/WeatherIcons/nrasn80.jpg differ diff --git a/assets/WeatherIcons/nrasn90.jpg b/assets/WeatherIcons/nrasn90.jpg new file mode 100644 index 00000000..3b8a0207 Binary files /dev/null and b/assets/WeatherIcons/nrasn90.jpg differ diff --git a/assets/WeatherIcons/nsct.jpg b/assets/WeatherIcons/nsct.jpg new file mode 100644 index 00000000..6a6ef9e4 Binary files /dev/null and b/assets/WeatherIcons/nsct.jpg differ diff --git a/assets/WeatherIcons/nscttsra.jpg b/assets/WeatherIcons/nscttsra.jpg new file mode 100644 index 00000000..87ec037e Binary files /dev/null and b/assets/WeatherIcons/nscttsra.jpg differ diff --git a/assets/WeatherIcons/nscttsra10.jpg b/assets/WeatherIcons/nscttsra10.jpg new file mode 100644 index 00000000..0b17d98d Binary files /dev/null and b/assets/WeatherIcons/nscttsra10.jpg differ diff --git a/assets/WeatherIcons/nscttsra100.jpg b/assets/WeatherIcons/nscttsra100.jpg new file mode 100644 index 00000000..1e25f99a Binary files /dev/null and b/assets/WeatherIcons/nscttsra100.jpg differ diff --git a/assets/WeatherIcons/nscttsra20.jpg b/assets/WeatherIcons/nscttsra20.jpg new file mode 100644 index 00000000..e6c4d666 Binary files /dev/null and b/assets/WeatherIcons/nscttsra20.jpg differ diff --git a/assets/WeatherIcons/nscttsra30.jpg b/assets/WeatherIcons/nscttsra30.jpg new file mode 100644 index 00000000..054eb171 Binary files /dev/null and b/assets/WeatherIcons/nscttsra30.jpg differ diff --git a/assets/WeatherIcons/nscttsra40.jpg b/assets/WeatherIcons/nscttsra40.jpg new file mode 100644 index 00000000..1e497df4 Binary files /dev/null and b/assets/WeatherIcons/nscttsra40.jpg differ diff --git a/assets/WeatherIcons/nscttsra50.jpg b/assets/WeatherIcons/nscttsra50.jpg new file mode 100644 index 00000000..a7260c19 Binary files /dev/null and b/assets/WeatherIcons/nscttsra50.jpg differ diff --git a/assets/WeatherIcons/nscttsra60.jpg b/assets/WeatherIcons/nscttsra60.jpg new file mode 100644 index 00000000..e0c0063d Binary files /dev/null and b/assets/WeatherIcons/nscttsra60.jpg differ diff --git a/assets/WeatherIcons/nscttsra70.jpg b/assets/WeatherIcons/nscttsra70.jpg new file mode 100644 index 00000000..f7fa940e Binary files /dev/null and b/assets/WeatherIcons/nscttsra70.jpg differ diff --git a/assets/WeatherIcons/nscttsra80.jpg b/assets/WeatherIcons/nscttsra80.jpg new file mode 100644 index 00000000..3e61790b Binary files /dev/null and b/assets/WeatherIcons/nscttsra80.jpg differ diff --git a/assets/WeatherIcons/nscttsra90.jpg b/assets/WeatherIcons/nscttsra90.jpg new file mode 100644 index 00000000..5ad2bcb2 Binary files /dev/null and b/assets/WeatherIcons/nscttsra90.jpg differ diff --git a/assets/WeatherIcons/nskc.jpg b/assets/WeatherIcons/nskc.jpg new file mode 100644 index 00000000..0fdc7891 Binary files /dev/null and b/assets/WeatherIcons/nskc.jpg differ diff --git a/assets/WeatherIcons/nsn.jpg b/assets/WeatherIcons/nsn.jpg new file mode 100644 index 00000000..e086e6c0 Binary files /dev/null and b/assets/WeatherIcons/nsn.jpg differ diff --git a/assets/WeatherIcons/nsn10.jpg b/assets/WeatherIcons/nsn10.jpg new file mode 100644 index 00000000..a4a398ea Binary files /dev/null and b/assets/WeatherIcons/nsn10.jpg differ diff --git a/assets/WeatherIcons/nsn100.jpg b/assets/WeatherIcons/nsn100.jpg new file mode 100644 index 00000000..f3732b7a Binary files /dev/null and b/assets/WeatherIcons/nsn100.jpg differ diff --git a/assets/WeatherIcons/nsn20.jpg b/assets/WeatherIcons/nsn20.jpg new file mode 100644 index 00000000..e3da3776 Binary files /dev/null and b/assets/WeatherIcons/nsn20.jpg differ diff --git a/assets/WeatherIcons/nsn30.jpg b/assets/WeatherIcons/nsn30.jpg new file mode 100644 index 00000000..2b93f6d5 Binary files /dev/null and b/assets/WeatherIcons/nsn30.jpg differ diff --git a/assets/WeatherIcons/nsn40.jpg b/assets/WeatherIcons/nsn40.jpg new file mode 100644 index 00000000..17c4f675 Binary files /dev/null and b/assets/WeatherIcons/nsn40.jpg differ diff --git a/assets/WeatherIcons/nsn50.jpg b/assets/WeatherIcons/nsn50.jpg new file mode 100644 index 00000000..2d22122f Binary files /dev/null and b/assets/WeatherIcons/nsn50.jpg differ diff --git a/assets/WeatherIcons/nsn60.jpg b/assets/WeatherIcons/nsn60.jpg new file mode 100644 index 00000000..28aecc8b Binary files /dev/null and b/assets/WeatherIcons/nsn60.jpg differ diff --git a/assets/WeatherIcons/nsn70.jpg b/assets/WeatherIcons/nsn70.jpg new file mode 100644 index 00000000..809e50c3 Binary files /dev/null and b/assets/WeatherIcons/nsn70.jpg differ diff --git a/assets/WeatherIcons/nsn80.jpg b/assets/WeatherIcons/nsn80.jpg new file mode 100644 index 00000000..66be2a4f Binary files /dev/null and b/assets/WeatherIcons/nsn80.jpg differ diff --git a/assets/WeatherIcons/nsn90.jpg b/assets/WeatherIcons/nsn90.jpg new file mode 100644 index 00000000..5cbbdf69 Binary files /dev/null and b/assets/WeatherIcons/nsn90.jpg differ diff --git a/assets/WeatherIcons/nsvrtsra.jpg b/assets/WeatherIcons/nsvrtsra.jpg new file mode 100644 index 00000000..2a249335 Binary files /dev/null and b/assets/WeatherIcons/nsvrtsra.jpg differ diff --git a/assets/WeatherIcons/ntsra.jpg b/assets/WeatherIcons/ntsra.jpg new file mode 100644 index 00000000..afdcf4c5 Binary files /dev/null and b/assets/WeatherIcons/ntsra.jpg differ diff --git a/assets/WeatherIcons/ntsra10.jpg b/assets/WeatherIcons/ntsra10.jpg new file mode 100644 index 00000000..fde39f85 Binary files /dev/null and b/assets/WeatherIcons/ntsra10.jpg differ diff --git a/assets/WeatherIcons/ntsra100.jpg b/assets/WeatherIcons/ntsra100.jpg new file mode 100644 index 00000000..8593921d Binary files /dev/null and b/assets/WeatherIcons/ntsra100.jpg differ diff --git a/assets/WeatherIcons/ntsra20.jpg b/assets/WeatherIcons/ntsra20.jpg new file mode 100644 index 00000000..a1a14e89 Binary files /dev/null and b/assets/WeatherIcons/ntsra20.jpg differ diff --git a/assets/WeatherIcons/ntsra30.jpg b/assets/WeatherIcons/ntsra30.jpg new file mode 100644 index 00000000..4b6f0889 Binary files /dev/null and b/assets/WeatherIcons/ntsra30.jpg differ diff --git a/assets/WeatherIcons/ntsra40.jpg b/assets/WeatherIcons/ntsra40.jpg new file mode 100644 index 00000000..964bdc5a Binary files /dev/null and b/assets/WeatherIcons/ntsra40.jpg differ diff --git a/assets/WeatherIcons/ntsra50.jpg b/assets/WeatherIcons/ntsra50.jpg new file mode 100644 index 00000000..a0ed7c53 Binary files /dev/null and b/assets/WeatherIcons/ntsra50.jpg differ diff --git a/assets/WeatherIcons/ntsra60.jpg b/assets/WeatherIcons/ntsra60.jpg new file mode 100644 index 00000000..2e43207e Binary files /dev/null and b/assets/WeatherIcons/ntsra60.jpg differ diff --git a/assets/WeatherIcons/ntsra70.jpg b/assets/WeatherIcons/ntsra70.jpg new file mode 100644 index 00000000..04000621 Binary files /dev/null and b/assets/WeatherIcons/ntsra70.jpg differ diff --git a/assets/WeatherIcons/ntsra80.jpg b/assets/WeatherIcons/ntsra80.jpg new file mode 100644 index 00000000..5f584d55 Binary files /dev/null and b/assets/WeatherIcons/ntsra80.jpg differ diff --git a/assets/WeatherIcons/ntsra90.jpg b/assets/WeatherIcons/ntsra90.jpg new file mode 100644 index 00000000..2c548206 Binary files /dev/null and b/assets/WeatherIcons/ntsra90.jpg differ diff --git a/assets/WeatherIcons/nwind.jpg b/assets/WeatherIcons/nwind.jpg new file mode 100644 index 00000000..a2952dbc Binary files /dev/null and b/assets/WeatherIcons/nwind.jpg differ diff --git a/assets/WeatherIcons/ovc.jpg b/assets/WeatherIcons/ovc.jpg new file mode 100644 index 00000000..c5d00b58 Binary files /dev/null and b/assets/WeatherIcons/ovc.jpg differ diff --git a/assets/WeatherIcons/pcloudy.jpg b/assets/WeatherIcons/pcloudy.jpg new file mode 100644 index 00000000..2c4f00c7 Binary files /dev/null and b/assets/WeatherIcons/pcloudy.jpg differ diff --git a/assets/WeatherIcons/ra.jpg b/assets/WeatherIcons/ra.jpg new file mode 100644 index 00000000..822cb22e Binary files /dev/null and b/assets/WeatherIcons/ra.jpg differ diff --git a/assets/WeatherIcons/ra1.jpg b/assets/WeatherIcons/ra1.jpg new file mode 100644 index 00000000..bf8d7fc7 Binary files /dev/null and b/assets/WeatherIcons/ra1.jpg differ diff --git a/assets/WeatherIcons/ra10.jpg b/assets/WeatherIcons/ra10.jpg new file mode 100644 index 00000000..2a784e35 Binary files /dev/null and b/assets/WeatherIcons/ra10.jpg differ diff --git a/assets/WeatherIcons/ra100.jpg b/assets/WeatherIcons/ra100.jpg new file mode 100644 index 00000000..0c50a60c Binary files /dev/null and b/assets/WeatherIcons/ra100.jpg differ diff --git a/assets/WeatherIcons/ra20.jpg b/assets/WeatherIcons/ra20.jpg new file mode 100644 index 00000000..3694e7ff Binary files /dev/null and b/assets/WeatherIcons/ra20.jpg differ diff --git a/assets/WeatherIcons/ra30.jpg b/assets/WeatherIcons/ra30.jpg new file mode 100644 index 00000000..e2f006e6 Binary files /dev/null and b/assets/WeatherIcons/ra30.jpg differ diff --git a/assets/WeatherIcons/ra40.jpg b/assets/WeatherIcons/ra40.jpg new file mode 100644 index 00000000..1c4cf762 Binary files /dev/null and b/assets/WeatherIcons/ra40.jpg differ diff --git a/assets/WeatherIcons/ra50.jpg b/assets/WeatherIcons/ra50.jpg new file mode 100644 index 00000000..1225dbd4 Binary files /dev/null and b/assets/WeatherIcons/ra50.jpg differ diff --git a/assets/WeatherIcons/ra60.jpg b/assets/WeatherIcons/ra60.jpg new file mode 100644 index 00000000..766e0f8d Binary files /dev/null and b/assets/WeatherIcons/ra60.jpg differ diff --git a/assets/WeatherIcons/ra70.jpg b/assets/WeatherIcons/ra70.jpg new file mode 100644 index 00000000..2883bc96 Binary files /dev/null and b/assets/WeatherIcons/ra70.jpg differ diff --git a/assets/WeatherIcons/ra80.jpg b/assets/WeatherIcons/ra80.jpg new file mode 100644 index 00000000..19846aba Binary files /dev/null and b/assets/WeatherIcons/ra80.jpg differ diff --git a/assets/WeatherIcons/ra90.jpg b/assets/WeatherIcons/ra90.jpg new file mode 100644 index 00000000..4610337a Binary files /dev/null and b/assets/WeatherIcons/ra90.jpg differ diff --git a/assets/WeatherIcons/raip.jpg b/assets/WeatherIcons/raip.jpg new file mode 100644 index 00000000..c2d6f7b4 Binary files /dev/null and b/assets/WeatherIcons/raip.jpg differ diff --git a/assets/WeatherIcons/raip10.jpg b/assets/WeatherIcons/raip10.jpg new file mode 100644 index 00000000..ffb9995e Binary files /dev/null and b/assets/WeatherIcons/raip10.jpg differ diff --git a/assets/WeatherIcons/raip100.jpg b/assets/WeatherIcons/raip100.jpg new file mode 100644 index 00000000..a506e537 Binary files /dev/null and b/assets/WeatherIcons/raip100.jpg differ diff --git a/assets/WeatherIcons/raip20.jpg b/assets/WeatherIcons/raip20.jpg new file mode 100644 index 00000000..08a8a833 Binary files /dev/null and b/assets/WeatherIcons/raip20.jpg differ diff --git a/assets/WeatherIcons/raip30.jpg b/assets/WeatherIcons/raip30.jpg new file mode 100644 index 00000000..34f6e68e Binary files /dev/null and b/assets/WeatherIcons/raip30.jpg differ diff --git a/assets/WeatherIcons/raip40.jpg b/assets/WeatherIcons/raip40.jpg new file mode 100644 index 00000000..cf151fed Binary files /dev/null and b/assets/WeatherIcons/raip40.jpg differ diff --git a/assets/WeatherIcons/raip50.jpg b/assets/WeatherIcons/raip50.jpg new file mode 100644 index 00000000..10605673 Binary files /dev/null and b/assets/WeatherIcons/raip50.jpg differ diff --git a/assets/WeatherIcons/raip60.jpg b/assets/WeatherIcons/raip60.jpg new file mode 100644 index 00000000..7c02ed98 Binary files /dev/null and b/assets/WeatherIcons/raip60.jpg differ diff --git a/assets/WeatherIcons/raip70.jpg b/assets/WeatherIcons/raip70.jpg new file mode 100644 index 00000000..b2f30ea2 Binary files /dev/null and b/assets/WeatherIcons/raip70.jpg differ diff --git a/assets/WeatherIcons/raip80.jpg b/assets/WeatherIcons/raip80.jpg new file mode 100644 index 00000000..ace292f6 Binary files /dev/null and b/assets/WeatherIcons/raip80.jpg differ diff --git a/assets/WeatherIcons/raip90.jpg b/assets/WeatherIcons/raip90.jpg new file mode 100644 index 00000000..88cee7dd Binary files /dev/null and b/assets/WeatherIcons/raip90.jpg differ diff --git a/assets/WeatherIcons/rasn.jpg b/assets/WeatherIcons/rasn.jpg new file mode 100644 index 00000000..77e31d51 Binary files /dev/null and b/assets/WeatherIcons/rasn.jpg differ diff --git a/assets/WeatherIcons/rasn10.jpg b/assets/WeatherIcons/rasn10.jpg new file mode 100644 index 00000000..62116ecd Binary files /dev/null and b/assets/WeatherIcons/rasn10.jpg differ diff --git a/assets/WeatherIcons/rasn100.jpg b/assets/WeatherIcons/rasn100.jpg new file mode 100644 index 00000000..e681b3ed Binary files /dev/null and b/assets/WeatherIcons/rasn100.jpg differ diff --git a/assets/WeatherIcons/rasn20.jpg b/assets/WeatherIcons/rasn20.jpg new file mode 100644 index 00000000..39d54627 Binary files /dev/null and b/assets/WeatherIcons/rasn20.jpg differ diff --git a/assets/WeatherIcons/rasn30.jpg b/assets/WeatherIcons/rasn30.jpg new file mode 100644 index 00000000..70321bc6 Binary files /dev/null and b/assets/WeatherIcons/rasn30.jpg differ diff --git a/assets/WeatherIcons/rasn40.jpg b/assets/WeatherIcons/rasn40.jpg new file mode 100644 index 00000000..3e1b2d98 Binary files /dev/null and b/assets/WeatherIcons/rasn40.jpg differ diff --git a/assets/WeatherIcons/rasn50.jpg b/assets/WeatherIcons/rasn50.jpg new file mode 100644 index 00000000..02077607 Binary files /dev/null and b/assets/WeatherIcons/rasn50.jpg differ diff --git a/assets/WeatherIcons/rasn60.jpg b/assets/WeatherIcons/rasn60.jpg new file mode 100644 index 00000000..8215672d Binary files /dev/null and b/assets/WeatherIcons/rasn60.jpg differ diff --git a/assets/WeatherIcons/rasn70.jpg b/assets/WeatherIcons/rasn70.jpg new file mode 100644 index 00000000..c2c4edd4 Binary files /dev/null and b/assets/WeatherIcons/rasn70.jpg differ diff --git a/assets/WeatherIcons/rasn80.jpg b/assets/WeatherIcons/rasn80.jpg new file mode 100644 index 00000000..2486aea4 Binary files /dev/null and b/assets/WeatherIcons/rasn80.jpg differ diff --git a/assets/WeatherIcons/rasn90.jpg b/assets/WeatherIcons/rasn90.jpg new file mode 100644 index 00000000..3b8a805a Binary files /dev/null and b/assets/WeatherIcons/rasn90.jpg differ diff --git a/assets/WeatherIcons/sct.jpg b/assets/WeatherIcons/sct.jpg new file mode 100644 index 00000000..4f813f81 Binary files /dev/null and b/assets/WeatherIcons/sct.jpg differ diff --git a/assets/WeatherIcons/scttsra.jpg b/assets/WeatherIcons/scttsra.jpg new file mode 100644 index 00000000..1feecb6f Binary files /dev/null and b/assets/WeatherIcons/scttsra.jpg differ diff --git a/assets/WeatherIcons/scttsra10.jpg b/assets/WeatherIcons/scttsra10.jpg new file mode 100644 index 00000000..90e74f1a Binary files /dev/null and b/assets/WeatherIcons/scttsra10.jpg differ diff --git a/assets/WeatherIcons/scttsra100.jpg b/assets/WeatherIcons/scttsra100.jpg new file mode 100644 index 00000000..ff5a794e Binary files /dev/null and b/assets/WeatherIcons/scttsra100.jpg differ diff --git a/assets/WeatherIcons/scttsra20.jpg b/assets/WeatherIcons/scttsra20.jpg new file mode 100644 index 00000000..dcf2a745 Binary files /dev/null and b/assets/WeatherIcons/scttsra20.jpg differ diff --git a/assets/WeatherIcons/scttsra30.jpg b/assets/WeatherIcons/scttsra30.jpg new file mode 100644 index 00000000..a232d5e9 Binary files /dev/null and b/assets/WeatherIcons/scttsra30.jpg differ diff --git a/assets/WeatherIcons/scttsra40.jpg b/assets/WeatherIcons/scttsra40.jpg new file mode 100644 index 00000000..7e6a0cd3 Binary files /dev/null and b/assets/WeatherIcons/scttsra40.jpg differ diff --git a/assets/WeatherIcons/scttsra50.jpg b/assets/WeatherIcons/scttsra50.jpg new file mode 100644 index 00000000..6d83d4c5 Binary files /dev/null and b/assets/WeatherIcons/scttsra50.jpg differ diff --git a/assets/WeatherIcons/scttsra60.jpg b/assets/WeatherIcons/scttsra60.jpg new file mode 100644 index 00000000..182ee13e Binary files /dev/null and b/assets/WeatherIcons/scttsra60.jpg differ diff --git a/assets/WeatherIcons/scttsra70.jpg b/assets/WeatherIcons/scttsra70.jpg new file mode 100644 index 00000000..710239cf Binary files /dev/null and b/assets/WeatherIcons/scttsra70.jpg differ diff --git a/assets/WeatherIcons/scttsra80.jpg b/assets/WeatherIcons/scttsra80.jpg new file mode 100644 index 00000000..1f7210a0 Binary files /dev/null and b/assets/WeatherIcons/scttsra80.jpg differ diff --git a/assets/WeatherIcons/scttsra90.jpg b/assets/WeatherIcons/scttsra90.jpg new file mode 100644 index 00000000..c63a06b4 Binary files /dev/null and b/assets/WeatherIcons/scttsra90.jpg differ diff --git a/assets/WeatherIcons/shra.jpg b/assets/WeatherIcons/shra.jpg new file mode 100644 index 00000000..412afc83 Binary files /dev/null and b/assets/WeatherIcons/shra.jpg differ diff --git a/assets/WeatherIcons/shra10.jpg b/assets/WeatherIcons/shra10.jpg new file mode 100644 index 00000000..9a9eb2e6 Binary files /dev/null and b/assets/WeatherIcons/shra10.jpg differ diff --git a/assets/WeatherIcons/shra100.jpg b/assets/WeatherIcons/shra100.jpg new file mode 100644 index 00000000..d332687d Binary files /dev/null and b/assets/WeatherIcons/shra100.jpg differ diff --git a/assets/WeatherIcons/shra2.jpg b/assets/WeatherIcons/shra2.jpg new file mode 100644 index 00000000..69fe76b2 Binary files /dev/null and b/assets/WeatherIcons/shra2.jpg differ diff --git a/assets/WeatherIcons/shra20.jpg b/assets/WeatherIcons/shra20.jpg new file mode 100644 index 00000000..ac617d38 Binary files /dev/null and b/assets/WeatherIcons/shra20.jpg differ diff --git a/assets/WeatherIcons/shra30.jpg b/assets/WeatherIcons/shra30.jpg new file mode 100644 index 00000000..7060308d Binary files /dev/null and b/assets/WeatherIcons/shra30.jpg differ diff --git a/assets/WeatherIcons/shra40.jpg b/assets/WeatherIcons/shra40.jpg new file mode 100644 index 00000000..caad9784 Binary files /dev/null and b/assets/WeatherIcons/shra40.jpg differ diff --git a/assets/WeatherIcons/shra50.jpg b/assets/WeatherIcons/shra50.jpg new file mode 100644 index 00000000..2e4196cc Binary files /dev/null and b/assets/WeatherIcons/shra50.jpg differ diff --git a/assets/WeatherIcons/shra60.jpg b/assets/WeatherIcons/shra60.jpg new file mode 100644 index 00000000..07d563a5 Binary files /dev/null and b/assets/WeatherIcons/shra60.jpg differ diff --git a/assets/WeatherIcons/shra70.jpg b/assets/WeatherIcons/shra70.jpg new file mode 100644 index 00000000..25c7e860 Binary files /dev/null and b/assets/WeatherIcons/shra70.jpg differ diff --git a/assets/WeatherIcons/shra80.jpg b/assets/WeatherIcons/shra80.jpg new file mode 100644 index 00000000..20984712 Binary files /dev/null and b/assets/WeatherIcons/shra80.jpg differ diff --git a/assets/WeatherIcons/shra90.jpg b/assets/WeatherIcons/shra90.jpg new file mode 100644 index 00000000..708f5fc2 Binary files /dev/null and b/assets/WeatherIcons/shra90.jpg differ diff --git a/assets/WeatherIcons/skc.jpg b/assets/WeatherIcons/skc.jpg new file mode 100644 index 00000000..6ebbbf0b Binary files /dev/null and b/assets/WeatherIcons/skc.jpg differ diff --git a/assets/WeatherIcons/smoke.jpg b/assets/WeatherIcons/smoke.jpg new file mode 100644 index 00000000..9c921c7e Binary files /dev/null and b/assets/WeatherIcons/smoke.jpg differ diff --git a/assets/WeatherIcons/sn.jpg b/assets/WeatherIcons/sn.jpg new file mode 100644 index 00000000..74119b93 Binary files /dev/null and b/assets/WeatherIcons/sn.jpg differ diff --git a/assets/WeatherIcons/sn10.jpg b/assets/WeatherIcons/sn10.jpg new file mode 100644 index 00000000..10f67905 Binary files /dev/null and b/assets/WeatherIcons/sn10.jpg differ diff --git a/assets/WeatherIcons/sn100.jpg b/assets/WeatherIcons/sn100.jpg new file mode 100644 index 00000000..a96be976 Binary files /dev/null and b/assets/WeatherIcons/sn100.jpg differ diff --git a/assets/WeatherIcons/sn20.jpg b/assets/WeatherIcons/sn20.jpg new file mode 100644 index 00000000..23a56ba3 Binary files /dev/null and b/assets/WeatherIcons/sn20.jpg differ diff --git a/assets/WeatherIcons/sn30.jpg b/assets/WeatherIcons/sn30.jpg new file mode 100644 index 00000000..71696680 Binary files /dev/null and b/assets/WeatherIcons/sn30.jpg differ diff --git a/assets/WeatherIcons/sn40.jpg b/assets/WeatherIcons/sn40.jpg new file mode 100644 index 00000000..309fb57f Binary files /dev/null and b/assets/WeatherIcons/sn40.jpg differ diff --git a/assets/WeatherIcons/sn50.jpg b/assets/WeatherIcons/sn50.jpg new file mode 100644 index 00000000..0d67ef50 Binary files /dev/null and b/assets/WeatherIcons/sn50.jpg differ diff --git a/assets/WeatherIcons/sn60.jpg b/assets/WeatherIcons/sn60.jpg new file mode 100644 index 00000000..aa346fdb Binary files /dev/null and b/assets/WeatherIcons/sn60.jpg differ diff --git a/assets/WeatherIcons/sn70.jpg b/assets/WeatherIcons/sn70.jpg new file mode 100644 index 00000000..e60fd3bf Binary files /dev/null and b/assets/WeatherIcons/sn70.jpg differ diff --git a/assets/WeatherIcons/sn80.jpg b/assets/WeatherIcons/sn80.jpg new file mode 100644 index 00000000..6a1fb952 Binary files /dev/null and b/assets/WeatherIcons/sn80.jpg differ diff --git a/assets/WeatherIcons/sn90.jpg b/assets/WeatherIcons/sn90.jpg new file mode 100644 index 00000000..6bca4d9b Binary files /dev/null and b/assets/WeatherIcons/sn90.jpg differ diff --git a/assets/WeatherIcons/tcu.jpg b/assets/WeatherIcons/tcu.jpg new file mode 100644 index 00000000..37cc4a62 Binary files /dev/null and b/assets/WeatherIcons/tcu.jpg differ diff --git a/assets/WeatherIcons/tsra.jpg b/assets/WeatherIcons/tsra.jpg new file mode 100644 index 00000000..ce0c1fa4 Binary files /dev/null and b/assets/WeatherIcons/tsra.jpg differ diff --git a/assets/WeatherIcons/tsra10.jpg b/assets/WeatherIcons/tsra10.jpg new file mode 100644 index 00000000..e442b210 Binary files /dev/null and b/assets/WeatherIcons/tsra10.jpg differ diff --git a/assets/WeatherIcons/tsra100.jpg b/assets/WeatherIcons/tsra100.jpg new file mode 100644 index 00000000..3d712e90 Binary files /dev/null and b/assets/WeatherIcons/tsra100.jpg differ diff --git a/assets/WeatherIcons/tsra20.jpg b/assets/WeatherIcons/tsra20.jpg new file mode 100644 index 00000000..e2b0b774 Binary files /dev/null and b/assets/WeatherIcons/tsra20.jpg differ diff --git a/assets/WeatherIcons/tsra30.jpg b/assets/WeatherIcons/tsra30.jpg new file mode 100644 index 00000000..9768cb9a Binary files /dev/null and b/assets/WeatherIcons/tsra30.jpg differ diff --git a/assets/WeatherIcons/tsra40.jpg b/assets/WeatherIcons/tsra40.jpg new file mode 100644 index 00000000..479996e8 Binary files /dev/null and b/assets/WeatherIcons/tsra40.jpg differ diff --git a/assets/WeatherIcons/tsra50.jpg b/assets/WeatherIcons/tsra50.jpg new file mode 100644 index 00000000..c749931d Binary files /dev/null and b/assets/WeatherIcons/tsra50.jpg differ diff --git a/assets/WeatherIcons/tsra60.jpg b/assets/WeatherIcons/tsra60.jpg new file mode 100644 index 00000000..6e4185e6 Binary files /dev/null and b/assets/WeatherIcons/tsra60.jpg differ diff --git a/assets/WeatherIcons/tsra70.jpg b/assets/WeatherIcons/tsra70.jpg new file mode 100644 index 00000000..6ff751a3 Binary files /dev/null and b/assets/WeatherIcons/tsra70.jpg differ diff --git a/assets/WeatherIcons/tsra80.jpg b/assets/WeatherIcons/tsra80.jpg new file mode 100644 index 00000000..2dfd96f4 Binary files /dev/null and b/assets/WeatherIcons/tsra80.jpg differ diff --git a/assets/WeatherIcons/tsra90.jpg b/assets/WeatherIcons/tsra90.jpg new file mode 100644 index 00000000..ed92c024 Binary files /dev/null and b/assets/WeatherIcons/tsra90.jpg differ diff --git a/assets/WeatherIcons/wind.jpg b/assets/WeatherIcons/wind.jpg new file mode 100644 index 00000000..a9834efd Binary files /dev/null and b/assets/WeatherIcons/wind.jpg differ diff --git a/classes/data/dataCities.php b/classes/data/dataCities.php index 57681df6..89347d1c 100644 --- a/classes/data/dataCities.php +++ b/classes/data/dataCities.php @@ -225,6 +225,33 @@ class GlmDataCities extends GlmDataAbstract return $cities; } -} + /* + * Get Alpha list of first characters in member name + * for those members that have active info. + * + * @param string $where Where clause + * Note the table refernces M and I. + * @param string $selected Optional selected alpha character + * + * @return object Class object + * + */ + public function getAlphaList( $where = '', $selected = '' ) + { + $sql = " + SELECT DISTINCT LEFT(T.name, 1) AS alpha + FROM ".GLM_MEMBERS_PLUGIN_DB_PREFIX. "cities T + WHERE true $where + ORDER BY alpha"; -?> + $alphaData = $this->wpdb->get_results($sql, ARRAY_A); + + // Set selected + foreach ($alphaData as $k=>$v) { + $alphaData[$k]['default'] = ($v['alpha'] == $selected); + } + + return $alphaData; + } + +} diff --git a/index.php b/index.php index 3a15559c..454e7a9f 100755 --- a/index.php +++ b/index.php @@ -48,7 +48,7 @@ if (!defined('ABSPATH')) { */ define('GLM_MEMBERS_PLUGIN_VERSION', '2.10.45'); -define('GLM_MEMBERS_PLUGIN_DB_VERSION', '1.1.43'); +define('GLM_MEMBERS_PLUGIN_DB_VERSION', '1.1.44'); // Check if plugin version is not current in WordPress option and if needed updated it if (GLM_MEMBERS_PLUGIN_VERSION != get_option('glmMembersDatabasePluginVersion')) { diff --git a/models/front/members/cityWeather.php b/models/front/members/cityWeather.php new file mode 100644 index 00000000..b67cd160 --- /dev/null +++ b/models/front/members/cityWeather.php @@ -0,0 +1,413 @@ + + * @license http://www.gaslightmedia.com Gaslightmedia + * @version 0.1 + */ + + +// Load Members data abstract +require_once GLM_MEMBERS_PLUGIN_CLASS_PATH.'/data/dataCities.php'; + +/* + * This class performs the work for the default action of the "Members" menu + * option, which is to display the members dashboard. + * + */ +class GlmMembersFront_members_cityWeather extends GlmDataCities +{ + + /** + * WordPress Database Object + * + * @var $wpdb + * @access public + */ + public $wpdb; + /** + * Plugin Configuration Data + * + * @var $config + * @access public + */ + public $config; + + /* + * Constructor + * + * This contructor sets up this model. At this time that only includes + * storing away the WordPress data object. + * + * @return object Class object + * + */ + public function __construct ($wpdb, $config) + { + + // Save WordPress Database object + $this->wpdb = $wpdb; + + // Save plugin configuration object + $this->config = $config; + + // Run constructor for members data class + parent::__construct(false, false); + + } + + /* + * Perform Model Action + * + * This method does the work for this model and returns any resulting data + * + * @return array Status and data array + * + * 'status' + * + * True if successful and false if there was a fatal failure. + * + * 'menuItemRedirect' + * + * If not false, provides a menu item the controller should + * execute after this one. Normally if this is used, there would also be a + * modelRedirect value supplied as well. + * + * 'modelRedirect' + * + * If not false, provides an action the controller should execute after + * this one. + * + * 'view' + * + * A suggested view name that the contoller should use instead of the + * default view for this model or false to indicate that the default view + * should be used. + * + * 'data' + * + * Data that the model is returning for use in merging with the view to + * produce output. + * + */ + public function modelAction ( $actionData = false ) + { + $settings = array(); + $success = true; + $alpha = 'A'; + $alphaList = false; + $latbounds = + $latbounds = false; + + if ( $actionData['request']['lon-bounds'] ) { + $latbounds = $actionData['request']['lat-bounds']; + } + + if ( $actionData['request']['lon-bounds'] ) { + $lonbounds = $actionData['request']['lon-bounds']; + } + + // for current weather + $this->now = mktime( + date('H') + 1, + date('i'), + date('s'), + date('m'), + date('d'), + date('Y')); + + // for weather caching + $this->validTime = mktime( + date('H') - 24, + date('i'), + date('s'), + date('m'), + date('d'), + date('Y')); + + if ( isset( $_REQUEST['alpha'] ) && $_REQUEST['alpha'] ) { + $alpha = filter_var( $_REQUEST['alpha'], FILTER_SANITIZE_STRING ); + } + + $alphaList = $this->getAlphaList(' AND T.lat IS NOT NULL AND lon IS NOT NULL ', $alpha); + + $alphaSelected = strtoupper( $alpha ); + + $where = " T.name LIKE '$alphaSelected%'"; + + $cities = $this->getList( $where, 'name' ); + + if ( $cities ) { + foreach ( $cities as &$city ) { + $cWeather = $this->checkWeather( $city['id'] ); + if ( $cWeather ) { + $icon_url = parse_url( $cWeather['icon'] ); + // echo '
$icon_url: ' . print_r( $icon_url, true ) . '
'; + $icon_file = basename( $icon_url['path'] ); + // echo '
$icon_file: ' . print_r( $icon_file, true ) . '
'; + $city['temp_max'] = $cWeather['temp_max']; + $city['temp_min'] = $cWeather['temp_min']; + $city['weather'] = $cWeather['weather']; + $city['moreinfo'] = $cWeather['moreinfo']; + $city['icon'] = $icon_file; + } else { + $city['temp_max'] = ''; + $city['temp_min'] = ''; + $city['weather'] = 'N/A'; + $city['moreinfo'] = ''; + $city['icon'] = ''; + } + } + } + + $templateData = array( + 'jsUrl' => GLM_MEMBERS_PLUGIN_JS_URL, + 'cities' => $cities, + 'icon_url_path' => GLM_MEMBERS_PLUGIN_ASSETS_URL . '/WeatherIcons', + 'alphaList' => $alphaList, + ); + + // Return status, suggested view, and data to controller - also return any modified settings + return array( + 'status' => $success, + 'menuItemRedirect' => false, + 'modelRedirect' => false, + 'view' => "front/members/cityWeather.html", + 'data' => $templateData, + 'settings' => $settings, + ); + + } + + /** + * Lookup data from zip database to get the lat lon for the city + * given it's city_id + * need lookup from city table to get city_name + * use city_alias field in zip database + * + * @param mixed $cid city_id from city table + * + * @access public + * @return string + */ + function getLatLonForCity( $city_id ) + { + return $this->wpdb->get_row( + $this->wpdb->prepare( + "SELECT lat,lon + FROM " . GLM_MEMBERS_PLUGIN_DB_PREFIX . "cities + WHERE id = %d", + $city_id + ), + ARRAY_A + ); + } + + /** + * Checks to see if there's current weather in the database + * if not then it will go out to get current ndfd data from noaa + * these are 24 hour weather-summaries and they are reloaded + * when needed after 24 hours. + * You can change the time it refreshes thes by changing the + * $this->validTime variable. + * + * @param int $cid City id from city table + * + * @access public + * @return string + */ + function checkWeather( $cid ) + { + static $validTime; + $update = false; + if (!$validTime) { + $validTime = date("m/d/Y", $this->validTime); + } + + // get current db data for city weather + $weatherData = $this->wpdb->get_row( + $this->wpdb->prepare( + "SELECT temp_max,temp_min,icon,weather,moreinfo,wx_time + FROM " . GLM_MEMBERS_PLUGIN_DB_PREFIX . "cities + WHERE id = %d", + $cid + ), + ARRAY_A + ); + // convert date to timestamp + $wx_time = strtotime( $weatherData['wx_time'] ); + + if ( ( (int)$wx_time <= $this->validTime ) || $weatherData['weather'] == '' ) { + $update = true; + } else { + return $weatherData; + } + // echo '
$update: ' . print_r( $update, true ) . '
'; + // check the valid time if is older that $this->validTime + // then set update true + if ( $update ) { + // do lookup for lat lon + $llData = $this->getLatLonForCity( $cid ); + $weatherData = $this->pullWeather( $llData['lat'], $llData['lon'] ); + } + if ( $update && $weatherData['weather'] ) { + $this->wpdb->update( + GLM_MEMBERS_PLUGIN_DB_PREFIX . 'cities', + array( + 'temp_max' => $weatherData['temp_max'], + 'temp_min' => $weatherData['temp_min'], + 'icon' => $weatherData['icon'], + 'weather' => $weatherData['weather'], + 'moreinfo' => $weatherData['moreinfo'], + 'wx_time' => date( 'Y-m-d H:i:s' ) + ), + array( 'id' => $cid ), + array( + '%s', + '%s', + '%s', + '%s', + '%s', + '%s' + ), + array( '%d' ) + ); + } + // if there's no weather then return false + if ($weatherData['weather']) { + return $weatherData; + } else { + return false; + } + } + + /** + * pull the weather feed and give a return string to use + * + * @param unknown $lat Latitude + North - South + * @param unknown $lon Longitude + East - West + * + * @return void + * @access public + */ + function pullWeather( $lat, $lon ) + { + try { + $client = new SoapClient( + 'https://graphical.weather.gov/xml/DWMLgen/wsdl/ndfdXML.wsdl', + array( + 'trace' => true, + 'exceptions' => false, + 'connection_timeout' => '60', + 'soap_version' => 'SOAP 1.2', + 'exceptions' => '1', + 'cache_wsdl' => WSDL_CACHE_NONE, + 'stream_context' => stream_context_create( + array( + 'http' => array( + 'user_agent' => 'PHP/SoapClient' + ) + ) + ) + ) + ); + $res2 = $client->__soapCall( + 'NDFDgenByDayLatLonList', + array( + 'listLatLon' => $lat.','.$lon, + 'startDate' => date('Y-m-d', $this->now), + 'numdays' => '1', + 'units' => 'e', + 'format' => '24 hourly' + ) + ); + $result = $this->cleanUpXml($client->__getLastResponse()); + + // create a new SimpleXmlElement with clean xml + $xml = new SimpleXmlElement($result); + // get condition icon url + // icon + $condIcon = $xml->xpath('//icon-link'); + $icon = $condIcon[0]; + + // more_info + $link = $xml->xpath('//moreWeatherInformation'); + $moreinfo = $link[0]; + + // temp_max + $tempAppt = $xml->xpath('//temperature[@type="maximum"]'); + $temp_max = $tempAppt[0]->value; + + // temp_min + $tempAppt = $xml->xpath('//temperature[@type="minimum"]'); + $temp_min = $tempAppt[0]->value; + + // weather + $wxSummary = $xml->xpath('//weather/weather-conditions'); + foreach ($wxSummary[0]->attributes() as $wxkey => $wxval) { + $weather = $wxval; + } + return array( + 'temp_max' => $temp_max, + 'temp_min' => $temp_min, + 'icon' => $icon, + 'weather' => $weather, + 'moreinfo' => $moreinfo, + ); + } catch (SoapFault $fault) { + // let's just give message of no data + // or just return empty array + return false; + + } + } + + /** + * Clean up the returning xml format from ndfd data + * to be used in SimpleXml + * + * @param string $xml Xml from SoapClient lastResponse call + * + * @return string well formated xml for SimpleXml + * @access public + */ + function cleanUpXml($xml) + { + $xml = htmlspecialchars_decode($xml); + $patterns[] = "//"; + $patterns[] = "/ version='1.0'/"; + $patterns[] = "//"; + $patterns[] = "//"; + $patterns[] = "//"; + $patterns[] = "//"; + $patterns[] = "//"; + $patterns[] = "//"; + $patterns[] = "//"; + $patterns[] = "//"; + $patterns[] = "//"; + $patterns[] = "//"; + $patterns[] = "/<\/listLatLonOut>/"; + $patterns[] = "/<\/dwmlOut>/"; + $patterns[] = "/<\/dwmlByDayOut>/"; + $patterns[] = "/<\/ns1:LatLonListZipCodeResponse>/"; + $patterns[] = "/<\/ns1:NDFDgenByDayResponse>/"; + $patterns[] = "/<\/ns1:NDFDgenLatLonListResponse>/"; + $patterns[] = "/<\/ns1:NDFDgenByDayLatLonListResponse>/"; + $patterns[] = "/<\/ns1:NDFDgenResponse>/"; + $patterns[] = "/<\/SOAP-ENV:Body>/"; + $patterns[] = "/<\/SOAP-ENV:Envelope>/"; + foreach ($patterns as $pattern) { + $xml = preg_replace($pattern, "", $xml); + } + return $xml; + } + + +} diff --git a/setup/databaseScripts/create_database_V1.1.43.sql b/setup/databaseScripts/create_database_V1.1.43.sql deleted file mode 100755 index ed453876..00000000 --- a/setup/databaseScripts/create_database_V1.1.43.sql +++ /dev/null @@ -1,698 +0,0 @@ --- Gaslight Media Members Database --- File Created: 12/29/16 12:06:00 --- Database Version: 1.1.41 --- Database Creation Script --- --- To permit each query below to be executed separately, --- all queries must be separated by a line with four dashes --- --- **** BE SURE TO ALSO UPDATE drop_database_Vxxx.sql FILE WHEN CHANGING TABLES **** --- - --- Amenities -CREATE TABLE {prefix}amenities ( - id INT NOT NULL AUTO_INCREMENT, - active TINYINT(1) NULL, -- Amenity is active flag - name TINYTEXT NULL, -- Name of amenity - descr TEXT NULL, -- Description of amenity - short_descr TINYTEXT NULL, -- Short description of amenity - ref_type INT NULL, -- Type of entity these amenities are associated with - see plugin.ini ref_type tables - uses_value BOOLEAN NULL, -- Flag indicating whether the amenity requires a quantity number - PRIMARY KEY (id), - INDEX(name(20)) -); - ----- - --- Amenity Reference - Links a specific amenity to a specific entity of type ref_type -CREATE TABLE {prefix}amenity_ref ( - id INT NOT NULL AUTO_INCREMENT, - amenity INT NULL, -- Pointer to amenity in amenities table - ref_type INT NULL, -- Copy of ref_type from matching amenities table entry - to simplify searches - ref_dest INT NULL, -- Pointer to the specific entity of type ref_type - amenity_value TINYTEXT NULL, -- Quantity if amenity uses values - PRIMARY KEY (id), - INDEX(ref_type), - INDEX(ref_dest) -); - ----- - --- groups -CREATE TABLE {prefix}amenity_groups ( - id INT NOT NULL AUTO_INCREMENT, - name TINYTEXT NULL, -- Name of the Group - PRIMARY KEY (id), - INDEX(name(20)) -); - ----- - --- Amenity Group - Links a specific amenity to groups -CREATE TABLE {prefix}grouped_amenities ( - id INT NOT NULL AUTO_INCREMENT, - group_id INT, -- Pointer to the group - amenity_id INT, -- Pointer to the Amenity - searchable BOOLEAN DEFAULT '0', -- Flag indicating whether the amenity group will show in the search form - PRIMARY KEY (id) -); - ----- - --- Member Cateogries - used with member information records -CREATE TABLE {prefix}categories ( - id INT NOT NULL AUTO_INCREMENT, - name TINYTEXT NULL, -- Name of this category - descr TEXT NULL, -- Description of this category - short_descr TINYTEXT NULL, -- Short description of this category - parent INT NULL, -- Pointer to parent category in this table - if there is one - PRIMARY KEY (id) -); - ----- - --- Mapping of categories to specific member information records -CREATE TABLE {prefix}category_member_info ( - id INT NOT NULL AUTO_INCREMENT, - category INT NULL, -- Pointer to category in categories table - member_info INT NULL, -- Pointer to member information record - PRIMARY KEY (id), - CONSTRAINT {prefix}categories_fk_1 - FOREIGN KEY (category) - REFERENCES {prefix}categories (id) - ON DELETE CASCADE, - INDEX(category), - INDEX(member_info) -); - ----- - --- Cities -CREATE TABLE {prefix}cities ( - id INT NOT NULL AUTO_INCREMENT, - name TINYTEXT NULL, -- Name of city - lat FLOAT NULL, -- Latitude of city's location - lon FLOAT NULL, -- Longitude of city's location - county INT NULL, -- County reference to county table - PRIMARY KEY (id) -); - ----- - --- Member Click Through Stats Data - Totals of URL click-throughs - Preserved for 2 years -CREATE TABLE {prefix}clickthrough_stats ( - member INT NOT NULL, -- ID of member - stat_type INT NOT NULL, -- Type of stat 1 = day, 2 = week, 3 = month - stat_date DATE NOT NULL, -- Date for which these stats are accumulated (date or first date of week or month) - clicks INT NULL, -- Number of Clicks - PRIMARY KEY (member, stat_type, stat_date), - INDEX (member), - INDEX (stat_type), - INDEX (stat_date) -); - ----- - --- Files - Files are stored under /wp-content/uploads/glm-member-db/files/ -CREATE TABLE {prefix}files ( - id INT NOT NULL AUTO_INCREMENT, - name TINYTEXT NULL, -- Original name of the file - might be URL if copied via HTTP - status TINYINT(1) NULL, -- Display/Use status - See plugin.ini status table - file_name TINYTEXT NULL, -- Stored file name for the file - descr TEXT NULL, -- Description - caption TINYTEXT NULL, -- Caption for the image - position INT NULL, -- Numeric position for sequence of display - ref_type INT NULL, -- Type of entity this image is associated with - ref_dest INT NULL, -- Pointer to the specific entity of ref_type this image is associated with - PRIMARY KEY (id), - INDEX(name(20)), - INDEX(file_name(20)), - INDEX(ref_type), - INDEX(ref_dest) -); - ----- - --- Images - Images are stored under /wp-content/uploads/glm-member-db/images/{size}/ -CREATE TABLE {prefix}images ( - id INT NOT NULL AUTO_INCREMENT, - name TINYTEXT NULL, -- Original name of the image - might be URL if copied via HTTP - status TINYINT(1) NULL, -- Display/Use status - See plugin.ini status table - selected BOOLEAN NULL, -- A single special image in the current gallery for this entity - featured BOOLEAN null, -- Image is a member of a group of featured images - file_name TINYTEXT NULL, -- Stored file name for the image - descr TEXT NULL, -- Description - caption TINYTEXT NULL, -- Caption for the image - position INT NULL, -- Numeric position for sequence of display - ref_type INT NULL, -- Type of entity this image is associated with - ref_dest INT NULL, -- Pointer to the specific entity of ref_type this image is associated with - PRIMARY KEY (id), - INDEX(name(20)), - INDEX(file_name(20)), - INDEX(ref_type), - INDEX(ref_dest) -); - ----- - --- Primary member records - One for each member -CREATE TABLE {prefix}members ( - id INT NOT NULL AUTO_INCREMENT, - access INT NULL, -- Access type - See access table in plugin.ini - member_type INT NULL, -- Pointer to member type in member_type table - created DATE NULL, -- Date member record was created - name TINYTEXT NULL, -- Member name - member_slug TINYTEXT NULL, -- Member name slug for canonical URLs (lowercase, "-" for spaces, no punctuation) - notes TEXT NULL, -- General notes - Not displayed in front-end - old_member_id TINYTEXT NULL, -- Old member ID if imported from old database - featured BOOLEAN DEFAULT '0', -- Whether the member is featured - PRIMARY KEY (id), - INDEX(name(20)), - INDEX(member_slug(20)), - INDEX(created), - INDEX(old_member_id(20)) -); - ----- - --- Member Detail Display Stats Data - Totals of times detail page is displayed - Preserved for 2 years -CREATE TABLE {prefix}member_detail_stats ( - member INT NOT NULL, -- ID of member - stat_type INT NOT NULL, -- Type of stat 1 = day, 2 = week, 3 = month - stat_date DATE NOT NULL, -- Date for which these stats are accumulated (date or first date of week or month) - clicks INT NULL, -- Number of Clicks - PRIMARY KEY (member, stat_type, stat_date), - INDEX (member), - INDEX (stat_type), - INDEX (stat_date) -); - ----- - --- Member information version record - May be multiples per member - Only one with status "Active" for a distinct date range -CREATE TABLE {prefix}member_info ( - id INT NOT NULL AUTO_INCREMENT, - member INT NULL, -- Pointer to member record in table members - member_name TINYTEXT NULL, -- Copy of member name from members table entry for fast reference - status INT NULL, -- Status of this member information record - See plugin.ini status table - reference_name TINYTEXT NULL, -- Reference name for this member information record - Not displayed on front-end - has_no_map_data BOOLEAN DEFAULT '0', -- True if member info record has no map data - has_no_profile BOOLEAN DEFAULT '0', -- True if member has no profile record - descr TEXT NULL, -- Description - short_descr TEXT NULL, -- Short description - addr1 TINYTEXT NULL, -- Main member location address line 1 - addr2 TINYTEXT NULL, -- Address line 2 - city INT NULL, -- Pointer to City in cities table - state TINYTEXT NULL, -- Two character state code - matches states.ini entries - country TINYTEXT NULL, -- Two character country code - matches countries.ini entries - zip TINYTEXT NULL, -- ZIP/Postal code - lat FLOAT NULL, -- Latitude of member's location - lon FLOAT NULL, -- Longitude of member's location - region INT NULL, -- Pointer to entry in regions table - county INT NULL, -- Pointer to entry in regions table - phone TINYTEXT NULL, -- Primary phone number - toll_free TINYTEXT NULL, -- Toll Free phone number - url TINYTEXT NULL, -- URL with information about this member - reservation_url TEXT NULL, -- Reservation URL - email TINYTEXT NULL, -- Main E-Mail address for this member - logo TINYTEXT NULL, -- Member logo - cc_type INT NULL, -- Bitmap of credit card types accepted - See credit_card array in plugin.ini - video_url TINYTEXT NULL, -- Video URL - video_file TINYTEXT NULL, -- Video File Name - video_title TINYTEXT NULL, -- Video Title - video_descr TEXT NULL, -- Video Description - video_type INT NULL, -- Video Type - See plugin.ini video type table. - live_cam_url TINYTEXT NULL, -- Live Cam URL - live_cam_title TINYTEXT NULL, -- Live Cam Title - live_cam_descr TEXT NULL, -- Live Cam Description - live_cam_type INT NULL, -- Live Cam Type - See plugin.ini video type table. - mailing_addr1 TINYTEXT NULL, -- Mailing Address 1 - mailing_addr2 TINYTEXT NULL, -- Mailing Address 2 - mailing_city INT NULL, -- Mailing City (Pointer to City in cities table) - mailing_state TINYTEXT NULL, -- Mailing State (Two character state code - matches states.ini entries) - mailing_zip TINYTEXT NULL, -- Mailing ZIP/Postal code - notes TEXT NULL, -- General notes - Not displayed in front-end - create_time TIMESTAMP NULL, -- Create date/time - modify_time TIMESTAMP NULL, -- Last update date/time - PRIMARY KEY (id), - INDEX(status), - INDEX(city), - INDEX(zip(10)), - INDEX(lat), - INDEX(lon), - INDEX(region), - INDEX(county), - FULLTEXT KEY member_name (member_name) -); - ----- - --- Member type - Can be used to assign members to different "classes" of membership (i.e. Full, Associate, Premium) --- Mostly for internal use by the member organization, but could be displayed - Consider a short_description if they are. -CREATE TABLE {prefix}member_type ( - id INT NOT NULL AUTO_INCREMENT, - name TINYTEXT NULL, -- Name of member type - descr TINYTEXT NULL, -- Description of member type - PRIMARY KEY (id) -); - ----- - --- Regions - Used to segment members into various geographical regions - can be cities, counties, or other logical regions -CREATE TABLE {prefix}regions ( - id INT NOT NULL AUTO_INCREMENT, - name TINYTEXT NULL, -- Name of region - descr TEXT NULL, -- Description of region - short_descr TINYTEXT NULL, -- Short description of region - PRIMARY KEY (id) -); - ----- - --- Counties -CREATE TABLE {prefix}counties ( - id INT NOT NULL AUTO_INCREMENT, - name TINYTEXT NULL, -- Name of county - descr TEXT NULL, -- Description of county - short_descr TINYTEXT NULL, -- Short description of county - PRIMARY KEY (id) -); - ----- - --- File Library Cateogries - used with "Files Library" - Created due to PDF failures in WordPress Media Library -CREATE TABLE {prefix}file_library_categories ( - id INT NOT NULL AUTO_INCREMENT, - name TINYTEXT NULL, -- Name of this category - descr TEXT NULL, -- Description of this category - short_descr TINYTEXT NULL, -- Short description of this category - parent INT NULL, -- Pointer to parent category in this table - if there is one - PRIMARY KEY (id) -); - ----- - --- Files Library - Files are stored under /wp-content/uploads/glm-member-db/filesLibrary/ -CREATE TABLE {prefix}file_library ( - id INT NOT NULL AUTO_INCREMENT, - name TINYTEXT NULL, -- Original name of the file - might be URL if copied via HTTP - file_name TINYTEXT NULL, -- Stored file name for the file - descr TEXT NULL, -- Description - title TINYTEXT NULL, -- File title - last_access_time DATETIME NULL, -- Upload time or last access time - PRIMARY KEY (id), - INDEX(name(20)), - INDEX(file_name(20)) -); - ----- - --- General settings available on Management page in admin - Only 1 entry in this table --- Items in this table should be all self-explanatory -CREATE TABLE {prefix}settings_general ( - id INT NOT NULL AUTO_INCREMENT, - admin_debug BOOLEAN DEFAULT '0', - admin_debug_verbose BOOLEAN DEFAULT '0', - front_debug BOOLEAN DEFAULT '0', - front_debug_verbose BOOLEAN DEFAULT '0', - enable_members BOOLEAN DEFAULT '1', - selected_map_interface SMALLINT DEFAULT '1', - leaflet_tile_server TINYTEXT DEFAULT '', - leaflet_tile_server_key TINYTEXT DEFAULT '', - google_maps_api_key TINYTEXT DEFAULT '', - maps_default_lat FLOAT DEFAULT '45.3749', - maps_default_lon FLOAT DEFAULT '-84.9592', - maps_default_zoom INTEGER DEFAULT '10', - time_zone TINYTEXT DEFAULT NULL, - canonical_member_page TINYTEXT DEFAULT NULL, - phone_infix TINYTEXT DEFAULT NULL, - phone_format TINYTEXT DEFAULT NULL, - default_state TINYTEXT DEFAULT NULL, - enable_counties BOOLEAN DEFAULT '0', - enable_multiple_profiles BOOLEAN DEFAULT '0', - enable_single_profile BOOLEAN DEFAULT '0', -- Hide the add profile and clone profile links/buttons - enable_member_reports BOOLEAN DEFAULT '1', - enable_caching BOOLEAN DEFAULT '1', - enable_contact_edit_only BOOLEAN DEFAULT '0', - memb_info_location BOOLEAN DEFAULT '1', - memb_info_contact BOOLEAN DEFAULT '1', - memb_info_categories BOOLEAN DEFAULT '1', - memb_info_images BOOLEAN DEFAULT '1', - memb_info_files BOOLEAN DEFAULT '1', - memb_info_video BOOLEAN DEFAULT '1', - memb_info_cam BOOLEAN DEFAULT '1', - file_library BOOLEAN DEFAULT '0', - list_show_map BOOLEAN DEFAULT '1', - list_show_featured BOOLEAN DEFAULT '0', - list_show_featured_count SMALLINT DEFAULT '3', - list_show_list BOOLEAN DEFAULT '1', - list_order_list SMALLINT DEFAULT '10', - list_pagination BOOLEAN DEFAULT '1', - list_pagination_count SMALLINT DEFAULT '20', - list_show_search_filters_opened BOOLEAN DEFAULT '0', - list_show_search BOOLEAN DEFAULT '1', - list_show_search_text BOOLEAN DEFAULT '1', - list_show_search_category BOOLEAN DEFAULT '1', - list_show_search_amenities BOOLEAN DEFAULT '1', - list_show_search_region BOOLEAN DEFAULT '1', - list_show_search_alpha BOOLEAN DEFAULT '1', - list_floating_search BOOLEAN DEFAULT '0', - list_floating_search_distance_top INTEGER DEFAULT '0', -- How far from the top the sticky Search/Filters box should hover - list_show_detail_link BOOLEAN DEFAULT '1', - list_show_logo BOOLEAN DEFAULT '1', - list_logo_size TINYTEXT NULL, - list_logo_for_mobile BOOLEAN DEFAULT '1', - list_show_address BOOLEAN DEFAULT '1', - list_show_street BOOLEAN DEFAULT '1', - list_show_citystatezip BOOLEAN DEFAULT '1', - list_show_country BOOLEAN DEFAULT '1', - list_show_region BOOLEAN DEFAULT '1', - list_show_descr BOOLEAN DEFAULT '0', - list_show_short_descr BOOLEAN DEFAULT '1', - list_show_phone BOOLEAN DEFAULT '1', - list_show_tollfree BOOLEAN DEFAULT '1', - list_show_url BOOLEAN DEFAULT '1', - list_show_url_newtarget BOOLEAN DEFAULT '1', - list_show_email BOOLEAN DEFAULT '1', - list_show_categories BOOLEAN DEFAULT '0', - list_show_creditcards BOOLEAN DEFAULT '0', - list_show_amenities BOOLEAN DEFAULT '0', - list_show_logo_filler BOOLEAN DEFAULT '1', - list_show_live_cam BOOLEAN DEFAULT '1', - list_map_show_opened BOOLEAN DEFAULT '0', - list_map_show_detaillink BOOLEAN DEFAULT '1', - list_map_show_logo BOOLEAN DEFAULT '0', - list_map_logo_size TINYTEXT NULL, - list_map_show_descr BOOLEAN DEFAULT '0', - list_map_show_short_descr BOOLEAN DEFAULT '1', - list_map_show_address BOOLEAN DEFAULT '1', - list_map_show_street BOOLEAN DEFAULT '1', - list_map_show_citystatezip BOOLEAN DEFAULT '1', - list_map_show_country BOOLEAN DEFAULT '1', - list_map_show_region BOOLEAN DEFAULT '1', - list_map_show_phone BOOLEAN DEFAULT '1', - list_map_show_tollfree BOOLEAN DEFAULT '1', - list_map_show_url BOOLEAN DEFAULT '1', - list_map_show_url_newtarget BOOLEAN DEFAULT '1', - list_map_show_email BOOLEAN DEFAULT '1', - list_map_show_categories BOOLEAN DEFAULT '0', - list_map_show_creditcards BOOLEAN DEFAULT '0', - list_map_show_amenities BOOLEAN DEFAULT '0', - list_show_packages BOOLEAN DEFAULT '0', - list_show_packages_link BOOLEAN DEFAULT '0', - list_header_text TINYTEXT DEFAULT NULL, - detail_auto_expand_sections BOOLEAN DEFAULT '0', - detail_show_map BOOLEAN DEFAULT '1', - detail_show_directions BOOLEAN DEFAULT '1', - detail_show_logo BOOLEAN DEFAULT '1', - detail_logo_size TINYTEXT NULL, - detail_show_descr BOOLEAN DEFAULT '1', - detail_show_short_descr BOOLEAN DEFAULT '0', - detail_show_address BOOLEAN DEFAULT '1', - detail_show_street BOOLEAN DEFAULT '1', - detail_show_citystatezip BOOLEAN DEFAULT '1', - detail_show_country BOOLEAN DEFAULT '1', - detail_show_region BOOLEAN DEFAULT '1', - detail_show_phone BOOLEAN DEFAULT '1', - detail_show_tollfree BOOLEAN DEFAULT '1', - detail_show_url BOOLEAN DEFAULT '1', - detail_show_url_newtarget BOOLEAN DEFAULT '1', - detail_show_email BOOLEAN DEFAULT '1', - detail_show_categories BOOLEAN DEFAULT '0', - detail_show_creditcards BOOLEAN DEFAULT '0', - detail_show_amenities BOOLEAN DEFAULT '1', - detail_show_imagegallery BOOLEAN DEFAULT '1', - detail_show_coupons BOOLEAN DEFAULT '0', - detail_show_packages BOOLEAN DEFAULT '0', - detail_show_events BOOLEAN DEFAULT '0', - detail_show_video BOOLEAN DEFAULT '0', - detail_show_live_cam BOOLEAN DEFAULT '0', - detail_top_offset_autoscroll INTEGER DEFAULT '0', -- Determines the distance from the top when autoscrolling to a section on member detail pages - detail_map_show_logo BOOLEAN DEFAULT '0', - detail_map_logo_size TINYTEXT NULL, - detail_map_show_descr BOOLEAN DEFAULT '0', - detail_map_show_short_descr BOOLEAN DEFAULT '1', - detail_map_show_address BOOLEAN DEFAULT '1', - detail_map_show_street BOOLEAN DEFAULT '1', - detail_map_show_citystatezip BOOLEAN DEFAULT '1', - detail_map_show_country BOOLEAN DEFAULT '1', - detail_map_show_region BOOLEAN DEFAULT '1', - detail_map_show_phone BOOLEAN DEFAULT '1', - detail_map_show_tollfree BOOLEAN DEFAULT '1', - detail_map_show_url BOOLEAN DEFAULT '1', - detail_map_show_url_newtarget BOOLEAN DEFAULT '1', - detail_map_show_email BOOLEAN DEFAULT '1', - detail_map_show_categories BOOLEAN DEFAULT '0', - detail_map_show_creditcards BOOLEAN DEFAULT '0', - detail_map_show_amenities BOOLEAN DEFAULT '0', - members_only_support_email TINYTEXT DEFAULT '', - members_only_support_phone TINYTEXT DEFAULT '', - updates_notification_to TINYTEXT DEFAULT '', -- To email address for the notification email - updates_notification_from TINYTEXT DEFAULT '', -- From header for the notification email - updates_notification TEXT DEFAULT '', -- Notification message - short_desc_char_limit INTEGER DEFAULT '120', -- How many characters the short description is limited to - also used for importing - use_cluster_markers BOOLEAN DEFAULT '0', -- Flag to say if cluster markers should be use in maps - recaptcha_site_key TINYTEXT DEFAULT '', -- reCAPTCHA site key - recaptcha_secret_key TINYTEXT DEFAULT '', -- reCAPTCHA secret key - recaptcha_header_code TEXT DEFAULT '', -- reCAPTCHA code for page header - recaptcha_form_code TEXT DEFAULT '', -- reCAPTCHA code for captcha form field - PRIMARY KEY (id) -); - ----- - --- Set default entry -INSERT INTO {prefix}settings_general - ( id, time_zone, canonical_member_page, list_logo_size, list_map_logo_size, detail_logo_size, detail_map_logo_size, - list_pagination, list_pagination_count, enable_counties, enable_multiple_profiles, enable_member_reports, enable_caching, updates_notification, enable_single_profile ) - VALUES - ( 1, 'America/Detroit', 'member-detail', 'large', 'thumb', 'large', 'thumb', '1', 20, 0, 0, 1, 1, - 'A member has updated their record and is now in a pending state.', 0) -; - ----- - --- Terms used in site modifiable on Management page in admin - Only 1 entry in this table --- Terms in this table should be all self-explanatory -CREATE TABLE {prefix}settings_terms ( - id INT NOT NULL AUTO_INCREMENT, - term_admin_menu_members TINYTEXT NULL, - term_admin_menu_member_list TINYTEXT NULL, - term_admin_menu_member TINYTEXT NULL, - term_admin_menu_configure TINYTEXT NULL, - term_admin_menu_settings TINYTEXT NULL, - term_admin_menu_shortcodes TINYTEXT NULL, - term_admin_menu_members_dashboard TINYTEXT NULL, - term_admin_menu_members_list TINYTEXT NULL, - term_admin_menu_members_reports TINYTEXT NULL, - term_admin_menu_member_dashboard TINYTEXT NULL, - term_admin_menu_member_info TINYTEXT NULL, - term_admin_menu_member_locations TINYTEXT NULL, - term_admin_menu_member_facilities TINYTEXT NULL, - term_admin_menu_member_attractions TINYTEXT NULL, - term_admin_menu_member_contacts TINYTEXT NULL, - term_admin_menu_configure_member_types TINYTEXT NULL, - term_admin_menu_configure_member_cats TINYTEXT NULL, - term_admin_menu_configure_accom_types TINYTEXT NULL, - term_admin_menu_configure_amenities TINYTEXT NULL, - term_admin_menu_configure_cities TINYTEXT NULL, - term_admin_menu_configure_counties TINYTEXT NULL, - term_admin_menu_configure_regions TINYTEXT NULL, - term_admin_menu_settings_general TINYTEXT NULL, - term_admin_menu_settings_terms TINYTEXT NULL, - term_admin_menu_settings_development TINYTEXT NULL, - term_member TINYTEXT NULL, - term_member_cap TINYTEXT NULL, - term_member_plur TINYTEXT NULL, - term_member_plur_cap TINYTEXT NULL, - term_location TINYTEXT NULL, - term_location_cap TINYTEXT NULL, - term_location_plur TINYTEXT NULL, - term_location_plur_cap TINYTEXT NULL, - term_county TINYTEXT NULL, - term_county_cap TINYTEXT NULL, - term_county_plur TINYTEXT NULL, - term_county_plur_cap TINYTEXT NULL, - term_facility TINYTEXT NULL, - term_facility_cap TINYTEXT NULL, - term_facility_plur TINYTEXT NULL, - term_facility_plur_cap TINYTEXT NULL, - term_attraction TINYTEXT NULL, - term_attraction_cap TINYTEXT NULL, - term_attraction_plur TINYTEXT NULL, - term_attraction_plur_cap TINYTEXT NULL, - term_contact TINYTEXT NULL, - term_contact_cap TINYTEXT NULL, - term_contact_plur TINYTEXT NULL, - term_contact_plur_cap TINYTEXT NULL, - term_webcam_cap TINYTEXT NULL, - PRIMARY KEY (id) -); - ----- - --- Default terms entry -INSERT INTO {prefix}settings_terms - ( - id, - term_admin_menu_members, - term_admin_menu_member_list, - term_admin_menu_member, - term_admin_menu_configure, - term_admin_menu_settings, - term_admin_menu_shortcodes, - term_admin_menu_members_dashboard, - term_admin_menu_members_list, - term_admin_menu_members_reports, - term_admin_menu_member_dashboard, - term_admin_menu_member_info, - term_admin_menu_member_locations, - term_admin_menu_member_facilities, - term_admin_menu_member_attractions, - term_admin_menu_member_contacts, - term_admin_menu_configure_member_types, - term_admin_menu_configure_member_cats, - term_admin_menu_configure_accom_types, - term_admin_menu_configure_amenities, - term_admin_menu_configure_cities, - term_admin_menu_configure_counties, - term_admin_menu_configure_regions, - term_admin_menu_settings_general, - term_admin_menu_settings_terms, - term_admin_menu_settings_development, - term_member, - term_member_cap, - term_member_plur, - term_member_plur_cap, - term_location, - term_location_cap, - term_location_plur, - term_location_plur_cap, - term_county, - term_county_cap, - term_county_plur, - term_county_plur_cap, - term_facility, - term_facility_cap, - term_facility_plur, - term_facility_plur_cap, - term_attraction, - term_attraction_cap, - term_attraction_plur, - term_attraction_plur_cap, - term_contact, - term_contact_cap, - term_contact_plur, - term_contact_plur_cap, - term_webcam_cap - ) - VALUES - ( - 1, - 'Members', - 'Member', - 'Member', - 'Configure', - 'Management', - 'Shortcodes', - 'Dashboard', - 'Member List', - 'Reports', - 'Member Dashboard', - 'Member Info', - 'Locations', - 'Facilities', - 'Attractions', - 'Contacts', - 'Member Types', - 'Member Categories', - 'Accommodation Types', - 'Amenities', - 'Cities', - 'Counties', - 'Regions', - 'General Settings', - 'Terms & Phrases', - 'Development', - 'member', - 'Member', - 'members', - 'Members', - 'location', - 'Location', - 'locations', - 'Locations', - 'county', - 'County', - 'counties', - 'Counties', - 'facility', - 'Facility', - 'facilities', - 'Facilities', - 'attraction', - 'Attraction', - 'attractions', - 'Attractions', - 'contact', - 'Contact', - 'contacts', - 'Contacts', - 'Webcam' - ) -; - ----- - --- Shortcode Output Cache -CREATE TABLE {prefix}cache ( - shortcode TINYTEXT NULL, - cache_code TINYTEXT NOT NULL, - created DATETIME NULL, - html MEDIUMTEXT NULL, - PRIMARY KEY (cache_code(20)), - INDEX (created) -); - ----- - --- Theme Settings - Only 1 entry in this table -CREATE TABLE {prefix}settings_theme ( - id INT NOT NULL AUTO_INCREMENT, - PRIMARY KEY (id) -); - ----- - --- Default Theme Settings entry -INSERT INTO {prefix}settings_theme - ( - id - ) - VALUES - ( - 1 - ) -; - ----- - --- Member Email Notifications -CREATE TABLE {prefix}email_notifications ( - id INT NOT NULL AUTO_INCREMENT, - notification_message TEXT NULL, - declined_message TEXT NULL, - approved_message TEXT NULL, - to_email TINYTEXT NULL, - from_email TINYTEXT NULL, - PRIMARY KEY (id) -); - ----- - --- Set default email notifications -INSERT INTO {prefix}email_notifications - ( id, notification_message, declined_message, approved_message ) -VALUES - ( 1, 'A member has requested a profile update.', 'Your profile update has been declined.', 'Your profile has been approved!' ); - diff --git a/setup/databaseScripts/create_database_V1.1.44.sql b/setup/databaseScripts/create_database_V1.1.44.sql new file mode 100755 index 00000000..91d769c6 --- /dev/null +++ b/setup/databaseScripts/create_database_V1.1.44.sql @@ -0,0 +1,704 @@ +-- Gaslight Media Members Database +-- File Created: 12/29/16 12:06:00 +-- Database Version: 1.1.41 +-- Database Creation Script +-- +-- To permit each query below to be executed separately, +-- all queries must be separated by a line with four dashes +-- +-- **** BE SURE TO ALSO UPDATE drop_database_Vxxx.sql FILE WHEN CHANGING TABLES **** +-- + +-- Amenities +CREATE TABLE {prefix}amenities ( + id INT NOT NULL AUTO_INCREMENT, + active TINYINT(1) NULL, -- Amenity is active flag + name TINYTEXT NULL, -- Name of amenity + descr TEXT NULL, -- Description of amenity + short_descr TINYTEXT NULL, -- Short description of amenity + ref_type INT NULL, -- Type of entity these amenities are associated with - see plugin.ini ref_type tables + uses_value BOOLEAN NULL, -- Flag indicating whether the amenity requires a quantity number + PRIMARY KEY (id), + INDEX(name(20)) +); + +---- + +-- Amenity Reference - Links a specific amenity to a specific entity of type ref_type +CREATE TABLE {prefix}amenity_ref ( + id INT NOT NULL AUTO_INCREMENT, + amenity INT NULL, -- Pointer to amenity in amenities table + ref_type INT NULL, -- Copy of ref_type from matching amenities table entry - to simplify searches + ref_dest INT NULL, -- Pointer to the specific entity of type ref_type + amenity_value TINYTEXT NULL, -- Quantity if amenity uses values + PRIMARY KEY (id), + INDEX(ref_type), + INDEX(ref_dest) +); + +---- + +-- groups +CREATE TABLE {prefix}amenity_groups ( + id INT NOT NULL AUTO_INCREMENT, + name TINYTEXT NULL, -- Name of the Group + PRIMARY KEY (id), + INDEX(name(20)) +); + +---- + +-- Amenity Group - Links a specific amenity to groups +CREATE TABLE {prefix}grouped_amenities ( + id INT NOT NULL AUTO_INCREMENT, + group_id INT, -- Pointer to the group + amenity_id INT, -- Pointer to the Amenity + searchable BOOLEAN DEFAULT '0', -- Flag indicating whether the amenity group will show in the search form + PRIMARY KEY (id) +); + +---- + +-- Member Cateogries - used with member information records +CREATE TABLE {prefix}categories ( + id INT NOT NULL AUTO_INCREMENT, + name TINYTEXT NULL, -- Name of this category + descr TEXT NULL, -- Description of this category + short_descr TINYTEXT NULL, -- Short description of this category + parent INT NULL, -- Pointer to parent category in this table - if there is one + PRIMARY KEY (id) +); + +---- + +-- Mapping of categories to specific member information records +CREATE TABLE {prefix}category_member_info ( + id INT NOT NULL AUTO_INCREMENT, + category INT NULL, -- Pointer to category in categories table + member_info INT NULL, -- Pointer to member information record + PRIMARY KEY (id), + CONSTRAINT {prefix}categories_fk_1 + FOREIGN KEY (category) + REFERENCES {prefix}categories (id) + ON DELETE CASCADE, + INDEX(category), + INDEX(member_info) +); + +---- + +-- Cities +CREATE TABLE {prefix}cities ( + id INT NOT NULL AUTO_INCREMENT, + name TINYTEXT NULL, -- Name of city + lat FLOAT NULL, -- Latitude of city's location + lon FLOAT NULL, -- Longitude of city's location + county INT NULL, -- County reference to county table + temp_max TINYTEXT NULL, -- Max temp + temp_min TINYTEXT NULL, -- Min temp + icon TINYTEXT NULL, -- Icon url + weather TINYTEXT NULL, -- weather + moreinfo TEXT NULL, -- moreinfo + wx_time DATETIME NULL, -- last update time for weather + PRIMARY KEY (id) +); + +---- + +-- Member Click Through Stats Data - Totals of URL click-throughs - Preserved for 2 years +CREATE TABLE {prefix}clickthrough_stats ( + member INT NOT NULL, -- ID of member + stat_type INT NOT NULL, -- Type of stat 1 = day, 2 = week, 3 = month + stat_date DATE NOT NULL, -- Date for which these stats are accumulated (date or first date of week or month) + clicks INT NULL, -- Number of Clicks + PRIMARY KEY (member, stat_type, stat_date), + INDEX (member), + INDEX (stat_type), + INDEX (stat_date) +); + +---- + +-- Files - Files are stored under /wp-content/uploads/glm-member-db/files/ +CREATE TABLE {prefix}files ( + id INT NOT NULL AUTO_INCREMENT, + name TINYTEXT NULL, -- Original name of the file - might be URL if copied via HTTP + status TINYINT(1) NULL, -- Display/Use status - See plugin.ini status table + file_name TINYTEXT NULL, -- Stored file name for the file + descr TEXT NULL, -- Description + caption TINYTEXT NULL, -- Caption for the image + position INT NULL, -- Numeric position for sequence of display + ref_type INT NULL, -- Type of entity this image is associated with + ref_dest INT NULL, -- Pointer to the specific entity of ref_type this image is associated with + PRIMARY KEY (id), + INDEX(name(20)), + INDEX(file_name(20)), + INDEX(ref_type), + INDEX(ref_dest) +); + +---- + +-- Images - Images are stored under /wp-content/uploads/glm-member-db/images/{size}/ +CREATE TABLE {prefix}images ( + id INT NOT NULL AUTO_INCREMENT, + name TINYTEXT NULL, -- Original name of the image - might be URL if copied via HTTP + status TINYINT(1) NULL, -- Display/Use status - See plugin.ini status table + selected BOOLEAN NULL, -- A single special image in the current gallery for this entity + featured BOOLEAN null, -- Image is a member of a group of featured images + file_name TINYTEXT NULL, -- Stored file name for the image + descr TEXT NULL, -- Description + caption TINYTEXT NULL, -- Caption for the image + position INT NULL, -- Numeric position for sequence of display + ref_type INT NULL, -- Type of entity this image is associated with + ref_dest INT NULL, -- Pointer to the specific entity of ref_type this image is associated with + PRIMARY KEY (id), + INDEX(name(20)), + INDEX(file_name(20)), + INDEX(ref_type), + INDEX(ref_dest) +); + +---- + +-- Primary member records - One for each member +CREATE TABLE {prefix}members ( + id INT NOT NULL AUTO_INCREMENT, + access INT NULL, -- Access type - See access table in plugin.ini + member_type INT NULL, -- Pointer to member type in member_type table + created DATE NULL, -- Date member record was created + name TINYTEXT NULL, -- Member name + member_slug TINYTEXT NULL, -- Member name slug for canonical URLs (lowercase, "-" for spaces, no punctuation) + notes TEXT NULL, -- General notes - Not displayed in front-end + old_member_id TINYTEXT NULL, -- Old member ID if imported from old database + featured BOOLEAN DEFAULT '0', -- Whether the member is featured + PRIMARY KEY (id), + INDEX(name(20)), + INDEX(member_slug(20)), + INDEX(created), + INDEX(old_member_id(20)) +); + +---- + +-- Member Detail Display Stats Data - Totals of times detail page is displayed - Preserved for 2 years +CREATE TABLE {prefix}member_detail_stats ( + member INT NOT NULL, -- ID of member + stat_type INT NOT NULL, -- Type of stat 1 = day, 2 = week, 3 = month + stat_date DATE NOT NULL, -- Date for which these stats are accumulated (date or first date of week or month) + clicks INT NULL, -- Number of Clicks + PRIMARY KEY (member, stat_type, stat_date), + INDEX (member), + INDEX (stat_type), + INDEX (stat_date) +); + +---- + +-- Member information version record - May be multiples per member - Only one with status "Active" for a distinct date range +CREATE TABLE {prefix}member_info ( + id INT NOT NULL AUTO_INCREMENT, + member INT NULL, -- Pointer to member record in table members + member_name TINYTEXT NULL, -- Copy of member name from members table entry for fast reference + status INT NULL, -- Status of this member information record - See plugin.ini status table + reference_name TINYTEXT NULL, -- Reference name for this member information record - Not displayed on front-end + has_no_map_data BOOLEAN DEFAULT '0', -- True if member info record has no map data + has_no_profile BOOLEAN DEFAULT '0', -- True if member has no profile record + descr TEXT NULL, -- Description + short_descr TEXT NULL, -- Short description + addr1 TINYTEXT NULL, -- Main member location address line 1 + addr2 TINYTEXT NULL, -- Address line 2 + city INT NULL, -- Pointer to City in cities table + state TINYTEXT NULL, -- Two character state code - matches states.ini entries + country TINYTEXT NULL, -- Two character country code - matches countries.ini entries + zip TINYTEXT NULL, -- ZIP/Postal code + lat FLOAT NULL, -- Latitude of member's location + lon FLOAT NULL, -- Longitude of member's location + region INT NULL, -- Pointer to entry in regions table + county INT NULL, -- Pointer to entry in regions table + phone TINYTEXT NULL, -- Primary phone number + toll_free TINYTEXT NULL, -- Toll Free phone number + url TINYTEXT NULL, -- URL with information about this member + reservation_url TEXT NULL, -- Reservation URL + email TINYTEXT NULL, -- Main E-Mail address for this member + logo TINYTEXT NULL, -- Member logo + cc_type INT NULL, -- Bitmap of credit card types accepted - See credit_card array in plugin.ini + video_url TINYTEXT NULL, -- Video URL + video_file TINYTEXT NULL, -- Video File Name + video_title TINYTEXT NULL, -- Video Title + video_descr TEXT NULL, -- Video Description + video_type INT NULL, -- Video Type - See plugin.ini video type table. + live_cam_url TINYTEXT NULL, -- Live Cam URL + live_cam_title TINYTEXT NULL, -- Live Cam Title + live_cam_descr TEXT NULL, -- Live Cam Description + live_cam_type INT NULL, -- Live Cam Type - See plugin.ini video type table. + mailing_addr1 TINYTEXT NULL, -- Mailing Address 1 + mailing_addr2 TINYTEXT NULL, -- Mailing Address 2 + mailing_city INT NULL, -- Mailing City (Pointer to City in cities table) + mailing_state TINYTEXT NULL, -- Mailing State (Two character state code - matches states.ini entries) + mailing_zip TINYTEXT NULL, -- Mailing ZIP/Postal code + notes TEXT NULL, -- General notes - Not displayed in front-end + create_time TIMESTAMP NULL, -- Create date/time + modify_time TIMESTAMP NULL, -- Last update date/time + PRIMARY KEY (id), + INDEX(status), + INDEX(city), + INDEX(zip(10)), + INDEX(lat), + INDEX(lon), + INDEX(region), + INDEX(county), + FULLTEXT KEY member_name (member_name) +); + +---- + +-- Member type - Can be used to assign members to different "classes" of membership (i.e. Full, Associate, Premium) +-- Mostly for internal use by the member organization, but could be displayed - Consider a short_description if they are. +CREATE TABLE {prefix}member_type ( + id INT NOT NULL AUTO_INCREMENT, + name TINYTEXT NULL, -- Name of member type + descr TINYTEXT NULL, -- Description of member type + PRIMARY KEY (id) +); + +---- + +-- Regions - Used to segment members into various geographical regions - can be cities, counties, or other logical regions +CREATE TABLE {prefix}regions ( + id INT NOT NULL AUTO_INCREMENT, + name TINYTEXT NULL, -- Name of region + descr TEXT NULL, -- Description of region + short_descr TINYTEXT NULL, -- Short description of region + PRIMARY KEY (id) +); + +---- + +-- Counties +CREATE TABLE {prefix}counties ( + id INT NOT NULL AUTO_INCREMENT, + name TINYTEXT NULL, -- Name of county + descr TEXT NULL, -- Description of county + short_descr TINYTEXT NULL, -- Short description of county + PRIMARY KEY (id) +); + +---- + +-- File Library Cateogries - used with "Files Library" - Created due to PDF failures in WordPress Media Library +CREATE TABLE {prefix}file_library_categories ( + id INT NOT NULL AUTO_INCREMENT, + name TINYTEXT NULL, -- Name of this category + descr TEXT NULL, -- Description of this category + short_descr TINYTEXT NULL, -- Short description of this category + parent INT NULL, -- Pointer to parent category in this table - if there is one + PRIMARY KEY (id) +); + +---- + +-- Files Library - Files are stored under /wp-content/uploads/glm-member-db/filesLibrary/ +CREATE TABLE {prefix}file_library ( + id INT NOT NULL AUTO_INCREMENT, + name TINYTEXT NULL, -- Original name of the file - might be URL if copied via HTTP + file_name TINYTEXT NULL, -- Stored file name for the file + descr TEXT NULL, -- Description + title TINYTEXT NULL, -- File title + last_access_time DATETIME NULL, -- Upload time or last access time + PRIMARY KEY (id), + INDEX(name(20)), + INDEX(file_name(20)) +); + +---- + +-- General settings available on Management page in admin - Only 1 entry in this table +-- Items in this table should be all self-explanatory +CREATE TABLE {prefix}settings_general ( + id INT NOT NULL AUTO_INCREMENT, + admin_debug BOOLEAN DEFAULT '0', + admin_debug_verbose BOOLEAN DEFAULT '0', + front_debug BOOLEAN DEFAULT '0', + front_debug_verbose BOOLEAN DEFAULT '0', + enable_members BOOLEAN DEFAULT '1', + selected_map_interface SMALLINT DEFAULT '1', + leaflet_tile_server TINYTEXT DEFAULT '', + leaflet_tile_server_key TINYTEXT DEFAULT '', + google_maps_api_key TINYTEXT DEFAULT '', + maps_default_lat FLOAT DEFAULT '45.3749', + maps_default_lon FLOAT DEFAULT '-84.9592', + maps_default_zoom INTEGER DEFAULT '10', + time_zone TINYTEXT DEFAULT NULL, + canonical_member_page TINYTEXT DEFAULT NULL, + phone_infix TINYTEXT DEFAULT NULL, + phone_format TINYTEXT DEFAULT NULL, + default_state TINYTEXT DEFAULT NULL, + enable_counties BOOLEAN DEFAULT '0', + enable_multiple_profiles BOOLEAN DEFAULT '0', + enable_single_profile BOOLEAN DEFAULT '0', -- Hide the add profile and clone profile links/buttons + enable_member_reports BOOLEAN DEFAULT '1', + enable_caching BOOLEAN DEFAULT '1', + enable_contact_edit_only BOOLEAN DEFAULT '0', + memb_info_location BOOLEAN DEFAULT '1', + memb_info_contact BOOLEAN DEFAULT '1', + memb_info_categories BOOLEAN DEFAULT '1', + memb_info_images BOOLEAN DEFAULT '1', + memb_info_files BOOLEAN DEFAULT '1', + memb_info_video BOOLEAN DEFAULT '1', + memb_info_cam BOOLEAN DEFAULT '1', + file_library BOOLEAN DEFAULT '0', + list_show_map BOOLEAN DEFAULT '1', + list_show_featured BOOLEAN DEFAULT '0', + list_show_featured_count SMALLINT DEFAULT '3', + list_show_list BOOLEAN DEFAULT '1', + list_order_list SMALLINT DEFAULT '10', + list_pagination BOOLEAN DEFAULT '1', + list_pagination_count SMALLINT DEFAULT '20', + list_show_search_filters_opened BOOLEAN DEFAULT '0', + list_show_search BOOLEAN DEFAULT '1', + list_show_search_text BOOLEAN DEFAULT '1', + list_show_search_category BOOLEAN DEFAULT '1', + list_show_search_amenities BOOLEAN DEFAULT '1', + list_show_search_region BOOLEAN DEFAULT '1', + list_show_search_alpha BOOLEAN DEFAULT '1', + list_floating_search BOOLEAN DEFAULT '0', + list_floating_search_distance_top INTEGER DEFAULT '0', -- How far from the top the sticky Search/Filters box should hover + list_show_detail_link BOOLEAN DEFAULT '1', + list_show_logo BOOLEAN DEFAULT '1', + list_logo_size TINYTEXT NULL, + list_logo_for_mobile BOOLEAN DEFAULT '1', + list_show_address BOOLEAN DEFAULT '1', + list_show_street BOOLEAN DEFAULT '1', + list_show_citystatezip BOOLEAN DEFAULT '1', + list_show_country BOOLEAN DEFAULT '1', + list_show_region BOOLEAN DEFAULT '1', + list_show_descr BOOLEAN DEFAULT '0', + list_show_short_descr BOOLEAN DEFAULT '1', + list_show_phone BOOLEAN DEFAULT '1', + list_show_tollfree BOOLEAN DEFAULT '1', + list_show_url BOOLEAN DEFAULT '1', + list_show_url_newtarget BOOLEAN DEFAULT '1', + list_show_email BOOLEAN DEFAULT '1', + list_show_categories BOOLEAN DEFAULT '0', + list_show_creditcards BOOLEAN DEFAULT '0', + list_show_amenities BOOLEAN DEFAULT '0', + list_show_logo_filler BOOLEAN DEFAULT '1', + list_show_live_cam BOOLEAN DEFAULT '1', + list_map_show_opened BOOLEAN DEFAULT '0', + list_map_show_detaillink BOOLEAN DEFAULT '1', + list_map_show_logo BOOLEAN DEFAULT '0', + list_map_logo_size TINYTEXT NULL, + list_map_show_descr BOOLEAN DEFAULT '0', + list_map_show_short_descr BOOLEAN DEFAULT '1', + list_map_show_address BOOLEAN DEFAULT '1', + list_map_show_street BOOLEAN DEFAULT '1', + list_map_show_citystatezip BOOLEAN DEFAULT '1', + list_map_show_country BOOLEAN DEFAULT '1', + list_map_show_region BOOLEAN DEFAULT '1', + list_map_show_phone BOOLEAN DEFAULT '1', + list_map_show_tollfree BOOLEAN DEFAULT '1', + list_map_show_url BOOLEAN DEFAULT '1', + list_map_show_url_newtarget BOOLEAN DEFAULT '1', + list_map_show_email BOOLEAN DEFAULT '1', + list_map_show_categories BOOLEAN DEFAULT '0', + list_map_show_creditcards BOOLEAN DEFAULT '0', + list_map_show_amenities BOOLEAN DEFAULT '0', + list_show_packages BOOLEAN DEFAULT '0', + list_show_packages_link BOOLEAN DEFAULT '0', + list_header_text TINYTEXT DEFAULT NULL, + detail_auto_expand_sections BOOLEAN DEFAULT '0', + detail_show_map BOOLEAN DEFAULT '1', + detail_show_directions BOOLEAN DEFAULT '1', + detail_show_logo BOOLEAN DEFAULT '1', + detail_logo_size TINYTEXT NULL, + detail_show_descr BOOLEAN DEFAULT '1', + detail_show_short_descr BOOLEAN DEFAULT '0', + detail_show_address BOOLEAN DEFAULT '1', + detail_show_street BOOLEAN DEFAULT '1', + detail_show_citystatezip BOOLEAN DEFAULT '1', + detail_show_country BOOLEAN DEFAULT '1', + detail_show_region BOOLEAN DEFAULT '1', + detail_show_phone BOOLEAN DEFAULT '1', + detail_show_tollfree BOOLEAN DEFAULT '1', + detail_show_url BOOLEAN DEFAULT '1', + detail_show_url_newtarget BOOLEAN DEFAULT '1', + detail_show_email BOOLEAN DEFAULT '1', + detail_show_categories BOOLEAN DEFAULT '0', + detail_show_creditcards BOOLEAN DEFAULT '0', + detail_show_amenities BOOLEAN DEFAULT '1', + detail_show_imagegallery BOOLEAN DEFAULT '1', + detail_show_coupons BOOLEAN DEFAULT '0', + detail_show_packages BOOLEAN DEFAULT '0', + detail_show_events BOOLEAN DEFAULT '0', + detail_show_video BOOLEAN DEFAULT '0', + detail_show_live_cam BOOLEAN DEFAULT '0', + detail_top_offset_autoscroll INTEGER DEFAULT '0', -- Determines the distance from the top when autoscrolling to a section on member detail pages + detail_map_show_logo BOOLEAN DEFAULT '0', + detail_map_logo_size TINYTEXT NULL, + detail_map_show_descr BOOLEAN DEFAULT '0', + detail_map_show_short_descr BOOLEAN DEFAULT '1', + detail_map_show_address BOOLEAN DEFAULT '1', + detail_map_show_street BOOLEAN DEFAULT '1', + detail_map_show_citystatezip BOOLEAN DEFAULT '1', + detail_map_show_country BOOLEAN DEFAULT '1', + detail_map_show_region BOOLEAN DEFAULT '1', + detail_map_show_phone BOOLEAN DEFAULT '1', + detail_map_show_tollfree BOOLEAN DEFAULT '1', + detail_map_show_url BOOLEAN DEFAULT '1', + detail_map_show_url_newtarget BOOLEAN DEFAULT '1', + detail_map_show_email BOOLEAN DEFAULT '1', + detail_map_show_categories BOOLEAN DEFAULT '0', + detail_map_show_creditcards BOOLEAN DEFAULT '0', + detail_map_show_amenities BOOLEAN DEFAULT '0', + members_only_support_email TINYTEXT DEFAULT '', + members_only_support_phone TINYTEXT DEFAULT '', + updates_notification_to TINYTEXT DEFAULT '', -- To email address for the notification email + updates_notification_from TINYTEXT DEFAULT '', -- From header for the notification email + updates_notification TEXT DEFAULT '', -- Notification message + short_desc_char_limit INTEGER DEFAULT '120', -- How many characters the short description is limited to - also used for importing + use_cluster_markers BOOLEAN DEFAULT '0', -- Flag to say if cluster markers should be use in maps + recaptcha_site_key TINYTEXT DEFAULT '', -- reCAPTCHA site key + recaptcha_secret_key TINYTEXT DEFAULT '', -- reCAPTCHA secret key + recaptcha_header_code TEXT DEFAULT '', -- reCAPTCHA code for page header + recaptcha_form_code TEXT DEFAULT '', -- reCAPTCHA code for captcha form field + PRIMARY KEY (id) +); + +---- + +-- Set default entry +INSERT INTO {prefix}settings_general + ( id, time_zone, canonical_member_page, list_logo_size, list_map_logo_size, detail_logo_size, detail_map_logo_size, + list_pagination, list_pagination_count, enable_counties, enable_multiple_profiles, enable_member_reports, enable_caching, updates_notification, enable_single_profile ) + VALUES + ( 1, 'America/Detroit', 'member-detail', 'large', 'thumb', 'large', 'thumb', '1', 20, 0, 0, 1, 1, + 'A member has updated their record and is now in a pending state.', 0) +; + +---- + +-- Terms used in site modifiable on Management page in admin - Only 1 entry in this table +-- Terms in this table should be all self-explanatory +CREATE TABLE {prefix}settings_terms ( + id INT NOT NULL AUTO_INCREMENT, + term_admin_menu_members TINYTEXT NULL, + term_admin_menu_member_list TINYTEXT NULL, + term_admin_menu_member TINYTEXT NULL, + term_admin_menu_configure TINYTEXT NULL, + term_admin_menu_settings TINYTEXT NULL, + term_admin_menu_shortcodes TINYTEXT NULL, + term_admin_menu_members_dashboard TINYTEXT NULL, + term_admin_menu_members_list TINYTEXT NULL, + term_admin_menu_members_reports TINYTEXT NULL, + term_admin_menu_member_dashboard TINYTEXT NULL, + term_admin_menu_member_info TINYTEXT NULL, + term_admin_menu_member_locations TINYTEXT NULL, + term_admin_menu_member_facilities TINYTEXT NULL, + term_admin_menu_member_attractions TINYTEXT NULL, + term_admin_menu_member_contacts TINYTEXT NULL, + term_admin_menu_configure_member_types TINYTEXT NULL, + term_admin_menu_configure_member_cats TINYTEXT NULL, + term_admin_menu_configure_accom_types TINYTEXT NULL, + term_admin_menu_configure_amenities TINYTEXT NULL, + term_admin_menu_configure_cities TINYTEXT NULL, + term_admin_menu_configure_counties TINYTEXT NULL, + term_admin_menu_configure_regions TINYTEXT NULL, + term_admin_menu_settings_general TINYTEXT NULL, + term_admin_menu_settings_terms TINYTEXT NULL, + term_admin_menu_settings_development TINYTEXT NULL, + term_member TINYTEXT NULL, + term_member_cap TINYTEXT NULL, + term_member_plur TINYTEXT NULL, + term_member_plur_cap TINYTEXT NULL, + term_location TINYTEXT NULL, + term_location_cap TINYTEXT NULL, + term_location_plur TINYTEXT NULL, + term_location_plur_cap TINYTEXT NULL, + term_county TINYTEXT NULL, + term_county_cap TINYTEXT NULL, + term_county_plur TINYTEXT NULL, + term_county_plur_cap TINYTEXT NULL, + term_facility TINYTEXT NULL, + term_facility_cap TINYTEXT NULL, + term_facility_plur TINYTEXT NULL, + term_facility_plur_cap TINYTEXT NULL, + term_attraction TINYTEXT NULL, + term_attraction_cap TINYTEXT NULL, + term_attraction_plur TINYTEXT NULL, + term_attraction_plur_cap TINYTEXT NULL, + term_contact TINYTEXT NULL, + term_contact_cap TINYTEXT NULL, + term_contact_plur TINYTEXT NULL, + term_contact_plur_cap TINYTEXT NULL, + term_webcam_cap TINYTEXT NULL, + PRIMARY KEY (id) +); + +---- + +-- Default terms entry +INSERT INTO {prefix}settings_terms + ( + id, + term_admin_menu_members, + term_admin_menu_member_list, + term_admin_menu_member, + term_admin_menu_configure, + term_admin_menu_settings, + term_admin_menu_shortcodes, + term_admin_menu_members_dashboard, + term_admin_menu_members_list, + term_admin_menu_members_reports, + term_admin_menu_member_dashboard, + term_admin_menu_member_info, + term_admin_menu_member_locations, + term_admin_menu_member_facilities, + term_admin_menu_member_attractions, + term_admin_menu_member_contacts, + term_admin_menu_configure_member_types, + term_admin_menu_configure_member_cats, + term_admin_menu_configure_accom_types, + term_admin_menu_configure_amenities, + term_admin_menu_configure_cities, + term_admin_menu_configure_counties, + term_admin_menu_configure_regions, + term_admin_menu_settings_general, + term_admin_menu_settings_terms, + term_admin_menu_settings_development, + term_member, + term_member_cap, + term_member_plur, + term_member_plur_cap, + term_location, + term_location_cap, + term_location_plur, + term_location_plur_cap, + term_county, + term_county_cap, + term_county_plur, + term_county_plur_cap, + term_facility, + term_facility_cap, + term_facility_plur, + term_facility_plur_cap, + term_attraction, + term_attraction_cap, + term_attraction_plur, + term_attraction_plur_cap, + term_contact, + term_contact_cap, + term_contact_plur, + term_contact_plur_cap, + term_webcam_cap + ) + VALUES + ( + 1, + 'Members', + 'Member', + 'Member', + 'Configure', + 'Management', + 'Shortcodes', + 'Dashboard', + 'Member List', + 'Reports', + 'Member Dashboard', + 'Member Info', + 'Locations', + 'Facilities', + 'Attractions', + 'Contacts', + 'Member Types', + 'Member Categories', + 'Accommodation Types', + 'Amenities', + 'Cities', + 'Counties', + 'Regions', + 'General Settings', + 'Terms & Phrases', + 'Development', + 'member', + 'Member', + 'members', + 'Members', + 'location', + 'Location', + 'locations', + 'Locations', + 'county', + 'County', + 'counties', + 'Counties', + 'facility', + 'Facility', + 'facilities', + 'Facilities', + 'attraction', + 'Attraction', + 'attractions', + 'Attractions', + 'contact', + 'Contact', + 'contacts', + 'Contacts', + 'Webcam' + ) +; + +---- + +-- Shortcode Output Cache +CREATE TABLE {prefix}cache ( + shortcode TINYTEXT NULL, + cache_code TINYTEXT NOT NULL, + created DATETIME NULL, + html MEDIUMTEXT NULL, + PRIMARY KEY (cache_code(20)), + INDEX (created) +); + +---- + +-- Theme Settings - Only 1 entry in this table +CREATE TABLE {prefix}settings_theme ( + id INT NOT NULL AUTO_INCREMENT, + PRIMARY KEY (id) +); + +---- + +-- Default Theme Settings entry +INSERT INTO {prefix}settings_theme + ( + id + ) + VALUES + ( + 1 + ) +; + +---- + +-- Member Email Notifications +CREATE TABLE {prefix}email_notifications ( + id INT NOT NULL AUTO_INCREMENT, + notification_message TEXT NULL, + declined_message TEXT NULL, + approved_message TEXT NULL, + to_email TINYTEXT NULL, + from_email TINYTEXT NULL, + PRIMARY KEY (id) +); + +---- + +-- Set default email notifications +INSERT INTO {prefix}email_notifications + ( id, notification_message, declined_message, approved_message ) +VALUES + ( 1, 'A member has requested a profile update.', 'Your profile update has been declined.', 'Your profile has been approved!' ); + diff --git a/setup/databaseScripts/dbVersions.php b/setup/databaseScripts/dbVersions.php index 66131ba8..e88c1d5f 100755 --- a/setup/databaseScripts/dbVersions.php +++ b/setup/databaseScripts/dbVersions.php @@ -75,6 +75,7 @@ $glmMembersDbVersions = array( '1.1.41' => array('version' => '1.1.41', 'tables' => 23, 'date' => '10/12/18'), '1.1.42' => array('version' => '1.1.42', 'tables' => 23, 'date' => '10/29/18'), '1.1.43' => array('version' => '1.1.43', 'tables' => 23, 'date' => '11/07/18'), + '1.1.44' => array('version' => '1.1.44', 'tables' => 23, 'date' => '11/08/18'), ); diff --git a/setup/databaseScripts/update_database_V1.1.43.sql b/setup/databaseScripts/update_database_V1.1.43.sql index af377a7f..9249cd4b 100755 --- a/setup/databaseScripts/update_database_V1.1.43.sql +++ b/setup/databaseScripts/update_database_V1.1.43.sql @@ -1,6 +1,6 @@ -- Gaslight Media Members Database --- File Created: 2018-10-12 --- Database Version: 1.1.41 +-- File Created: 2018-11-07 +-- Database Version: 1.1.43 -- Database Update From Previous Version Script -- -- To permit each query below to be executed separately, diff --git a/setup/databaseScripts/update_database_V1.1.44.sql b/setup/databaseScripts/update_database_V1.1.44.sql new file mode 100755 index 00000000..80895db8 --- /dev/null +++ b/setup/databaseScripts/update_database_V1.1.44.sql @@ -0,0 +1,35 @@ +-- Gaslight Media Members Database +-- File Created: 2018-11-08 +-- Database Version: 1.1.44 +-- Database Update From Previous Version Script +-- +-- To permit each query below to be executed separately, +-- all queries must be separated by a line with four dashes + +-- Add temp_max to cities table +ALTER TABLE {prefix}cities ADD COLUMN temp_max TINYTEXT NULL; -- Max temp + +---- + +-- Add temp_min to cities table +ALTER TABLE {prefix}cities ADD COLUMN temp_min TINYTEXT NULL; -- Min temp + +---- + +-- Add icon to cities table +ALTER TABLE {prefix}cities ADD COLUMN icon TINYTEXT NULL; -- Icon url + +---- + +-- Add weather to cities table +ALTER TABLE {prefix}cities ADD COLUMN weather TINYTEXT NULL; -- weather + +---- + +-- Add moreinfo to cities table +ALTER TABLE {prefix}cities ADD COLUMN moreinfo TEXT NULL; -- moreinfo + +---- + +-- Add wx_time to cities table +ALTER TABLE {prefix}cities ADD COLUMN wx_time DATETIME NULL; -- last update time for weather diff --git a/setup/shortcodes.php b/setup/shortcodes.php index 91407bcd..350d72ab 100644 --- a/setup/shortcodes.php +++ b/setup/shortcodes.php @@ -213,6 +213,14 @@ if ( isset( $config['settings'] ) && $config['settings']['enable_members'] ) { 'lon-bounds' => false, ), ), + 'glm-member-city-weather' => array( + 'plugin' => GLM_MEMBERS_PLUGIN_SLUG, + 'menu' => 'members', + 'action' => 'cityWeather', + 'attributes' => array( + 'alpha' => false, + ), + ), ); $glmMembersShortcodes = apply_filters( 'glm-custom-fields-shortcodes', $glmMembersShortcodes ); @@ -564,10 +572,51 @@ if ( isset( $config['settings'] ) && $config['settings']['enable_members'] ) { categories credit-cards amenities -

+ + [glm-member-interactive-map] +   + + Display Interactive Map. + + + +   + + main-level-cats="{ Category ID(s) }" + + + The "main-level-cats" attribute is used to set the top level main categories for the map. + + + +   + + main-level-colors="{ Color(s) }" + + + The "main-level-colors" attribute is used to set the Colors for each top level main categories for the map. + + + + [glm-member-city-weather] +   + + Display City Weather. Each city must have lat lon data for weather to work. + + + +   + + alpha="{ First Letter of City Name }" + + + The "alpha" attribute is used to set the letter used for the city displayed. This is overridden using + $_REQUEST[\'alpha\']. + + '; } else { $glmMembersShortcodes = array(); diff --git a/setup/validActions.php b/setup/validActions.php index c39e79df..ef985fca 100644 --- a/setup/validActions.php +++ b/setup/validActions.php @@ -110,6 +110,7 @@ $glmMembersValidActions = array( 'detail' => 'glm-member-db', 'featured' => 'glm-member-db', 'interactivemap' => 'glm-member-db', + 'cityWeather' => 'glm-member-db', ), 'error' => array( 'index' => 'glm-member-db', diff --git a/views/front/members/cityWeather.html b/views/front/members/cityWeather.html new file mode 100644 index 00000000..1826d468 --- /dev/null +++ b/views/front/members/cityWeather.html @@ -0,0 +1,47 @@ + + +
+ {foreach $cities as $city} + {if $city.moreinfo} +
+
+ {if $city.moreinfo} + + + + {/if} + {if !$city.moreinfo} + + {/if} +

{$city.name}

+

{$city.weather}

+ {if $city.temp_max} +

{$city.temp_max}°/{$city.temp_min}°F

+ {/if} + {if !$city.temp_max} +

 

+ {/if} +
+
+ {/if} + {/foreach} +