title: How to pass 2 parameters in a route, but make one hidden in Laravel?
body: <p>I want to make an edit_Item functionality, but I'm having a little bit of trouble with routing when submiting the edited form. I get this error:</p>
  
  <pre><code>InvalidArgumentException in UrlGenerator.php line 314:
  Route [userItems] not defined.
  </code></pre>
  
  <p>First of all, in my Edit page, I have a form which passes 2 arguments from the Items table (item_id and user_id) to the controller and it looks like this:</p>
  
  <pre><code>{!! Form::model($items, ['action' =&gt; ['ItemController@update', $items-&gt;id, $items-&gt;user_id], 'method' =&gt; 'PUT']) !!}
      //Form inputs                    
  {{ Form::close() }}
  </code></pre>
  
  <p>My Update controller looks like this:</p>
  
  <pre><code>public function update($id, $user_id){
      // validate
      // read more on validation at http://laravel.com/docs/validation
      $rules = array(
          'title'       =&gt; 'required',
          'description'      =&gt; 'required|description',
      );
      // store
      $items = Item::find($id);
      $items-&gt;title = Input::get('title');
      $items-&gt;description = Input::get('description');
      $items-&gt;save();
  
      // redirect
      Session::flash('message', 'Successfully updated item!');
      return Redirect::route('userItems');
  }
  </code></pre>
  
  <p>And my Route with the Update method looks like this:</p>
  
  <pre><code>Route::put('/userItems/{id}/{user_id}', 'ItemController@update');
  </code></pre>
  
  <p>Now, when I submit I'm currently getting routed to:</p>
  
  <pre><code>http://localhost:8000/userItems/26/3
  </code></pre>
  
  <p>And I need to get routed to:</p>
  
  <pre><code>http://localhost:8000/userItems/3
  </code></pre>
  
  <p><strong>Any ideas on how to make the item_id(26) disappear from the route?</strong></p>