cloudy cloudy

Author Topic: Space Weather addon page for WD-AJAX-PHP-USA  (Read 48411 times)

0 Members and 1 Guest are viewing this topic.

Offline MCHALLIS

  • Posts: 2,149
  • Long Beach, WA USA
    • Weather for Long Beach, WA USA
Space Weather addon page for WD-AJAX-PHP-USA
« on: October 20, 2009, 07:16:32 PM »
Space Weather addon page for WD-AJAX-PHP-USA

You can see my Space Weather Script in use here:
http://www.642weather.com/weather/space-weather.php

This script will show a space weather forecast page, Real Time Images of the Sun, and graphs of Real Time Solar X-ray and Solar Wind. It shows the 3-day space weather forecast from the NOAA / Space Weather Prediction Center. Also included are 9 PHP images that are cached locally on your server.

Version: 1.2.1 - 30-Sep-2011
- updated image URL for Mauna Loa Solar image

Version: 1.2 - 24-Oct-2009
- XHTML 1.0-Strict compliant code (even though the template uses XHTML 1.0 Transitional)
- added links in the credits.

Version: 1.1 - 24-Oct-2009
- Added more images and graphs.
- Image PHP files updated to latest version of the image handler, fixes error 004 on some servers
http://www.642weather.com/weather/scripts-history.php#ImageHandler

-----------------------------------------
Installation (USA carterlake php template sites)
-----------------------------------------

You must already be running the USA carterlake php template
http://saratoga-weather.org/template/index.php

Step 1)
Download:
www.642weather.com/weather/scripts/wxspace.zip

Step 2)
Upload these files to your web server:
wxspace.php
image-space-aurora.php
image-space-aurora-s.php
image-space-eit-284.php
image-space-eit-304.php
image-space-sat-env.php
image-space-solar-cycle.php
image-space-solar-disk.php
image-space-solar-wind.php
image-space-xray.php

Step 3)
test your page:
www.yoursite.com/wxspace.php

A paypal donate button is on my scripts page
www.642weather.com.com/weather/scripts.php


What to do if you get Error 003 displayed in the images.
Description of the PHP error:
cannot write to file, you need to adjust the server permission settings.

Solution:
This is a PHP error telling you that your server is setup with too strict file permissions,
not every server is the same so it is not possible to give you one specific solution.
Try changing the folder permissions(CHMOD) to 755, 717, or on some servers 777.

Here is a tutorial on how to change folder permissions using your FTP program.
http://www.stadtaus.com/en/tutorials/chmod-ftp-file-permissions.php

If your host has PHP safe_mode = on, this will cause many PHP scripts to have permission problems and errors.
Ask your host to turn safe_mode off, safe_mode was determined to be a bad idea and will be removed from PHP6.

« Last Edit: September 30, 2011, 08:44:22 PM by MCHALLIS »

Offline ALITTLEweird1

  • Mark
  • Global Moderator
  • Posts: 5,082
  • North Bend, WA
    • North Bend Weather
Re: Space Weather addon page for WD-AJAX-PHP-USA
« Reply #1 on: October 20, 2009, 07:22:47 PM »
Very nice Mike. I'll be adding that onto my site later.
"Nature can do without man, but man cannot do without nature."

Davis VP2 + VP2 Solar + Logitech Webcam

Offline smokie

  • Posts: 413
  • WS2300 operational May 2007
  • Newquay, Cornwall UK
    • Newquay weather and much more
Re: Space Weather addon page for WD-AJAX-PHP-USA
« Reply #2 on: October 20, 2009, 07:44:53 PM »
Nice one, added, I have something similar on my astronomy page but yours is so much better :D

Newquay, Cornwall.UK  > WS2300 Operational since May 2007.
From 6/4/08 www.newquayweather.com
** Philip

Offline Silversword

  • --Stan Y.
  • Posts: 953
  • Maui, Hawaii
    • Up Country Maui Weather
Re: Space Weather addon page for WD-AJAX-PHP-USA
« Reply #3 on: October 20, 2009, 08:50:43 PM »
Hi Mike,

Got another winner.  This info will be great for the amateur radio community as well. Will try to play around with it as time permits.

Thank you for all that you contribute.

--Stan Y.
   Maui, Hawaii
   KH6HHG
WD 10.37s Bld 36
WDL 6.05

Dell Optiplex GX280-Intel Pentium 4 CPU 3.00GHz, 4 GB RAM
Webcam: Axis 211
Wx Sta: Davis Vantage Pro 2+

Blackjack52

  • Guest
Re: Space Weather addon page for WD-AJAX-PHP-USA
« Reply #4 on: October 20, 2009, 09:01:17 PM »
Looks good. Is there a chance of using dials from Rice University, the Planetary Kp from N3KL, and offer black background.? I also RSS from HFRadio.org Propogation Center.

When I flew the DSP Satellite Constellation we heavily relied upon Kp and X-Ray indices. Indicators of impending spacecraft impacts and perturbations. Bad stuff, as flares and our magnetic field can cause 'drag' on spacecraft.

http://www.knology.net/~blackjack52/wxspacewx.php

Offline i_fiorentino

  • Alessandro Bardi
  • Posts: 1,682
  • 150 mls Candeglia (Pt), Tuscany, Italy
    • Meteopistoia.it
Re: Space Weather addon page for WD-AJAX-PHP-USA
« Reply #5 on: October 20, 2009, 10:06:57 PM »
Very Nice Mike,
here is the link: http://www.meteocarmignano.it/wxspace.php

Thanks for your great job,  :)

Alessandro
« Last Edit: October 21, 2009, 08:15:31 AM by i_fiorentino »

Offline AM1234

  • Posts: 385
  • Beamsville, Ontario, Canada
    • Beamsville Weather Station
Re: Space Weather addon page for WD-AJAX-PHP-USA
« Reply #6 on: October 21, 2009, 01:01:36 AM »
I've been meaning to place a space weather page on my site for some time now. Thanks very much Mike :)
Ann-Marie
Beamsville, Ontario, Canada

Offline MCHALLIS

  • Posts: 2,149
  • Long Beach, WA USA
    • Weather for Long Beach, WA USA
Re: Space Weather addon page for WD-AJAX-PHP-USA
« Reply #7 on: October 21, 2009, 01:16:43 AM »
Looks good. Is there a chance of using dials from Rice University, the Planetary Kp from N3KL, and offer black background.? I also RSS from HFRadio.org Propogation Center.

When I flew the DSP Satellite Constellation we heavily relied upon Kp and X-Ray indices. Indicators of impending spacecraft impacts and perturbations. Bad stuff, as flares and our magnetic field can cause 'drag' on spacecraft.

http://www.knology.net/~blackjack52/wxspacewx.php

I like the sun images you have, and the other stuff.  I might fit them into my script when I get time.

Mike

Offline niko

  • syzygy
  • Global Moderator
  • Posts: 26,769
  • Crystal Ball broken! Please post the URL.
  • Northern California, U.S.A.
Re: Space Weather addon page for WD-AJAX-PHP-USA
« Reply #8 on: October 21, 2009, 01:53:01 AM »
Good one Mike!

Offline saratogaWX

  • Global Moderator
  • Posts: 5,673
  • Ken True
  • Saratoga, CA, USA 37:16:28N, 122:01:23W - Elev: 374ft.
    • Saratoga Weather
Re: Space Weather addon page for WD-AJAX-PHP-USA
« Reply #9 on: October 21, 2009, 03:03:10 AM »
Great script set, Mike!  Thanks!!

My page is at http://saratoga-weather.org/space-weather.php

Best regards,
Ken
« Last Edit: October 21, 2009, 05:03:01 AM by ktrue »
Ken True
Saratoga Weather
CWOP: CW1792
WeatherUnderground: KCASARAT1
Free weather website PHP scripts and WD website AJAX templates

Offline WeatherPilot

  • Posts: 84
  • Charles Town - WV
    • Tuscawilla Weather
Re: Space Weather addon page for WD-AJAX-PHP-USA
« Reply #10 on: October 21, 2009, 03:28:15 AM »
Quick question - I uploaded the files per instructions (Thanks Mike!!) and tested the wxspace.php at http://www.tuscawilla-weather.net/wxspace.php  Seems I'm not getting any graphics.  Could that be the cache file writing restriction on e-Rice.net?  If so, what are the cache files?  I think if I create them in the website directory at e-Rice and set the permissions to 666 then the scripts can use the cache file write that it needs to display graphics?  Am I on the right track?? 

Any help appreciated.

Greg.


Offline looney2ns

  • Posts: 3,210
  • Fearless Weather Dog-Loves to watch Lightning.
  • Near Evansville Indiana USA
    • Newburgh Weather
Re: Space Weather addon page for WD-AJAX-PHP-USA
« Reply #11 on: October 21, 2009, 03:32:24 AM »
I'm also on E-Rice.
I simply uploaded the files that Mike said was needed, and it worked.
I didn't have to change any permissions.

Offline WeatherPilot

  • Posts: 84
  • Charles Town - WV
    • Tuscawilla Weather
Re: Space Weather addon page for WD-AJAX-PHP-USA
« Reply #12 on: October 21, 2009, 03:35:05 AM »
Hmmmm.  Now Im really puzzled. 

Offline looney2ns

  • Posts: 3,210
  • Fearless Weather Dog-Loves to watch Lightning.
  • Near Evansville Indiana USA
    • Newburgh Weather
Re: Space Weather addon page for WD-AJAX-PHP-USA
« Reply #13 on: October 21, 2009, 03:36:44 AM »
All files were put in the same directory as wxspace.php?

Offline Silversword

  • --Stan Y.
  • Posts: 953
  • Maui, Hawaii
    • Up Country Maui Weather
Re: Space Weather addon page for WD-AJAX-PHP-USA
« Reply #14 on: October 21, 2009, 07:42:25 AM »
Hi All,

Thanks Mike for the script.  Got mine to work just fine. Plug n' Play.  No fuss, just load and go.  My page is at http://www.dwayneyamato.com/wx/wxspace.php.

Will get it on the menu bar as time permits.

Thank you again for a wonderful job.

--Stan Y.
  Maui, Hawaii
  KH6HHG
WD 10.37s Bld 36
WDL 6.05

Dell Optiplex GX280-Intel Pentium 4 CPU 3.00GHz, 4 GB RAM
Webcam: Axis 211
Wx Sta: Davis Vantage Pro 2+

 

cumulus