How I can take code from http://domain.com/auth/fb?code=kakakak.
Because $request->input('code') return null and I don't know why.
Thanks
What about using the query() method since the code is part of the query string. For example:
$request->query('code');
See the documentation for more info.
Try the input() method:
echo $request->input('code');
As described in the Docs (In this case Request::input() and $request->input() do the same)
Here's a basic test to see if query parameters are really not working. Add this to routes.php:
Route::get('test', function(){
dd(Request::input('foo'));
});
And access:
http://domain.com/test?foo=bar
You should see "bar" printed on your screen.
$request variable? Can I see a bit more of your code?public function fb(AuthenticateUser $authenticateUser, Request $request) { dd($request->query('code')); //$hasCode = $request->has('code'); // return $authenticateUser->execute($hasCode, $this); }Request. The full path is Illuminate\Http\Request