{"id":15024457,"url":"https://github.com/langeler/langelermvc","last_synced_at":"2025-08-19T14:14:37.670Z","repository":{"id":254510223,"uuid":"844819487","full_name":"langeler/LangelerMVC","owner":"langeler","description":"LangelerMVC is a custom-built PHP MVC framework designed with a strong focus on structure, modularity, and best practices, including SRP, SoC, and OOP principles.","archived":false,"fork":false,"pushed_at":"2025-02-03T21:00:21.000Z","size":839,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-03-13T16:35:54.544Z","etag":null,"topics":["custom","development","mvc","oop","pdo","php","php7","php8","soc","sql","srp"],"latest_commit_sha":null,"homepage":"","language":"PHP","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/langeler.png","metadata":{"files":{"readme":"readme.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-08-20T03:10:27.000Z","updated_at":"2025-02-03T21:00:25.000Z","dependencies_parsed_at":"2024-08-23T23:42:19.307Z","dependency_job_id":"42bd2eaa-5fcb-4d02-9a10-777652e04b96","html_url":"https://github.com/langeler/LangelerMVC","commit_stats":null,"previous_names":["langeler/langelermvc"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/langeler/LangelerMVC","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/langeler%2FLangelerMVC","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/langeler%2FLangelerMVC/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/langeler%2FLangelerMVC/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/langeler%2FLangelerMVC/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/langeler","download_url":"https://codeload.github.com/langeler/LangelerMVC/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/langeler%2FLangelerMVC/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":271166354,"owners_count":24710465,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-08-19T02:00:09.176Z","response_time":63,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["custom","development","mvc","oop","pdo","php","php7","php8","soc","sql","srp"],"created_at":"2024-09-24T20:00:23.072Z","updated_at":"2025-08-19T14:14:37.636Z","avatar_url":"https://github.com/langeler.png","language":"PHP","funding_links":[],"categories":[],"sub_categories":[],"readme":"![Logo](./logo.jpeg)\n\n# LangelerMVC Framework\n\n[![PHP Version](https://img.shields.io/badge/PHP-7.4%20%7C%208.x-blue.svg)](https://www.php.net/)\n**A PHP 7.4 / 8+ MVC Framework focusing on structure, adhering to the Single Responsibility Principle (SRP), Separation of Concerns (SoC), and Object-Oriented Programming (OOP)**.\n\n---\n\n## Table of Contents\n\n- [Project Overview](#project-overview)\n- [Features](#features)\n- [Installation](#installation)\n- [Directory Structure](#directory-structure)\n  - [Complete Directory Breakdown](#complete-directory-breakdown)\n- [Configuration](#configuration)\n- [Usage](#usage)\n- [Development Status](#development-status)\n- [Testing](#testing)\n- [Contributing](#contributing)\n- [Support](#support)\n- [License](#license)\n\n---\n\n## Project Overview\n\nLangelerMVC is a custom-built PHP MVC framework designed to provide a highly structured and modular approach to building web applications. The framework adheres to important design principles such as:\n\n- **Single Responsibility Principle (SRP)**: Ensuring each class is responsible for only one part of the functionality.\n- **Separation of Concerns (SoC)**: Encouraging separation between distinct functionalities to enhance maintainability.\n- **Object-Oriented Programming (OOP)**: Utilizing OOP practices like inheritance, encapsulation, and polymorphism.\n\nThis framework is ideal for developers who want a solid foundation for building scalable PHP applications using modern best practices.\n\n---\n\n## Features\n\n- **MVC Architecture** (Model-View-Controller)\n- **PHP 7.4+ Support**\n- **Modular Design** with Admin and User Modules\n- **SQL Integration** with MySQL using PDO\n- **Custom Templating System** with Layouts, Pages, Partials, and Components\n- **Security Features** like 2FA (Two-Factor Authentication) and secure email verification\n- **Localization Support** including locale management and number formatting\n- **Detailed Error and Exception Handling**\n- **PSR-4 Autoloading**\n- **Mailer Integration** (SMTP)\n- **Shell Command Execution**, Stream Handling, and Sockets\n- **Custom Validators and Sanitizers**\n- **Unit and Integration Testing with PHPUnit**\n\n---\n\n## Installation\n\n### Prerequisites\n\n- PHP 7.4 or PHP 8.0+\n- MySQL Database\n- Composer\n\n### Steps\n\n1. Clone the repository:\n\n\t```bash\n\tgit clone https://github.com/langeler/LangelerMVC.git\n\tcd LangelerMVC\n\t```\n\n2. Install the dependencies:\n\n\t```bash\n\tcomposer install\n\t```\n\n3. Copy the example environment file and update settings:\n\n\t```bash\n\tcp .env.example .env\n\t```\n\n4. Set up your `.env` configuration file:\n\n\t```ini\n\tAPP_NAME=\"Langeler\"\n\tAPP_ENV=local\n\tAPP_DEBUG=true\n\tAPP_URL=http://localhost\n\tDB_CONNECTION=mysql\n\tDB_HOST=127.0.0.1\n\tDB_PORT=3306\n\tDB_DATABASE=langeler\n\tDB_USERNAME=root\n\tDB_PASSWORD=root\n\t```\n\n5. Set up your database:\n\n\t```bash\n\tphp artisan migrate\n\t```\n\n6. Run the application:\n\n\t```bash\n\tphp -S localhost:8000 -t Public/\n\t```\n\n---\n\n## Directory Structure\n\nLangelerMVC is designed with modularity in mind, making it easier to maintain and scale the application. Below is a complete breakdown of the core directory structure with detailed explanations of each subfolder.\n\n### Complete Directory Breakdown\n\n```\nLangelerMVC/\n├── App/                        # Core application code\n│   ├── Abstracts/              # Abstract classes for common functionality\n│   ├── Contracts/              # Interface contracts for dependency injection\n│   ├── Core/                   # Core framework logic, including bootstrap and initial loaders\n│   ├── Database/               # Database layer, including migrations, models, repositories, seeds\n│   │   ├── Migrations/         # Database migrations\n│   │   ├── Models/             # Eloquent models or custom database models\n│   │   ├── Repositories/       # Data access layers (Repository pattern)\n│   │   ├── Seeds/              # Database seeders\n│   ├── Exceptions/             # Custom exception classes for error handling\n│   ├── Helpers/                # Utility helper classes for common operations\n│   ├── Modules/                # Application modules, including Admin and User Modules\n│   │   ├── AdminModule/        # Admin-specific logic and components\n│   │   │   ├── Controllers/    # Admin controllers for handling requests\n│   │   │   ├── Middlewares/    # Admin-specific middlewares for security and other purposes\n│   │   │   ├── Requests/       # Request validation logic for Admin routes\n│   │   │   ├── Responses/      # Response handling for Admin routes\n│   │   │   ├── Routes/         # Admin route definitions\n│   │   │   ├── Views/          # Views/templates related to the Admin panel\n│   │   ├── UserModule/         # Similar to AdminModule, but for user-facing logic\n│   ├── Presenters/             # Data presentation layer (e.g., formatting data for views)\n│   ├── Resources/              # Static resources (CSS, JS, Images)\n│   │   ├── css/                # Custom stylesheets\n│   │   ├── images/             # Image files\n│   │   ├── js/                 # Custom JavaScript files\n│   ├── Services/               # Service layer for handling complex operations\n│   ├── Templates/              # Template files (layouts, components, partials, pages)\n│   │   ├── Components/         # Reusable view components (e.g., buttons, modals)\n│   │   ├── Layouts/            # Page layouts (e.g., header, footer)\n│   │   ├── Pages/              # Individual page views\n│   │   ├── Partials/           # Smaller reusable parts of pages (e.g., navigation)\n│   ├── Utilities/              # Utility classes for additional functionalities\n│       ├── Sanitation/         # Data sanitation methods and tools\n│       ├── Validation/         # Custom validation logic and rules\n├── Config/                     # Configuration files for different aspects of the application\n│   ├── app.php                 # Application-specific configuration\n│   ├── database.php            # Database connection configuration\n│   ├── feature.php             # Feature toggles and settings\n│   ├── mail.php                # Mail configuration settings\n├── Data/                       # SQL data dumps and seed files\n│   ├── Carts.sql               # Example SQL dump for carts table\n│   ├── Orders.sql              # Example SQL dump for orders table\n│   ├── Products.sql            # Example SQL dump for products table\n│   ├── Users.sql               # Example SQL dump for users table\n├── Public/                     # Public-facing files and assets\n│   ├── assets/                 # Frontend assets (CSS, JS, Images)\n│   │   ├── css/                # Compiled and minified CSS\n│   │   ├── images/             # Public images for the web app\n│   │   ├── js/                 # Compiled and minified JS\n│   ├── .htaccess               # URL rewriting and security rules\n│   ├── index.php               # Main entry point for the application\n├── Storage/                    # Storage for logs, cache, and uploaded files\n│   ├── Cache/                  # Cache files for performance improvements\n│   ├── Logs/                   # Log files for debugging\n│   ├── Uploads/                # Uploaded user files\n├── Tests/                      # Unit and Integration test suites\n│   ├── Integration/            # Integration tests for testing multiple parts together\n│   ├── Unit/                   # Unit tests for isolated testing of components\n├── Vendor/                     # Composer dependencies\n├── .env                        # Application environment variables\n├── .env.example                # Example environment configuration file\n├── .gitignore                  # Git ignore file\n├── composer.json               # Composer configuration for dependencies and autoloading\n├── composer.lock               # Composer lock file\n└── README.md                   # Project documentation\n```\n\n---\n\n## Configuration\n\n### `.env` Example:\n\n```ini\nAPP_NAME=\"Langeler\"\nAPP_ENV=local\nAPP_DEBUG=true\nAPP_URL=http://localhost\nDB_CONNECTION=mysql\nDB_HOST=127.0.0.1\nDB_PORT=3306\nDB_DATABASE=langeler\nDB_USERNAME=root\nDB_PASSWORD=root\n```\n\n**Mail Configuration**:\n\n```ini\nMAIL_DRIVER=smtp\nMAIL_HOST=smtp.langeler.se\nMAIL_PORT=587\nMAIL_USERNAME=noreply@langeler.se\nMAIL_PASSWORD=secret\nMAIL_ENCRYPTION=tls\n```\n\n---\n\n## Usage\n\n### URL Rewriting and Security\n\nLangelerMVC uses a `.htaccess` file for clean URL rewriting and security headers:\n\n- Redirect all requests to `index.php`\n- Deny access to sensitive files like `.htaccess`, `.env`, and Composer files\n- Add security headers for protection against MIME sniffing, XSS, and Clickjacking\n\n### Shell and Stream Handling\n\nThe framework includes handlers for shell commands and stream management, making it easy to execute commands and manage file streams and sockets securely.\n\n---\n\n## Development Status\n\n### **Under Active Development**\n\nLangelerMVC is currently under active development, and several key features are still being implemented or refined. Below is a list of features currently being developed or improved:\n\n- **Advanced Routing**: Additional support for RESTful routes and route groups.\n- **Admin Dashboard Enhancements**: More features and UI improvements for the admin panel.\n- **User Module Improvements**: Better user profile management, enhanced security, and user activity logging.\n- **More Built-in Validators**: Including more built-in rules and support for custom validation logic.\n- **Localization**: Improvements in multilingual support and content translation.\n- **Enhanced Security Features**: Additional security layers, such as role-based access control (RBAC), and security auditing tools.\n- **Performance Optimizations**: Optimizing SQL queries, caching, and memory usage for better performance.\n\nStay tuned for upcoming features and releases!\n\n---\n\n## Testing\n\nLangelerMVC supports unit and integration testing with **PHPUnit**.\n\nTo run the tests:\n\n```bash\ncomposer test\n```\n\nTests are located in the `Tests/` directory, separated into **Unit** and **Integration** tests.\n\n---\n\n## Contributing\n\nContributions are highly encouraged and welcome!\n\n1. **Fork** the repository.\n2. **Create a feature branch**: `git checkout -b my-feature`.\n3. **Commit your changes**: `git commit -m 'Add a feature'`.\n4. **Push to the branch**: `git push origin my-feature`.\n5. **Open a Pull Request**.\n\n---\n\n## Support\n\nFor any issues, suggestions, or feature requests, feel free to:\n\n- Open an [Issue on GitHub](https://github.com/langeler/LangelerMVC/issues).\n- Contribute to the [LangelerMVC Wiki](https://github.com/langeler/LangelerMVC/wiki).\n\n---\n\n## License\n\nThis project is licensed under the MIT License. See the [LICENSE](https://github.com/langeler/LangelerMVC/blob/main/LICENSE) file for details.\n\n---\n\n## GitHub Links\n\n- **Developer GitHub**: [https://github.com/langeler](https://github.com/langeler)\n- **Project GitHub**: [https://github.com/langeler/LangelerMVC](https://github.com/langeler/LangelerMVC)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flangeler%2Flangelermvc","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Flangeler%2Flangelermvc","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flangeler%2Flangelermvc/lists"}