title: Passing request parameter to View - Laravel
body: <p>Is it possible to pass a <code>route</code> parameter to a controller to then pass to a view in <code>laravel</code>?</p>
  
  <p>Example;</p>
  
  <p>I have the route below;</p>
  
  <pre><code>Route::get('post/{id}/{name}', 'BlogController@post')-&gt;name('blog-post');
  </code></pre>
  
  <p>I want to pass <code>{id}</code> and <code>{name}</code> to my view so in my controller</p>
  
  <pre><code>class BlogController extends Controller
  {
      //
       public function post () {
  
       //get id and name and pass it to the view
  
          return view('pages.blog.post');
      }
  }
  </code></pre>