Scootercam Sun & Moon

WordPress plugin for displaying comprehensive sun and moon data including sunset/moonset beauty predictions, phase calendars, arc visualizations, and viewing information.

Description

This plugin provides detailed astronomical information with beautiful visualizations:

  • Sunset/Moonset Predictions – AI-powered beauty scores (0-10) based on cloud cover, humidity, visibility, and moon phase
  • Moon Phase Calendar – Visual timeline showing phases from last new moon to next new moon
  • Sun & Moon Arcs – Real-time path visualizations showing current positions
  • Viewing Information – Optimal viewing times, recommendations, and technical data
  • Full Moon Data – Names, dates, and descriptions of last/next full moons

Installation

  1. Upload the scootercam-sun-moon folder to /wp-content/plugins/
  2. Activate the plugin through the ‘Plugins’ menu in WordPress
  3. Ensure data files exist:
    • /home/scootercam/public_html/wx/moon_api_data.json
    • /home/scootercam/public_html/wx/predictor.json
  4. Use shortcodes in your posts or pages

Shortcodes

Prediction Shortcodes

Sunset Beauty Score

[scootercam_sunset_score]
🌅
Tonight's Sunset
70/100
C-
Sunset at 6:53 PM

Displays tonight’s sunset quality prediction with score, rating, and contributing factors.

Moonset Beauty Score

[scootercam_moonset_score show_details="false"]
🌙
Tonight's Moonset
No notable moonset
No morning moonset over lake today
🌙
Tonight's Moonset
No notable moonset
No morning moonset over lake today

Displays tonight’s moonset quality prediction with moon phase and illumination data.

Options:

  • show_details – Show/hide contributing factors (default: true)

Moon Data Shortcodes

Moon Phase Calendar

🌙 Moon Phase Calendar
Last New Moon
Sep 22
1st Qtr
Sep 28
Full
Oct 6
Last Qtr
Oct 14
New Moon
Oct 21
Now
Oct 21
Current Phase: Waxing crescent (0% illuminated)
[scootercam_moon_calendar]

Displays 6-cell calendar showing moon phases from last new moon to next new moon, with “Now” indicator highlighting current position in the lunar cycle.

Current Moon Phase

🌙 Current Moon Phase
Phase:Waxing crescent 🌒
Illumination:0%
Age:29 days
Sun Sign:Libra
Moon Sign:Scorpio
Moonrise:12:15 PM
Moonset:10:42 PM
[scootercam_moon_current]

Shows current phase name, illumination percentage, age in days, zodiac signs, and moonrise/moonset times.

Moon Viewing Information

🔭 Moon Viewing Information
Visibility Rating:Poor
Visible Hours:6.2 hours
Best Viewing Time:7:55 PM
Optimal Period:7:25 PM - 9:55 PM
Viewing Quality:Limited visibility of surface features
Altitude:-53°
Azimuth:326.1°
Distance:403,136 km
Recommendations:
  • Best viewed in western sky after sunset
  • Look for earthshine on the dark portion of the moon
  • Low magnification best for thin crescent
[scootercam_moon_viewing]

Displays visibility rating, optimal viewing period, technical position data (altitude, azimuth, distance), and viewing recommendations.

Full Moon Data

🌕 Last Full Moon
Date:Oct 6, 2025
Name:Hunter's Moon
Traditionally aids hunters tracking prey by moonlight.
🌕 Next Full Moon
Date:Nov 4, 2025
Name:Beaver Moon
When beavers are actively preparing for winter.
[scootercam_full_moons]

Shows last and next full moons with traditional names and cultural descriptions.

Visualization Shortcodes

Sun Path Arc

☀️ Sun Path Today
8:03 AM 1:29 PM 6:55 PM 6:24 PM 10:52 daylight
[scootercam_sun_arc]

SVG visualization showing sun’s path across the sky with sunrise, solar noon, sunset times, and current position indicator.

Moon Path Arc

🌙 Moon Path Today
8:15 AM 6:42 PM 6:24 PM Waxing crescent (0%)
[scootercam_moon_arc]

SVG visualization showing moon’s path with moonrise/moonset times, current position, and phase graphic.

Dashboard

Complete Astronomy Dashboard

🌅
Tonight's Sunset
70/100
C-
Sunset at 6:53 PM

Description: Good sunset viewing conditions
🌙
Tonight's Moonset
No notable moonset
No morning moonset over lake today
🌙 Moon Phase Calendar
Last New Moon
Sep 22
1st Qtr
Sep 28
Full
Oct 6
Last Qtr
Oct 14
New Moon
Oct 21
Now
Oct 21
Current Phase: Waxing crescent (0% illuminated)
☀️ Sun Path Today
8:03 AM 1:29 PM 6:55 PM 6:24 PM 10:52 daylight
🌙 Moon Path Today
8:15 AM 6:42 PM 6:24 PM Waxing crescent (0%)
🌙 Current Moon Phase
Phase:Waxing crescent 🌒
Illumination:0%
Age:29 days
Sun Sign:Libra
Moon Sign:Scorpio
Moonrise:12:15 PM
Moonset:10:42 PM
🔭 Moon Viewing Information
Visibility Rating:Poor
Visible Hours:6.2 hours
Best Viewing Time:7:55 PM
Optimal Period:7:25 PM - 9:55 PM
Viewing Quality:Limited visibility of surface features
Altitude:-53°
Azimuth:326.1°
Distance:403,136 km
Recommendations:
  • Best viewed in western sky after sunset
  • Look for earthshine on the dark portion of the moon
  • Low magnification best for thin crescent
🌕 Last Full Moon
Date:Oct 6, 2025
Name:Hunter's Moon
Traditionally aids hunters tracking prey by moonlight.
🌕 Next Full Moon
Date:Nov 4, 2025
Name:Beaver Moon
When beavers are actively preparing for winter.
[scootercam_astronomy_dashboard]

Displays all components in a comprehensive, organized layout:

  • Sunset and moonset predictions side-by-side
  • Moon phase calendar
  • Sun and moon arc visualizations
  • Current moon phase and viewing information
  • Full moon data

Data Files

The plugin requires two JSON data files:

moon_api_data.json

Contains comprehensive moon and sun data:

  • Sun: sunrise, sunset, solar noon, day length
  • Moon: phase, illumination, age, zodiac signs
  • Moon events: moonrise, moonset, optimal viewing
  • Upcoming phases: new moon, quarters, full moon with names/descriptions
  • Technical data: altitude, azimuth, distance, phase angle

predictor.json

Contains beauty prediction scores:

  • Sunset: score, rating, time, contributing factors
  • Moonset: score, rating, time, moon data, contributing factors

Admin Interface

Access the plugin settings at Settings → Sun & Moon to:

  • View all available shortcodes with examples
  • Check data file status
  • Preview all components with live data
  • Test individual shortcodes

Styling

The plugin uses W3.CSS classes for styling. Color-coded score classes:

  • 8-10: Green (Excellent/Outstanding)
  • 6-7: Light Green (Good/Great)
  • 4-5: Orange (Fair/Moderate)
  • 0-3: Red (Poor)

File Structure

scootercam-sun-moon/
├── scootercam-sun-moon.php    # Main plugin file
└── README.md                   # This file

Requirements

  • WordPress 5.0 or higher
  • PHP 7.0 or higher
  • W3.CSS loaded on your site (or similar CSS framework)
  • Data files must be generated by your weather/astronomy scripts

Data File Locations

Default paths (can be modified in plugin code):

  • Moon data: /home/scootercam/public_html/wx/moon_api_data.json
  • Predictor data: /home/scootercam/public_html/wx/predictor.json

Changelog

1.0.0 – 2025-10-20

  • Initial release
  • Sunset/moonset beauty predictions
  • Moon phase calendar with “Now” indicator
  • Sun and moon arc visualizations
  • Current moon phase details
  • Moon viewing information with recommendations
  • Full moon data with traditional names
  • Complete astronomy dashboard
  • Admin preview interface

Support

For issues, questions, or feature requests, visit scootercam.net

License

GPL v2 or later

Credits

Developed by ScooterCam Icon assets located at /assets/icons/

Screenshots

Sunset Prediction

Shows tonight’s sunset quality with contributing weather factors.

Moon Phase Calendar

Visual timeline of the lunar cycle with current position highlighted.

Sun & Moon Arcs

Real-time visualizations showing celestial paths across the sky.

Complete Dashboard

All components organized in a comprehensive astronomy view.


Pro Tip: Use

🌅
Tonight's Sunset
70/100
C-
Sunset at 6:53 PM

Description: Good sunset viewing conditions
🌙
Tonight's Moonset
No notable moonset
No morning moonset over lake today
🌙 Moon Phase Calendar
Last New Moon
Sep 22
1st Qtr
Sep 28
Full
Oct 6
Last Qtr
Oct 14
New Moon
Oct 21
Now
Oct 21
Current Phase: Waxing crescent (0% illuminated)
☀️ Sun Path Today
8:03 AM 1:29 PM 6:55 PM 6:24 PM 10:52 daylight
🌙 Moon Path Today
8:15 AM 6:42 PM 6:24 PM Waxing crescent (0%)
🌙 Current Moon Phase
Phase:Waxing crescent 🌒
Illumination:0%
Age:29 days
Sun Sign:Libra
Moon Sign:Scorpio
Moonrise:12:15 PM
Moonset:10:42 PM
🔭 Moon Viewing Information
Visibility Rating:Poor
Visible Hours:6.2 hours
Best Viewing Time:7:55 PM
Optimal Period:7:25 PM - 9:55 PM
Viewing Quality:Limited visibility of surface features
Altitude:-53°
Azimuth:326.1°
Distance:403,136 km
Recommendations:
  • Best viewed in western sky after sunset
  • Look for earthshine on the dark portion of the moon
  • Low magnification best for thin crescent
🌕 Last Full Moon
Date:Oct 6, 2025
Name:Hunter's Moon
Traditionally aids hunters tracking prey by moonlight.
🌕 Next Full Moon
Date:Nov 4, 2025
Name:Beaver Moon
When beavers are actively preparing for winter.
for a complete astronomy page, or mix individual shortcodes for custom layouts!