Tweet, Share & Like [ EnAcCiOn ]

 

FeedBurner FeedCount Y Facebook | EnAcCiOn

Send Voicemail | EnAcCiOn

Contact me using vCita | EnAcCiOn

Contact me using vCita | EnAcCiOn

Meeting Scheduler Powered by vCita

martes, 12 de mayo de 2015

Angular + reCaptcha

For those of you using Angular and reCaptcha, you've probably run into the bug where reCaptcha does not destroy itself when the element it is bound do gets destroyed. This is especially annoying on a route change. A fairly effective fix is to add the following function to the grecaptcha object once it has been loaded:window.grecaptcha.getLatestResponse = function () {    return window.grecaptcha.getResponse(window.___grecaptcha_cfg.count - 1);};Obviously there are some caveats (only one captcha per page, etc.), and I'm sure it won't work in every situation. But if you only have one captcha per page in your one page app, this is an easy work around. -- You received this message because you are subscribed to the Google Groups "reCAPTCHA" group. To unsubscribe from this group and stop receiving emails from it, send an email to recaptcha+unsubscribe@googlegroups.com. To post to this group, send email to recaptcha@googlegroups.com. Visit this group at http://bit.ly/1dkFnYd. For more options, visit http://bit.ly/P65DvS.

No hay comentarios:

EnAcCiOn

Contador Web | EnAcCiOn

EnAcCiOn

EnAcCiOn

EnAcCiOn

Blog Archive | EnAcCiOn