pixlmint / nacho
My own Lightweight PHP Framework
1.6.10
2025-01-09 21:44 UTC
Requires
- php: 8.*
- ext-fileinfo: *
- php-di/php-di: ^7.0
- pixlmint/parsedown: *
- psr/log: ^3.0
- symfony/yaml: ^5.2
Requires (Dev)
- phpunit/phpunit: ^11
- dev-master
- 1.6.10
- 1.6.9
- 1.6.8
- 1.6.7
- 1.6.6
- 1.6.5
- 1.6.4
- 1.6.3
- 1.6.2
- 1.6.1
- 1.6.0
- 1.5.9
- 1.5.8
- 1.5.7
- 1.5.6
- 1.5.5
- 1.5.4
- 1.5.3
- 1.5.2
- 1.5.1
- 1.5.0
- 1.4.7
- 1.4.6
- 1.4.5
- 1.4.4
- 1.4.3
- 1.4.2
- 1.4.1
- 1.4.0
- 1.3.7
- 1.3.6
- 1.3.5
- 1.3.4
- 1.3.3
- 1.3.2
- 1.3.1
- 1.3.0
- 1.2
- 1.1
- 1.0
- 0.46
- 0.45
- 0.44
- 0.43
- 0.42
- 0.41
- 0.40
- 0.39
- 0.38
- 0.37
- 0.36
- 0.35
- 0.34
- 0.33
- 0.32
- 0.31
- 0.30
- 0.29
- 0.28
- 0.27
- 0.26
- 0.25
- 0.24
- 0.23
- 0.22
- 0.21
- 0.20
- 0.19
- 0.18
- 0.17
- 0.16
- 0.15
- 0.14
- 0.13
- 0.12
- 0.11
- 0.10
- 0.9
- 0.8
- 0.7
- 0.6
- 0.5
- 0.4
- 0.2
- 0.1
- 0.0.1
- dev-php7_4
- dev-testing
- dev-orm
- dev-data-handling
- dev-hooks
- dev-configuration
This package is auto-updated.
Last update: 2025-01-09 21:45:03 UTC
README
About
This is my own little PHP Framework, slowly developed as I need functionality in my own projects.
Installation
composer require pixlmint/nacho
- Copy
public/index.php
to your root directory
First Endpoint
- Add a
config.php
file under/config
with the following content:
<?php return [ 'routes' => [ [ "route" => "/", "controller" => App\Controllers\HomeController, "function" => "index" ], ], ];
- Create a file
HomeController.php
undersrc/Controllers
, add the following Content:
<?php namespace App\Controllers; use Nacho\Controllers\AbstractControllers; use Nacho\Models\Request; class HomeController extends AbstractController { public function index(Request $request) { return "hello world"; } }
- Add
.htaccess
<IfModule mod_rewrite.c> RewriteEngine On RewriteRule ^(src|.vscode|content|node_modules|CHANGELOG\.md|.secret|users.json|composer\.(json|lock|phar))(/|$) index.php # Enable URL rewriting RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d RewriteRule .? index.php [L] </IfModule> # Prevent file browsing Options -Indexes -MultiViews