I have a route
Route::get('student-search', 'Students@search')
and url on browser
student-search?session=2&name=raj&grade=1§ion=a
But while returning $request
its returning empty . Same thing is working fine on local but not working after trnsferring it to server.
code of search function looks like this
public function search(Request $request){
return $request;
...
and $request returns empty . While same thing is working on localhost.
What you are missing is your server is not passing query parameter in any form of request. If you are using nginx try
location / {
try_files $uri $uri/ /index.php?$args;
}
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With