I am new to Laravel, there is a get request to following url:
but i am getting : 404 Bad Request in my console, and the control goes in the fail block. Please help to sort out my issue.
layout.blade.php
body.on('loggedIn:fb', function(){
if(!User.isLoggedIn()) {
$.get(BASE_PATH + '/login/fb').success(function(response){
User.setData(response.user);
}).fail(function(jqXHR, textStatus, errorThrown){
body.trigger('social-login:error', jqXHR.responseText);
}).always(function(){
loginModal.removeClass("logging-in");
});
}
});
routes/web.php
Route::get('/login/fb', array('as' => 'loginWithFb', 'uses' => 'UserController@loginWithFb'));