title: Passing Parameters from one view to another Laravel
body: <p>I'm new with Laravel and there are some concepts that I don't understand very well. I really need your help on this because I've read many many pages, tutorials and stackoverflow solutions and I dont get the results that I need.
  I have a list of "patients" shown on a index page from a database.
  Here is the code:</p>
  
  <pre><code> @if($data)
      &lt;table class="table"&gt;
      &lt;thead&gt;
      &lt;tr&gt;
          &lt;td&gt;Nombre de Paciente&lt;/td&gt;
          &lt;td&gt;Cedula&lt;/td&gt;
          &lt;td&gt;Fecha&lt;/td&gt;
          &lt;td&gt;Telefono&lt;/td&gt;
          &lt;td&gt;Email&lt;/td&gt;
          &lt;td&gt;Direccion&lt;/td&gt;
          &lt;td&gt;Fecha de Creación&lt;/td&gt;
          &lt;td&gt;&lt;/td&gt;
          &lt;/tr&gt;
          &lt;/thead&gt;
          &lt;tbody&gt;
          @foreach($data as $row)
          &lt;tr&gt;
          &lt;td&gt;
          &lt;a href="{{url('/care/$row-&gt;id')}}"&gt; {{ $row-&gt;paciente }}&lt;/a&gt;&lt;/td&gt;
              &lt;!--&lt;td&gt;{{ $row-&gt;paciente }}&lt;/td&gt;--&gt;
              &lt;td&gt;{{ $row-&gt;cedula }}&lt;/td&gt;
              &lt;td&gt;{{ $row-&gt;fecha_nacimiento }}&lt;/td&gt;
               &lt;td&gt;{{ $row-&gt;telefono }}&lt;/td&gt;
              &lt;td&gt;{{ $row-&gt;email }}&lt;/td&gt;
              &lt;td&gt;{{ $row-&gt;direccion }}&lt;/td&gt;
              &lt;td&gt;{{ $row-&gt;created_at }}&lt;/td&gt;
              &lt;td&gt;
  
              &lt;/td&gt;
          &lt;/tr&gt;
          &lt;/tbody&gt;
          @endforeach
      &lt;/table&gt;
      @endif
  </code></pre>
  
  <p>What I want to do, and as you can see, the "patient" name is a link, which referese to (in this case)a form.
  I want to get two things from this. 
  ONE: I want to get the id of the patient I'm clicking on and the name of the "patient" and send it to the form page.
  TWO: on the form page I want to show the "patient" name on the top of the form, and have the "patient_id" hidden to save it on the form table (this patient_id will be a foreing key)</p>
  
  <p>This are my current components:</p>
  
  <p>ROUTE:</p>
  
  <pre><code>Route::get('/care/{id}', [
  'as' =&gt; 'create',
  'uses' =&gt; 'CareController@create' ]);
  </code></pre>
  
  <p>CONTROLLER</p>
  
  <pre><code> public function create($id)
  {
      //
  
      return view ($this-&gt;path.'.care',['id'=&gt;$id]);
  }
  </code></pre>
  
  <p>VIEW:</p>
  
  <pre><code>    &lt;div class="form-group"&gt;
  
      &lt;label for="exampleInputEmail"&gt;Paciente &lt;/label&gt;
    &lt;input type="hidden" name="id" value="{{$id}}"&gt;
  
    &lt;/div&gt;
  </code></pre>
  
  <p>But whenever I load the page, it shows a blank page and on the url I see the following:</p>
  
  <p><a href="http://hospital.dev/care/" rel="nofollow noreferrer">http://hospital.dev/care/</a>$row->id</p>
  
  <p>I really appreciate your help with this.</p>
  
  <p>UPDATE:
  THANKS.
  Its sending now the id. But when trying to display the form page, it still sends the blank page, and the url is the following:
  "<a href="http://hospital.dev/care/1" rel="nofollow noreferrer">http://hospital.dev/care/1</a>" </p>
  
  <p>I dont know if it is something on the controller:</p>
  
  <p>CONTROLLER:
   public function create($id)
      {
          //</p>
  
  <pre><code>    return view ($this-&gt;path.'.care',['id'=&gt;$id ]);
  }
  </code></pre>
  
  <p>how should I pass the id value no to the url but to the view?</p>