2017 © Pedro Peláez
 

project framework

A simple PHP framework

image

prob/framework

A simple PHP framework

  • Monday, March 27, 2017
  • by jongpak
  • Repository
  • 2 Watchers
  • 3 Stars
  • 4 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 1 Forks
  • 23 Open issues
  • 2 Versions
  • 0 % Grown

The README.md

Prob/Framework

A simple PHP framework, (*1)

Build Status Scrutinizer Code Quality codecov, (*2)

Installation

Copy sample configuration

$ cp .htaccess.example .htaccess
$ cp config/site.php.example config/site.php
$ cp config/db.php.example config/db.php
$ cp app/Auth/config/config.php.example app/Auth/config/config.php
$ cp app/Auth/config/accounts.php.example app/Auth/config/accounts.php

Setting configuration for your environment

.htaccess, (*3)

RewriteBase ** YOUR_WEB_SITE_URL_PATH (ex: / or /prob) **

config/site.php, (*4)

'url' => '/',
'publicPath' => '/public/',

config/db.php, (*5)

'host'      => 'localhost',
'port'      => 3306,
'user'      => 'username',
'password'  => 'password',
'dbname'    => 'dbname',
'charset'   => 'utf8'

app/Auth/config/config.php, (*6)

'defaultAllow' => true,
'defaultAccountManager' => 'FileBaseAccountManager',
'defaultLoginManager' => 'SessionLoginManager',
'defaultPermissionManager' => 'FileBasePermissionManager',
// ...

app/Auth/config/accounts.php, (*7)

return [
    // ...

    'test' => [
        'password' => 'test',
        'role' => [ 'Member' ]
    ],

    //*** Add YOUR ACCONUTS
];

Making directories

$ mkdir data

Dependency package update (use Composer)

$ composer update

Creating table schema

$ php ./vendor/doctrine/orm/bin/doctrine.php orm:schema-tool:create

Starting a web application (using PHP built-in server)

$ php -S 127.0.0.1:8080 -t public/, (*8)

The Versions