您好,欢迎访问一九零五行业门户网

php框架 - 一个PHPixie框架的问题

1. 安装框架
php composer.phar create-project phpixie/project your_project_folder

2.设置路径
原文:and here are rules for apache2 (put into .htaccess in project root
folder):
rewriteengine onrewritebase /rewritecond %{request_uri} !web/rewriterule (.*) /web/$1 [l]我把apache的localhost指向了 localhost/phpixie/web,同时把上面的.htaccess塞在了phpixie路径下(根目录)。

这时候访问http://localhost 可以得到phpixie的欢迎界面
3. 配置一个控制器
// bundles/app/src/project/app/httpprocessors/quickstart.php
namespace project\app\httpprocessors;
use phpixie\http\request;
// we extend a class that allows controller-like behavior
class quickstart extends \phpixie\defaultbundle\processor\http\actions
{
/**

the builder will be used to access
various parts of the framework later on
@var project\app\httpprocessors\builder
*/
$builder;
function __construct($builder)
{
$this->builder = $builder;

}
// this is the default action
function defaultaction(request $request)
{
return quickstart tutorial;

}
//we will be adding methods here in a moment
}
// bundles/app/src/project/app/httpprocessor.php//... protected function buildquickstartprocessor() { return new httpprocessors\quickstart( $this->builder ); }//...然后访问 **http://localhost/quickstart/** 却发现是404

求大神赐教我是哪里配置错了???
原文地址:http://www.phpixie.com/quickstart.html
回复内容: 1. 安装框架
php composer.phar create-project phpixie/project your_project_folder

2.设置路径
原文:and here are rules for apache2 (put into .htaccess in project root
folder):
rewriteengine onrewritebase /rewritecond %{request_uri} !web/rewriterule (.*) /web/$1 [l]我把apache的localhost指向了 localhost/phpixie/web,同时把上面的.htaccess塞在了phpixie路径下(根目录)。

这时候访问http://localhost 可以得到phpixie的欢迎界面
3. 配置一个控制器
// bundles/app/src/project/app/httpprocessors/quickstart.php
namespace project\app\httpprocessors;
use phpixie\http\request;
// we extend a class that allows controller-like behavior
class quickstart extends \phpixie\defaultbundle\processor\http\actions
{
/**

the builder will be used to access
various parts of the framework later on
@var project\app\httpprocessors\builder
*/
$builder;
function __construct($builder)
{
$this->builder = $builder;

}
// this is the default action
function defaultaction(request $request)
{
return quickstart tutorial;

}
//we will be adding methods here in a moment
}
// bundles/app/src/project/app/httpprocessor.php//... protected function buildquickstartprocessor() { return new httpprocessors\quickstart( $this->builder ); }//...然后访问 **http://localhost/quickstart/** 却发现是404

求大神赐教我是哪里配置错了???
原文地址:http://www.phpixie.com/quickstart.html
其它类似信息

推荐信息