21 velj.

Contact Form 7 spam

Plugin koji štiti bez captcha:

Contact Form 7 Honeypot

Google reCAPTCHA

reCAPTCHA

https://www.google.com/recaptcha

Savjeti sa foruma:

https://stackoverflow.com/questions/16278241/wordpress-contact-form-7-spam-messages

Prevođenje teksta u reCAPTCHA

Change the language of reCAPTCHA in Contact Form 7

Ovo je kod koji se dodaje u functions.php u folderu teme da bi tekst bio na hrvatskom

add_action( 'wpcf7_enqueue_scripts', 'custom_recaptcha_enqueue_scripts', 11 );

function custom_recaptcha_enqueue_scripts() {
	wp_deregister_script( 'google-recaptcha' );

	$url = 'https://www.google.com/recaptcha/api.js';
	$url = add_query_arg( array(
		'onload' => 'recaptchaCallback',
		'render' => 'explicit',
	 	'hl' => 'hr' ), $url );

	wp_register_script( 'google-recaptcha', $url, array(), '2.0', true );
}