I am trying to use satellizer to authorize with a Google account. When I click login, a popup appears showing this:
Invalid parameter
Invalid parameter value for redirect_uri: Missing authority: file://
Request Details:
scope=openid profile email
response_type=code
redirect_uri=file://
display=popup
client_id=xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx.apps.googleusercontent.com
What am I doing wrong?
Update 1: My Source Code
index.html
<script src="lib/satellizer/satellizer.js"></script>
app.js
.config(function($stateProvider, $urlRouterProvider,$authProvider) {
$authProvider.google({
clientId: 'xxxxxxxxxx.apps.googleusercontent.com'
});
$stateProvider
.state('app', {
url: "/app",
abstract: true,
controller: 'AppController'
})
.state('login', {
url: "/login",
templateUrl: "views/login.html",
controller: 'LoginController'
});
$urlRouterProvider.otherwise('/login');
})
and loginController.js
.controller('LoginController', function($scope,$auth) {
$scope.authenticate = function(provider) {
$auth.authenticate(provider);
};
});