react-native-recaptcha
react-native-recaptcha copied to clipboard
Redirected to my site
Hello, I tried using it but when my app loads it opens a tab in my browser pointing to the domain I set for siteKey
and exiting the app of course. Not sure what am I doing wrong.
Hello!
siteKey
is supposed to be the key available on your google admin console. Could you try setting the url
prop to the domain (also the one you're being redirected to) that is associated to that siteKey
?
I did, url is pointing to my domain. Whenever the app loads, it takes me out of the app and loads the domain in a browser tab.
I'm seeing this as well. why is this library sending you to the url when ReCaptcha is used?
Hello! Could one of you ( @polpenaloza , @Losapioj ) please post a screenshot or an example of how you're using the ReCaptcha component? I'm having trouble reproducing this.
Thanks,
Hello!
Same issue is happening to me
<ReCaptcha
url={Config.API_URL}
siteKey={Config.RECAPTCHA_SITE_KEY}
action="verify"
/>
this is how I use the component with API_URL being the string to my api "http://....."
and site key the key given by google admin console
when the captcha is loading, it just opens a browser and redirect to the url
I don't know if this happens to me or not - I get a white screen when I include the Recaptcha. May be because the domain is not a live domain but a local one which is not hosted on my device so it's unable to load it.
@lapwil
Hello!
Same issue is happening to me
<ReCaptcha url={Config.API_URL} siteKey={Config.RECAPTCHA_SITE_KEY} action="verify" />
this is how I use the component with API_URL being the string to my api
"http://....."
and site key the key given by google admin consolewhen the captcha is loading, it just opens a browser and redirect to the url
I'm also seeing this issue now. As a temporary workaround, I appended "/" at the end of the the API_URL to prevent the redirect. I'll look into releasing an actual fix for this soon. Feel free to let me know if that workaround doesn't work for you.
<ReCaptcha containerStyle={{height: 200, width: '100%', marginTop: 'auto', borderWidth: 1,}} siteKey="Site_Key" url='Domain_From_Admin_Console' action='verify' onReady={this.onReady.bind(this)} onExecute={this.captureResponseToken.bind(this)} />
Any thoughts on how can i fix this ??
@sarangvasishth Try to add to your url parameter "http://"
Use this library
https://www.npmjs.com/package/react-native-secure-captcha-v3