• Resolved Florian Simeth

    (@floriansimeth)


    Hey there,

    Thanks for this wonderful plugin! I do not have a support request but a suggestion for improvement.

    On one of my client’s sites we were unable to use the plugin because it gave connection-failed and hostname-mismatch errors. A bit of debugging then provided the answer. By default, the plugin uses the file_get_contents function to retrieve the appropriate ReCaptcha URL and then validate it. Unfortunately, sometimes the PHP flag allow_url_fopen is set to false, causing file_get_contents() to fail.

    It would be great if you could add a checkbox in the settings to allow the user to switch to CURL. All you would have to do is change line 206 in inc/core.php from

    $captcha_obj = new \ReCaptcha\ReCaptcha( $secret_key );

    to

    $captcha_obj = new \ReCaptcha\ReCaptcha( $secret_key, new \ReCaptcha\RequestMethod\CurlPost() );

    Thank you!

Viewing 1 replies (of 1 total)
  • Plugin Author WebFactory

    (@webfactory)

    Hi,
    Sorry for the delayed response.

    You’re right. Will include that fix in the next release ??

Viewing 1 replies (of 1 total)
  • The topic ‘Verbesserungsvorschlag: Allow CURL connections’ is closed to new replies.