Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Getting an error when trying to register and login #3

Open
fusionx1 opened this issue Jun 27, 2015 · 4 comments
Open

Getting an error when trying to register and login #3

fusionx1 opened this issue Jun 27, 2015 · 4 comments

Comments

@fusionx1
Copy link

Hi Kevin thanks for sharing your apps. This is really awesome, it triggers my appreciation for ionic.
I just wanna share this error i got when trying to configure my own endpoint url. I attached here a screenshot, i hope you can help me with it. I also would like to contribute to this project.

screen shot 2015-06-28 at 1 07 40 am

Thanks,

Paul de Paula

@fusionx1
Copy link
Author

i have checked the error on drupal side and i saw this:

screen shot 2015-06-28 at 1 25 11 am

It seems that it sends an undefined data which supposed to be a username and password.

@UnbekanntesPferd
Copy link

Same problem here.
Try this:
In login.html, line 9, change doLogin() to doLogin(username, password)
In controllers.js, line 37, change
$scope.doLogin = function() {
to
$scope.doLogin = function(username, password) {
and line 43 change
Account.login($scope.username, $scope.password).then(function(data){
to
Account.login(username, password).then(function(data){

@martinjbaker
Copy link

If Drupal Services is set to use the v1.1 API, then you'll also need to change line 35 of services.js to

data          : 'name=' + encodeURIComponent(username) + '&pass=' + encodeURIComponent(password),

also the username and password should be url encoded.

@ghost
Copy link

ghost commented Apr 9, 2016

Hello after the above correction, I managed to login to the site but the register process still fails. Can you please help?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants