Features Pricing Docs Compare Log in Get started free
Docs Developer & REST Plugin Architecture & File Structure

Plugin Architecture & File Structure

6 min read Updated Jun 13, 2026 Applies to: Free & Pro

PlayCourse follows standard WordPress plugin conventions with a clear separation of concerns.

File structure

playcourse-lms/
playcourse-lms.php        # bootstrap, constants, hooks
includes/
  class-playcourse.php    # main loader (singleton)
  post-types/             # courses, lessons, quizzes (CPTs)
  rest/                   # REST API controllers
  shortcodes/             # shortcode handlers
  widgets/                # Elementor widgets
templates/                # overridable front-end templates
assets/                   # css, js, images
languages/                # .pot / translations

Data model

  • Courses, lessons, topics and quizzes are custom post types.
  • Curriculum order and relationships are stored as post meta.
  • Enrollments and progress live in dedicated tables for performance.

Request lifecycle

On plugins_loaded the main class boots, registers CPTs and routes, then wires the front-end renderer. Pro hooks into the same lifecycle and adds its features only when a valid license is active.

Was this article helpful?