How to select different registers in a table in a view in laravel?
Here´s the thing. I have a view to show different students in a table. I`d like to select some of them, and send that to a method in my controller. Here is my table in the view:
I´d like to select some of the registers, store them in and array or something like that and send that array to a method in my controller, but I dont know how to select various rows and send them. Thank you.
@lrf002 just as an aside; you are overwriting the main $student variable value in the loop; you might want to consider a different variable for the loop item, e.g.
<h1>Añade amigos de {{$student->name}}</h1>
<!-- ... -->
@foreach($students as $otherStudent)