toknot/toknot

A php framework

3.0 2015-05-11 02:44 UTC

This package is auto-updated.

Last update: 2024-04-21 23:29:20 UTC


README

About

ToKnot is a php framework

http://toknot.com

Latest Stable Version Latest Unstable Version License

License

The PHP framework is under New BSD License (http://toknot.com/LICENSE.txt)

The demos is under GNU GPL version 3 or later http://opensource.org/licenses/gpl-3.0.html

Usage and Configure

On command line exec: php vendor/toknot/initapp.php App Init Guide build your app

On command line exec: php app/tool/index.php show tool app help message

在命令行中执行:php vendor/toknot/initapp.php 运行应用初始化向导,向导程序会创建应用基本目录及文件

在命令行中执行:php app/tool/index.php 显示tool应用帮助信息

Server Config

将所有请求都定向到index.php入口文件,以下是nginx与apache服务器配置方法

  • nginx:

    location  / {
        root $dir/index.php;
    }
    
  • apache:

    <Directory "/your-app-path/webroot">
        RewriteBase /
        RewriteRule .*  index.php
        RewriteEngine On
    </Directory>
    
  • PHP CLI Web Server:

    php -S 127.0.0.1:8000 index.php