dpapathanasiou / go-recaptcha Goto Github PK
View Code? Open in Web Editor NEWA package for handling reCaptcha (http://www.google.com/recaptcha) form submissions in Go (http://golang.org/).
License: MIT License
A package for handling reCaptcha (http://www.google.com/recaptcha) form submissions in Go (http://golang.org/).
License: MIT License
I think it will be nice to have the check function public. Because checking succcess is not enough and sometimes you need read error-codes, action and especially score for detailed validation.
so.. just merge pull request #13 please.
This is my first time using recaptcha, and it is said that the remote-ip parameter is optional, could you fix it?
https://github.com/dpapathanasiou/go-recaptcha/blob/master/recaptcha.go#L33. If you don't return after errors in this function you're going to have a bad day.
Hello,
It would be great if go-recaptcha had godocs that showed the available structs and options. Some documentation would help determine what types to use, for instance.
Thanks for considering!
Was trying out this recaptcha library but got into some errors that needed troubleshooting.
Read error: got invalid JSON: json: cannot unmarshal string into Go struct field
RecaptchaResponse.error-codes of type int
According to reCAPTCHA documentation on Verifying the user's response, error-codes
are now a list of strings.
Changing RecaptchaResponse should avoid the error.
type RecaptchaResponse struct {
Success bool `json:"success"`
ChallengeTS time.Time `json:"challenge_ts"`
Hostname string `json:"hostname"`
ErrorCodes []string `json:"error-codes"`
}
Thought this information might be helpful :)
.../vendor/github.com/dpapathanasiou/go-recaptcha/recaptcha.go recaptcha.go:42: possible formatting directive in Println call recaptcha.go:46: possible formatting directive in Println call exit status 1
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.