I'm having trouble with a link I've created in a view heading to a route . Here is the error:
ErrorException
Route [/user/addUser] not defined
.(View: /var/www/projeto/app/views/principal/index.blade.php)
Routes:
Route::get('/', function()
{
return View::make('principal.index');
});
Route: get ('/ user / addUser', 'AdminUserController @ addUser');
Controller:
class AdminUserController extends BaseController {
public function __construct(){
parent::__construct;
}
public function addUser()
{
return View::make('user.addUser');
}
}
View:
@extends('layout.main')
@section('header')
<a href="{{URL::route('/user/addUser')}}"><button class= "btn btn-primary">Novo Cadastro</button></a>
@stop
@section('content')
@stop
@section('footer')
@stop