react-native-recaptcha icon indicating copy to clipboard operation
react-native-recaptcha copied to clipboard

Redirected to my site

Open polpenaloza opened this issue 6 years ago • 10 comments

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.

polpenaloza avatar Sep 01 '18 00:09 polpenaloza

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?

acsant avatar Sep 03 '18 04:09 acsant

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.

polpenaloza avatar Sep 03 '18 23:09 polpenaloza

I'm seeing this as well. why is this library sending you to the url when ReCaptcha is used?

Losapioj avatar Sep 13 '18 20:09 Losapioj

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,

acsant avatar Sep 18 '18 03:09 acsant

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

lapwil avatar Dec 05 '18 17:12 lapwil

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.

Tencryn avatar Dec 09 '18 23:12 Tencryn

@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 console

when 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.

acsant avatar Dec 29 '18 19:12 acsant

<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 ?? screenshot_20190307-063223_phoneauth

sarangvasishth avatar Mar 07 '19 01:03 sarangvasishth

@sarangvasishth Try to add to your url parameter "http://"

sfemat avatar Jul 06 '19 22:07 sfemat

Use this library

https://www.npmjs.com/package/react-native-secure-captcha-v3

amitmehtacode avatar May 09 '24 19:05 amitmehtacode