Plugin Directory Structure Estimated reading: 3 minutes 66 views Summary: Learn how the EazyLMS directory structure is organized. Explore how the plugin uses WordPress metadata and EazyDocs hierarchy to create a robust, lightweight learning management system for WordPress. The EazyLMS plugin is architected to integrate seamlessly with the EazyDocs ecosystem, leveraging its existing documentation hierarchy. Unlike standalone LMS solutions that register custom database tables, EazyLMS utilizes native WordPress metadata, ensuring a lightweight and efficient performance. Understanding the plugin directory structure is essential for developers looking to customize, extend, or perform advanced troubleshooting on their course platform. Core Plugin Directory Layout The plugin root contains the bootstrap logic and core definitions, while specific functionality is compartmentalized into dedicated directories. Below is an overview of the primary structure: eazylms.php: The main entry point; handles singleton initialization, constant definitions, and file loading. includes/: The heart of the plugin, containing all backend logic, API handling, and admin configurations. includes/admin/: Manages the custom dashboard, Managing User Roles and Access in Docy: Best Practices and Plugin Recommendations interfaces, and per-post meta boxes. includes/woocommerce/: Contains the integration logic for payments and enrollment synchronization. src/ & build/: These folders house the React-powered admin applications and their compiled assets. Architecture and Bootstrap Flow Upon activation, the EazyLMS class triggers a series of events defined in eazylms.php. This ensures that dependencies like EazyDocs are validated and that constant variables (such as EAZYLMS_VERSION and EAZYLMS_PATH) are available globally. This architecture ensures that the plugin only loads the necessary components, such as the features, when required. Data Handling and Storage EazyLMS does not register new post types. Instead, it reuses the docs post type registered by EazyDocs. Data differentiation is achieved through post hierarchy: Depth 0: Represented as Courses. Depth 1: Represented as Modules or Sections. Depth 2+: Represented as Lessons or Quizzes. Course-level settings are stored within the eazylms_options meta key, while specific student progress is serialized within eazy_topic_data. For developers interested in The Advantages and Disadvantages of Developing a Custom WordPress Theme, this reliance on native WordPress postmeta allows for easy data manipulation and backups using standard WP functions. Customization and Extending Functionality If you need to modify the display of course pages, the eazydocs/single-docs.php file provides a template override mechanism. By copying this file to your child theme, you can customize the course interface without modifying core plugin files. Additionally, the REST API endpoints found in includes/api/rest-api.php allow developers to build external integrations or custom student dashboards. By maintaining a strict separation of concerns—keeping admin logic separate from frontend assets and React build tools—EazyLMS provides a developer-friendly environment that adheres to WordPress best practices. Tagged:ArchitectureDevelopmentPlugin Structure Plugin Directory Structure - PreviousDeveloper ResourcesNext - Plugin Directory StructureWorking with REST API