Goal
Tune where weather locations come from and how forecasts are fetched. These settings are per app — every role that has the Weather element shares them.
Steps
- Go to Mobile App Mgr → App Settings.
- Open the Weather panel.
- Set the options (table below) and Save.
The settings
| Setting | Choices | Default | What it controls |
|---|---|---|---|
| Weather Locations Source | Automatic / GeoDirectory listings / Developer filter | Automatic | Where the forecast locations come from. Automatic uses the developer filter (mam_nws_weather_for_home_screen_stack) when one is wired in code, otherwise GeoDirectory listings. Set it explicitly to pin one source. |
| GeoDirectory Categories for Weather | comma-separated category names | (blank) | Limits weather to listings in the named categories. Blank = every listing gets a forecast card. Ignored when locations come from the developer filter. |
| Forecast Type | Standard (12-hour periods) / Hourly | Standard | Which NWS forecast endpoint is used. Standard shows day/night periods with a detailed narrative; Hourly shows the current hour. Applies to developer-filter locations (per-location type overrides it); GeoDirectory listings always use the standard forecast. |
| Forecast Cache Duration (minutes) | number | 15 | How long a fetched forecast is reused for developer-filter locations before refreshing from NWS. |
| Location Match Radius (miles) | number | 5 | How close (in miles) a cached forecast must be to a requested location to be reused, for developer-filter locations. A per-location miles value overrides it. |
GeoDirectory forecasts are cached per listing and refreshed by the 15-minute scheduled job, so the two cache settings mainly matter for developer-filter locations.
Notes
- A site that never saves this panel keeps the defaults above — existing apps behave exactly as before the settings existed.
- The NWS API is free and unauthenticated but US-only. Locations outside the US produce no card (the element hides if nothing resolves).
- Large directories: with a blank categories setting, every listing is fetched every 15 minutes. If your directory has hundreds of listings, scope it with GeoDirectory Categories for Weather.
Related articles
- Plugin: mam-nws-weather
- Recipe: Add the Weather element to the home screen
- Hook:
mam_nws_geodirectory_categories
Metadata
| Field | Value |
|---|---|
| Article type | Recipe (Admin) |
| Plugin slug | mam-nws-weather |
| Applies to plugin version | 2.0+ |
| Category | Building Your App |
| Audience | WordPress admin |
| Estimated time | 5 minutes |
| Last verified | 2026-06-12 |
