sumitani
0
Q:

When you click on the search button, it is moved to the page laravel

Route::get('/profile/{Profile}', 'PlayerController@getStats');
0
public function searchForm() {
    return view('search');
}

public function search(Request $request) {
    // get the input
    $inputText = ...;
    // logic to get the profile name
    $profileName = ...;
    return redirect('/profile/'.$profileName);
}
0
Route::get('/profile/{Profile}', 'PlayerController@getStats');
Route::get('/search', 'PlayerController@searchForm');
Route::post('/search', 'PlayerController@search');
0

New to Communities?

Join the community