=== CourseGlade LMS - Online Course & eLearning Platform ===
Contributors: devitemsllc
Tags: lms, elearning, online courses, education, courses
Requires at least: 6.4
Tested up to: 7.0
Stable tag: 1.1.0
Requires PHP: 7.4
License: GPLv2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html

A complete Learning Management System for WordPress with courses, quizzes, multi-instructor support, and built-in payments.

== Description ==

CourseGlade is a full-featured Learning Management System plugin for WordPress. Build and sell online courses, manage students and instructors, and deliver engaging learning experiences — all from your WordPress site.

👇 **Helpful Links to Get Started**

🔍 [Learn More](https://courseglade.com/) | 🚀 [Explore Pro](https://courseglade.com/pricing/)

**Key Features**

* 7 quiz question types (multiple choice, true/false, fill in the blank, matching, ordering, short answer, essay)
* Multi-instructor support with earnings and withdrawal management
* Become-an-instructor application flow with admin approval
* Public instructor profiles at /instructor/{username}/
* Built-in payment processing with Stripe, WooCommerce, Manual, and Free (zero-price) gateways
* Coupons and discounts, plus free course enrolment
* Student dashboard with progress tracking and a course wishlist
* Course reviews and discussion boards
* Course categories, tags, and difficulty levels
* Transactional email notifications (enrolment, course completion, orders, instructor applications)
* Maintenance mode for your learning site
* Shortcodes for course grids, dashboard, checkout, and authentication pages

**More Free Features**

* Drag-and-drop course builder with sections, lessons, and quizzes
* Video lessons from YouTube, Vimeo, self-hosted, or any oEmbed provider — one player for every source, and the lesson completes itself when the video ends
* Audio lessons, with the same automatic completion when the track finishes
* Export and import your settings, with a resumable job runner and an undo for an import that went wrong
* A setup checklist on the dashboard, so a new site can see what is left to configure
* Distraction-free learning mode with a curriculum drawer and progress tracking
* Course catalog with search, category filtering, and pagination
* Custom student and instructor roles with granular capabilities
* Custom avatar uploads (falls back to Gravatar)
* React-based admin with a clean dashboard, orders, students, and reports
* Fully translation-ready (`.pot` included) and block-theme compatible

**CourseGlade Pro — Premium Add-ons**

CourseGlade Pro extends the free plugin with independently toggleable add-ons (requires the separate CourseGlade LMS Pro plugin):

* **Subscriptions & Memberships** — sell recurring access to a course, a category, or your whole catalogue, with plans, trials, renewals, and cancellations
* **AI Studio** — write any field from a brief, or generate a whole course: modules, lessons, quizzes with questions, and assignments. Bring your own API key
* **Bulk Enrolment** — enrol many students at once, or import them from a CSV
* **Social Login** — let students sign in with an existing account
* **Import & Export (content)** — move courses, lessons, quizzes, questions, curriculum, terms, and media between sites
* **Certificates** — auto-issue completion certificates with custom templates and shareable, verifiable certificate numbers
* **Assignments** — file-upload assignments with instructor grading and feedback
* **Content Drip** — release lessons and modules on a schedule or by enrolment date
* **Leaderboard & Gamification** — award points and badges, and rank learners
* **Gradebook** — a per-student grade overview across quizzes and assignments
* **Advanced Email** — broadcast campaigns, a send queue, and expanded notification events
* **Course Bundles** — sell groups of courses together as a single product
* **Advanced Reports** — detailed revenue, enrolment, course, and instructor analytics
* **Live Classes (Zoom & Google Meet)** — schedule and host live sessions with per-instructor connections
* **Google Classroom** — import and sync course rosters
* **White Label** — rebrand the admin with your own name, logo, and colours

== Installation ==

1. Upload the `courseglade-lms` folder to the `/wp-content/plugins/` directory, or install via the WordPress plugin installer.
2. Activate the plugin through the **Plugins** menu in WordPress.
3. Navigate to **CourseGlade** in the admin menu to complete setup.
4. Configure payment gateways under **CourseGlade → Settings → Payments**.

== Frequently Asked Questions ==

= Does CourseGlade work with any WordPress theme? =

Yes. CourseGlade includes its own frontend templates that work with any theme. Block-theme support is included.

= What payment gateways are supported? =

Stripe, WooCommerce, Manual payment, and Free (zero-price) enrolment are supported in the free version.

= Can I have multiple instructors? =

Yes. You can invite instructors, set commission rates, and manage withdrawal requests from the admin.

= Is the plugin translation-ready? =

Yes. All strings use the `courseglade-lms` text domain and a `.pot` file is included in `languages/`.

= Is there a Pro version? =

Yes. CourseGlade LMS Pro adds premium add-ons — Certificates, Assignments, Content Drip, Leaderboard & Gamification, Gradebook, Advanced Email, Course Bundles, Advanced Reports, Live Classes (Zoom & Google Meet), Google Classroom, and White Label. Each can be enabled or disabled independently. The free plugin is fully functional on its own.

== Source Code ==

The admin interface is built with React (Vite). The full, unminified source code is included in the plugin under `assets/admin/src/`. The compiled output is at `assets/admin/build/`.

To rebuild the admin assets:

1. `cd assets/admin`
2. `npm install`
3. `npm run build`

== External Services ==

This plugin connects to the following external services:

**Stripe**
Used to process course payments when the Stripe gateway is enabled. Checkout sessions are created against the Stripe API and the student is then redirected to Stripe's own hosted checkout page to pay.
- Data sent: payment amount, currency, customer email, course details
- When sent: only during checkout when a student purchases a course
- Service URL: https://api.stripe.com (and Stripe's hosted checkout at https://checkout.stripe.com)
- Terms of Service: https://stripe.com/legal
- Privacy Policy: https://stripe.com/privacy

**Video embeds (YouTube, Vimeo)**
Used to embed lesson videos when an instructor provides a YouTube or Vimeo video URL for a lesson. YouTube is embedded through youtube-nocookie.com. If an instructor instead chooses the "Embed" video source, WordPress's built-in oEmbed fetches the markup from whichever provider the supplied URL belongs to, under that provider's own terms and privacy policy.
- Data sent: standard browser request (IP address, browser info) when the video is loaded
- When sent: only when a student views a lesson that has a YouTube or Vimeo video URL set
- YouTube — Service URL: https://www.youtube-nocookie.com | Terms: https://www.youtube.com/t/terms | Privacy: https://policies.google.com/privacy
- Vimeo — Service URL: https://vimeo.com | Terms: https://vimeo.com/terms | Privacy: https://vimeo.com/privacy

== Screenshots ==

1. Admin dashboard — revenue, top courses, and quick actions
2. Admin — Course Management list
3. Admin — Students list
4. Admin — Orders list
5. Course builder — general course settings
6. Course builder — drag-and-drop curriculum editor
7. Course builder — quiz question editor
8. Course catalog — browse all published courses
9. Single course page — curriculum, pricing, and enroll button
10. Learning mode — lesson player with progress tracking
11. Quiz player — interactive question types
12. Instructor dashboard — earnings and student overview
13. Instructor public profile
14. Checkout page

== Changelog ==

= 1.1.0 =
**New**
* Audio lessons. Add an audio track to a lesson and it plays in the learning area, with the lesson completing itself when the track finishes.
* One player for every video source. Self-hosted, YouTube and Vimeo lessons now share the same controls, and a lesson marks itself complete when the video reaches the end — which YouTube and Vimeo lessons previously never did.
* Export and import. Move settings between sites as a portable file, with a job runner that resumes where it left off and can undo an import that went wrong.
* A setup checklist on the dashboard, so a new site can see what is left to configure.

**Fixes**
* An unexpected error during checkout no longer fails as a blank page. Requests that go wrong now return a proper error the site can act on, instead of a PHP fatal that could also print server paths when error display is switched on.
* Instructor invitations work. The acceptance link was broken, and accepting one did not finish setting the account up.
* A video lesson could not be saved in some cases.

= 1.0.2 =
**New & improved**
* Course pages now use your theme's fonts. The plugin no longer forces its own font family on the frontend, so changing fonts in your theme or global styles takes effect everywhere.

**Fixes**
* The course builder now sends the course along with content drip requests, so drip rules can be set on a lesson while it is still being created.

= 1.0.1 =
**Security**
* Restricted the enrollment REST endpoints to administrators (were reachable with an instructor-level capability).
* Escaped instructor-application data returned by the REST API.
* Closed several per-course ownership gaps and stopped quiz endpoints exposing answer keys.
* Added login throttling; the instructor user-picker now searches by name only and no longer exposes emails.

**New & improved**
* Course cards show the instructor's avatar linked to their public profile.
* Maintenance mode now also covers the course archive and category/tag/difficulty pages, with a new filter to adjust its scope.
* Real avatars now appear in quiz grading, submissions, and order details.

**Fixes**
* Scheduled maintenance tasks (cache cleanup, stale-order cancellation, enrollment expiry, stats refresh) now actually run on cron.
* Made order and withdrawal status transitions atomic to prevent duplicate processing.
* Blocked creating a duplicate order while one is still pending for the same course.
* Numerous settings, learning-mode, and responsive-layout fixes.

**Performance**
* Removed N+1 queries from the instructor and order lists and batched dashboard revenue calculations.
* Per-order options are no longer autoloaded on every request.

= 1.0.0 =
* Initial release
