hi @ethanchoi
Problems solved now. I checked it out by installing fresh WP with no plugins and no options with only WPForms, turns out, this is the problem:
WPForm requires reCaptcha to be called with query string like this:
<script type='text/javascript' src='https://www.google.com/recaptcha/api.js?onload=wpformsRecaptchaLoad&render=explicit&ver=2.0.0'></script>
While I have custom function to remove query string from static resources, and the result was this:
<script type='text/javascript' src='https://www.google.com/recaptcha/api.js'></script>
So now I made expection for the recaptcha/api.js
and everything works fine now. ??
Thanks a lot for your support! ??
FYI, this is my function:
function cleanup_query_string( $src ){
if ( stristr( $src, "google.com/recaptcha/api.js" ) ) {
return $src;
} else {
$parts = explode( '?', $src );
return $parts[0];
};
}
add_filter( 'script_loader_src', 'cleanup_query_string', 15, 1 );
-
This reply was modified 5 years, 6 months ago by V.E.L.