使用英语以外的其他语言设置 recaptcha [英] Setting recaptcha in a different language other than english

查看:43
本文介绍了使用英语以外的其他语言设置 recaptcha的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

是我还是 recaptcha 图像无法翻译成除 EN 以外的其他语言?我有 并且它仍然是英文的.这是故意的吗?

Is it me or is recaptcha images cannot be translated to another language other than EN? I have and it is still in English. Is this intentional?

推荐答案

对于 reCAPTCHA 2. 好久不见

For reCAPTCHA 2. Since a while have passed

这是你的cdn链接 看最后,hl参数

<script src="https://www.google.com/recaptcha/api.js?onload=myCallBack&render=explicit&hl=fr" async defer></script>

这是您在表单中的验证码

<div id="recaptcha1"></div>

这是您的 javascript您也可以在此处指定 lang 代码,我认为其中之一就足够了

var recaptcha1;
var myCallBack = function() {
    //Render the recaptcha1 on the element with ID "recaptcha1"
    recaptcha1 = grecaptcha.render('recaptcha1', {
    'sitekey': '6LdJLws_your site key',
    'lang' : 'fr'
   });};

您可以使用此方法添加多个 reCAPTCHA.

You can add multiple reCAPTCHAs with this method.

这里是完整的语言参考:https://developers.google.com/recaptcha/docs/language?hl=en

Here is full language reference: https://developers.google.com/recaptcha/docs/language?hl=en

这篇关于使用英语以外的其他语言设置 recaptcha的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆