HTML with Laravel 5.2

Asked

Viewed 269 times

3

I have a button in my index. I want to call another page as I do in Aravel 5.2 ? It would be through the routes ?

1 answer

3


Correct is to use the structure of MVC going by Controller

In his View:

<a href="pagina">Ir</a>
...

In the archive Routes.php:

Route::get('pagina', 'SeuController@redireciona');

And in his Seucontroller:

public function redireciona()
{
    //Manda para view responsável pela página
    return view('suaview');
}

Browser other questions tagged

You are not signed in. Login or sign up in order to post.