Using reCAPTCHA on localhost with a fake development domain

时间:2015-09-01 21:19:24

标签: recaptcha

I'm currently using a fake development domain instead of localhost on my local machine, as I have multiple websites that I want to manage locally.

Google reCAPTCHA is not recognising my domains, and is giving me this error: ERROR: Invalid domain for site key

What can I do to solve this?

1 个答案:

答案 0 :(得分:6)

您需要将虚假域名添加为reCAPTCHA白名单中的条目。对于您正在使用的当前reCAPTCHA,可以在reCAPTCHA admin panel中找到。

例如,如果您的虚假开发域名为mysite.myfakedomain,则可以将mysite.myfakedomain添加到白名单。

注意:更改可能需要几分钟时间。