我正在使用带有php 5.3.13的laravel 4.1但路由不起作用。 我在“about.php”视图下创建了一个简单的页面,并在我的路由中添加了:
Route::get('/', function()
{
return View::make('hello');
});
Route::get('about', function()
{
return View::make('about');
});
Route::resource('user', 'userInscriptionController');
Route::group(array('prefix' => ''), function()
{
Route::resource('user', 'userInscriptionController');
});
但只有“你好”页面有效,其他人给我以下信息:
Not Found
The requested URL /driving/public/about was not found on this server.
答案 0 :(得分:0)
我猜你正在使用apache,如果是这样的话,AllowOverride Option设置为none,那么laravel附带的.htaccess文件启用“漂亮的url”它没有被加载。
尝试http://mywebserver/mylaravelwebsite/index.php/about
它应该有用。