lundi 23 mai 2016

Php Laravel framework cant access to new page

Im currently working with laravel 4 framework and Im trying to add a new page. In the routes.php file, I have included the new route

Route::resource(
       Str::slug(trans('main.appli')), 
       'AppliController', 
       array('names' => array('index' => 'appli.index'))
);

And the AppliController

class AppliController extends Controller
{
   public function index()
   {
      return "asdasdassd";
   }
}

the .htaccess file

<IfModule mod_rewrite.c>
<IfModule mod_negotiation.c>
    Options -MultiViews
</IfModule>

RewriteEngine On

# Redirect Trailing Slashes...
RewriteRule ^(.*)/$ /$1 [L,R=301]

# Handle Front Controller...
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^ index.php [L]
</IfModule>

The site that I want to add a new page to, is full site, with other pages and routes that works, but for some reason I get the error

Forbidden

You don't have permission to access /app on this server.

Once again, the whole site is working, I have also had the chance to work on another project with laravel and I did managed to add a new page for the other website with no errors.

Thanks for you help!




Aucun commentaire:

Enregistrer un commentaire