vendredi 2 septembre 2016

laravel 5.3 old input values always empty

see docs here about old input

Route::post('/search/all/', function (Request $request) {

 //...

  $products = $query->paginate(15);
  $data = ['products' => $products,
  'oldinput' => $request->all()];


  return view('inventory.search_products', $data);
});

in the view:

this works:

<input type="text"  id="search_all" name="search_all" value="">

this is always empty:

<input type="text"  id="search_all" name="search_all"  value="">



via Chebli Mohamed

Aucun commentaire:

Enregistrer un commentaire