About the Bright E-Learning Dashboard

The Bright E-Learning Dashboard WordPress plugin turns your Bright-powered site into a small LMS-style experience: a public catalog of learning paths, a logged-in learner dashboard, and per–learning path pages that list modules (courses), launch SCORM Cloud courses, and display the learner's progress.

It works together with:

  • The main Bright for WordPress plugin and API connection
  • The plugin provides a site-specific integration object (\Bright\Integration) that can be interacted with at a code level to control how the plugin loads learning paths and course results
  • Learning paths and steps are configurable on the Bright server using the Bright 2.0 Admin tool.

What you get (three page types)

WordPress page template Typical audience Role
Bright Dashboard – Catalog Page Visitors (and logged-in users are sent elsewhere) Marketing-style catalog: overview, “newest” path, grid of all paths
Bright Dashboard – User Dashboard Logged-in learners Personal overview, “resume” module, grid of paths with status/scores
Bright Dashboard – Learning Path Learners on a specific path Path header, stats, optional page body, then a grid of modules with launch buttons

Templates are registered by this plugin (Bright Dashboard - Catalog Page, Bright Dashboard - User Dashboard, Bright Dashboard - Learning Path) and map to PHP templates under templates/.


Prerequisites

  1. Install and enable the Bright for WordPress plugin and the Bright E-Learning Dashboard plugin.
  2. Configure Bright (API URL, realm, and other required Bright settings) so the site can call the Bright API.
  3. In your customizations / bootstrap code, set the global $bright_integration to your integration instance (subclass \Bright\Integration if you override behavior). The learning path template checks for this; without it, administrators may see a setup warning on path pages.
  4. Create the Bright\Dashboard\Configuration singleton and set at least:
    • catalog_url – URL path of your catalog page (e.g. /e-learning-catalog/)
    • user_dashboard_url – URL path of the logged-in dashboard (e.g. /user-dashboard/)
    • name – Display name for the personalized dashboard greeting

See the plugin README.md for PHP examples.


How to set a dashboard catalog page

  1. In WordPress, Pages → Add New (or edit an existing page).
  2. In Page attributes, set the template to Bright Dashboard – Catalog Page.
  3. Publish the page at the URL you assigned to catalog_url (paths should match so redirects work).
  4. Use the page editor content for the top “hero” area: the catalog template runs your content through the dashboard hero hook so you can add introductory copy.
  5. Behavior: If a user is already logged in, visiting the catalog URL redirects them to user_dashboard_url (so the catalog stays a public entry point).

How to set up a learning path page

  1. On the Bright server, ensure the learning path exists with a slug (this is the canonical path key in the API; underscores vs hyphens are normalized when resolving WordPress URLs).
  2. In WordPress, create one page per learning path.
  3. Set the page template to Bright Dashboard – Learning Path.
  4. Link the page to the path in either of these ways:
    • Recommended: With the learning path template (or a child page under it), use the Bright meta box in the page editor and choose the path from Learning Path. This saves bright_path_id in post meta and is the clearest way to bind a page to a path regardless of permalink.
    • Fallback: Leave bright_path_id empty and align the page slug with the path: the template derives a path key from the page name by turning hyphens into underscores (e.g. page slug complete-trip → path key complete_trip).
  5. Optional: add body content in the editor; it appears in the path overview area (after the stats block) via the dashboard_path_after_overview hook, and the template also outputs the_content in the main section.

URLs: Path links in grids use get_path_url, which prefers a course_url in legacy realm JSON, otherwise resolves a WordPress page whose path matches the path slug (trying slug and underscore/hyphen variants), then falls back to a simple /{slug}/ path.

“Newest” course on the catalog: At least one path in your path list should be flagged newest (legacy realm-style JSON) so the “Newest course added” block has something to show. API-backed paths may expose equivalent metadata depending on your Bright configuration.


How to configure the dashboard via the Bright 2.0 Admin editor

Learning paths and their steps are authoritative on the Bright server. In the Bright Admin (ActiveScaffold-style Learning Paths and Learning Path Steps):

Learning Path (path-level)

Edit fields such as:

  • Title – Shown on path pages and cards
  • Slug – Path key used in course custom data and URL resolution
  • Image – Default / path-level image used when a step does not override the module image
  • Force sequencing – When enabled, learners must complete the previous module before launching the next (the dashboard replaces the launch control with a “complete the previous step” message until the prior module is complete)
  • Require registration, Hidden, Active, Session key – As needed for your realm and enrollment model

Child rows Learning path steps define which courses belong to the path.

Learning Path Step (module-level)

For each step:

  • Course – Which SCORM/Bright course is this step
  • Step – Numeric order; steps are listed in ascending step order on the path page and in API-derived course custom data used for sorting on WordPress
  • Image – Optional image for this course in the context of this path (exposed in course custom as learning_paths.<slug>.image in the public course payload the dashboard consumes)
  • Custom – Optional JSON for advanced use

When courses are returned through the Bright API public_minimum (and related) templates, the server merges learning-path membership into each course’s custom JSON: the path slug is set to the step number, and learning_paths.<slug>.image is set from the step’s image. The WordPress integration then sorts modules by treating that slug field as an integer step index. So reordering in Admin is done by changing step numbers (see How to reorder courses).

Realm custom JSON (legacy): Some sites still define paths under realm custom keyed by hostname. If that data is present, WordPress may load paths from there instead of the learning_path API; administrators see a warning in wp-admin when that happens. You can prefer the API with the bright_ignore_learning_path_keys_realm_custom_data option when you are ready to migrate.


How course images are set

Images can come from several layers; the dashboard picks the most specific first.

Path and catalog cards (whole learning path)

For the catalog and user dashboard grids, each path tile uses the image url from the Bright 2.0 Admin learning path editor.

Module tiles on a learning path page

For each module in the path grid, getCourseImage (in the Bright WordPress integration) resolves in this order. The last to apply takes precedence.

  1. The learning path step course image field that can be set in the learning path editor in the Admin 2.0 interface.
  2. course.custom.learning_paths.<path_slug>.image – From the Learning Path Step image in Bright Admin (merged into API course custom as above). This usage is deprecated.
  3. course.custom.course_image – A general course-level image in course custom JSON. Course custom JSON is editable from the course editor in the Admin tool.
  4. The learning path’s own image – Editable from the learning path main page in the Admin tool.

If you only set a path-level image in Admin, all modules without their own step image fall back to that path image (or to course_image on the course).


How to reorder courses

Order is determined by the numeric step associated with each course for that path:

  • In Bright 2.0 Admin: Open the Learning Path, then Learning Path Steps. Each row has a step value. The Bright app keeps steps ordered by this field (order(:step)). Lower numbers appear first in the path module grid. Use the arrow icons to re-order the learning path steps.
  • Under the hood: The WordPress integration loads the course list, groups courses by path using the path slug field inside each course’s custom JSON, then sorts those courses by the integer value of custom.<path_slug> (which the Bright API sets from LearningPathStep#step).

So to reorder modules: use the arrow icons. After saving on the Bright server, WordPress will reflect the new order on the next course list fetch.


Optional: certificates and prerequisites

  • Certificate link on the path page appears when the path is complete and prerequisite logic passes; the default snippet points at a /learning-path-certificate style URL with query parameters—your site should provide that page and shortcode as described in README.md.
  • Prerequisites: Developers can use the dashboard_path_grid_prerequisite_courses filter to inject prerequisite “survey” courses before the main module grid unlocks.

Summary checklist

Task Where
Public catalog page WordPress page → template Bright Dashboard – Catalog Page; match catalog_url
Learner home WordPress page → template Bright Dashboard – User Dashboard; match user_dashboard_url
Path landing page WordPress page → template Bright Dashboard – Learning Path; set Bright meta box Learning Path or match slug to path key
Path metadata, sequencing, default image Bright Admin → Learning Paths
Module list, per-path images, order Bright Admin → Learning Path Steps (step, image, course)

Related files in this plugin

File Purpose
page-template.php Registers WordPress page templates
templates/catalog.php Catalog layout
templates/user-dashboard.php Logged-in dashboard layout
templates/path-page.php Single learning path layout
pluggable.php Default dashboard sections (hooks)
configuration.php Configuration singleton (catalog_url, user_dashboard_url, name)
helpers.php Learning path meta box (bright_path_id)
README.md Initial setup, asset overrides, filters