weDevsOfficial / wp-recaptcha-integration

WordPress reCaptcha integration supporting Ninja Forms and Contact Form 7
https://wordpress.org/plugins/wp-recaptcha-integration
50 stars 31 forks source link

PHP Fatal error: Call to undefined function ninja_forms_register_field() #73

Closed tidl closed 7 years ago

tidl commented 8 years ago

PHP Fatal error: Call to undefined function ninja_forms_register_field() plugins/wp-recaptcha-integration/inc/class-wp_recaptcha_ninjaforms.php on line 97

please fix this with: if ( function_exists( 'ninja_forms_register_field' ) ) { ninja_forms_register_field( '_recaptcha', $args ); }

(Not that good yet with GitHub to fork it right) Tonny

alexstine commented 7 years ago

Hello @tidl

I'm not the plugin author. That would fix the plugin, but it seems like the hook for adding fields has changed. So it would eliminate the error, but I do not think it would work. Am I correct in saying this?

Thanks.

chapmanio commented 7 years ago

@tech55541 it would appear this is the case. @tidl 's fix works to get the plugin working, and reCaptcha is applied to all forms automatically apart from Ninja forms.

If you're not using Ninja forms that fix will be enough, but for those of us using Ninja forms (myself included!) we'll need a fix for this!