-
Hello,
Wonderful plugin you’ve got there.
I’ve removed the category base for my WooComemerce starter site.I’m using the Contact Form 7 plugin + Google reCaptcha.
With the help of this code, Google reCaptcha is stopped from running on every page except the contact page.
add_action('wp_print_scripts', function () { global $post; if ( is_a( $post, 'WP_Post' ) && !has_shortcode( $post->post_content, 'contact-form-7') ) { wp_dequeue_script( 'google-recaptcha' ); wp_dequeue_script( 'wpcf7-recaptcha' ); } });
However, reCaptcha still runs on all product catagory pages and I think it’s connected with the fact that the category base is removed.
Any idea how to go around this and also stop reCaptcha runnning on product category pages?
Regards!
Viewing 6 replies - 1 through 6 (of 6 total)
Viewing 6 replies - 1 through 6 (of 6 total)
The ticket ‘Google reCaptcha and Category Pages’ is closed to new replies.