title: How to get Route URL param in Controller | Laravel
body: <p>I have the following route:</p>
  
  <pre><code>Route::get('/category/{category}/keyword/{keyword}', 'CategoryController@search');
  </code></pre>
  
  <p>In my controller I am trying to retrieve both the URL params using the following code:</p>
  
  <pre><code>public function search(Request $request)
  {
      $request-&gt;all();
      ...
  }
  </code></pre>
  
  <p>The above code doesn't return the value of parameters.</p>
  
  <p>If I call the following code, I get the value:</p>
  
  <pre><code>$request-&gt;category
  </code></pre>
  
  <p>Can someone tell me what am I doing wrong?</p>
  
  <p>Thanks!</p>