-
Notifications
You must be signed in to change notification settings - Fork 12
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
Changed req.params.index to req.params.id #2
Conversation
The angularjs frontend sends 'id' as the request parameter instead of 'index'.
I have confirmed on angular, vanilla, and jquery front-end versions. They all send the index, not the id (although the number does match). You can confirm in https://github.com/emotionLoop/visualCaptcha-frontend-core/blob/master/src/visualcaptcha/templates.js#L91 && https://github.com/emotionLoop/visualCaptcha-frontend-core/blob/master/src/visualcaptcha/core.js#L178 && https://github.com/emotionLoop/visualCaptcha-frontend-core/blob/master/src/visualcaptcha/core.js#L78 Even if you were right, this commit does not do anything about it, instead changes the name of the request parameter, which is currently set as Please let me know if you need any explanation or if I'm not understanding this well. |
I deployed visual captcha in sails.js server and the request for route '/image' did not have an index parameter at all and no captcha images were returned (all 404 errors). After looking into the req argument, found that the 'index' is 'id' and after the change, am able to retrieve the images and visual captcha works. I do not know the internals, so I could be wrong in the actual, but the problem I reported is real |
OK, but the issue is not there for simple express. I'll investigate sails
|
If it helps, I have create a github repo with sailsjs: https://github.com/kavuri/sailsjs-visualcaptcha |
I didn't have time to look into this (I also know it's not very urgent since you've fixed it yourself), and I will be traveling this week, so I can only promise I'll look into this before the end of the month and figure out if we need another version for sails or a simple conditional in the code. |
Hello everyone, can someone help me please? In fact, i'm trying to implement visual captcha for sails but i don't really understand the configuration that i have to put on. I tried more than one time but i don't really understand how to add it into my register form . Can someone give me a help please ? Thank you |
Hi @RayanJ973 have you tried looking into @kavuri 's repo? Additionally you should create another issue or send an email to [email protected] if you need to share some more sensitive information (like code or logs). |
The angularjs frontend sends 'id' as the request parameter instead of 'index'.