I digged a little bit into the code.
This is how the hidden field looks like in the rendered html on the frontend:
<input type="hidden" id="hidden-1" name="hidden-1" value="https://www.some-example-page.com/contact-form">
The error is thrown in front.multi.min.js:13214
//same tab redirection
window.location.href = self.decodeHtmlEntity(data.data.url);
Where data.data.url looks like:
url: "http://https%3A%2F%2Fwww.some-sample-page.de%2contact-form%2"
So it seems that somewhere an additional http:// is added which leads to a malformed URL.
-
This reply was modified 3 years, 10 months ago by
justsomeone.
-
This reply was modified 3 years, 10 months ago by
justsomeone.
-
This reply was modified 3 years, 10 months ago by
justsomeone.
Hi @justsomeone
I hope you’re well today and thank you for reporting this!
You are right and there is an unexpected bug in recent release that’s breaking such redirects. Our Forminator Team is already aware of it and are working on a fix.
I believe it will be fixed soon but I don’t have ETA yet (as it’s a “fresh discovery”).
Downgrade to the previous version of the plugin would be a workaround for now until the fix is released.
Kind regards,
Adam
Hi @justsomeone
I just came to know that we do have a workaround that could be used for now. It’s a bit of custom code that you can add to the site:
1. create an empty file with a .php extensions (e.g. “forminator-redirect-fix.php”)
2. copy and paste following code into it:
<?php
add_filter( 'forminator_form_submit_response', 'wpmudev_fix_redirection_submission', 20, 2 );
add_filter( 'forminator_form_ajax_submit_response', 'wpmudev_fix_redirection_submission', 20, 2 );
function wpmudev_fix_redirection_submission( $response, $form_id ){
if( $form_id != 361 ){ //Please change the form ID
return $response;
}
if( $response['behav'] == 'behaviour-redirect' ){
$response['url'] = preg_replace("(^https?://)", "", $response['url'] );
$response['url'] = rawurldecode($response['url']);
}
return $response;
}
3. in this line
if( $form_id != 361 ){
replace the 361 number with an ID of your form; the ID is the number which you can see in form’s shortcode
4. save the file and upload it to the “/wp-content/mu-plugins” folder of your site’s WordPress installation using FTP, cPanel “File Manager” or similar way.
It should work out of the box.
Kind regards,
Adam
Hello @justsomeone ,
We haven’t heard from you for a while now, so it looks like you don’t need our assistance anymore.
Feel free to re-open this ticket if needed.
Kind regards
Kasia
Hi @wpmudev-support2 , @wpmudev-support8
the issue still exists in the latest 1.18.2 version.
I don’t want to apply a workaround. Could you please fix the issue?
Best
Robert
Hi @justsomeone,
Mentioned bug is in the backlog of our Forminator team and it will be fixed on the upcoming versions. We are providing workarounds to our users to resolve their issues until the fix is being released since we don’t have any ETA for it.
Thank you for your understanding.
Kind regards,
Zafer