A lightweight PHP framework based on the MVC pattern.
It also includes a simple MySQL-PDO-Database library.
Part of the routing is done with a simple .htaccess file.
URL requests should look like this: /controller/method/parameter
. It will either default to the base-controller or to the error-controller if an invalid url was passed.
Naming convention:
- Model
nameModel.php
can@extend BaseModel
- View
name.php
- Controller
nameController.php
can@extend BaseController
Database library documentation coming soon.
Use the included .htaccess
file.
Include the following code into the respective server block.
location = / {
index index.php;
}
location / {
try_files $uri $uri.html $uri/;
index index.php;
if (!-e $request_filename) {
rewrite ^/(.+)$ /index.php?url=$1;
}
}
Simply clone/copy this project to your working Apache webserver and import the sql file located in the sql
directory.
See /app/config/config.php
.
The latest working build is available at this site.
unio-php is licensed under the MIT License.