samsonos/php_htaccess

SamsonPHP htaccess 创建模块

dev-master 2014-12-11 13:52 UTC

This package is not auto-updated.

Last update: 2024-09-14 16:18:52 UTC


README

#SamsonPHP 自动创建 htaccess 规则的模块

##在项目中使用模块 要在项目中使用 SamsonPHP 框架,您必须在您的 composer.json 中添加其依赖项

    "require": {
        "samsonos/php_htaccess": "*"
    }, 

为了从您的 .txt 文件解析 404 规则,您必须创建配置并调用 error404() 方法

示例用法

// Create configuration class
class HtaccessConfig extends \samson\core\Config
{
    public $__module = 'htaccesscreate';

    public $domain 	= 'example.com';
}

/*
*
*
*
*/

// Call parsing method
m('htaccesscreate')->error404('myfile.txt');

SamsonOS 开发