New Google reCaptcha: How to change text “I'm not a robot”

前端 未结 6 2095
甜味超标
甜味超标 2021-02-05 08:32

I\'ve installed the latest Google reCaptcha tool on our yoga website. Now the users are confused about the text \"I\'m not a robot\" that appears next to the checkbox.

M

6条回答
  •  清酒与你
    2021-02-05 09:10

    You cannot change that specific text because it belongs to a third party iframe, though there is a workaround that fulfils exactly what the OP is asking for.

    You can append a new div on the parent div you can control, aligning and overlapping it on the label text, considering the Google Captcha has always a fixed size. Therefore, according to documentation, considering you may have the main Captcha div on your code with class="g-recaptcha", you simply do:

    $('.g-recaptcha').append('
    '); $('#new_label').text("My own text"); $('#new_label').css({"position":"absolute", "width":"160px", "top":"27px", "left":"53px", "background-color":"#f9f9f9"});

    it works :)

提交回复
热议问题