V. 2.8.0 - 404 on mautic-form.js

I am getting a 404/not found for mautic-form.js on a Wordpress contact page where a Mautic form is embedded via a standard [mauticform id=“4”] shortcode.



The page is this one: http://www.eserciziodiavvocatura.it/sampleone/



The not found is due to a wrong construction of the link to mautic-form.js as follows:

Code:
http://www.eserciziodiavvocatura.it/m/m/media/js/mautic-form.js

as you can see the /m part is inserted twice.

Mautic base dir is
Code:
http://www.eserciziodiavvocatura.it/m


I also checked the "manual copy" option to embed the form into the web pages, and again the issue shows up:
Code:

I have been trying to look for a solution for many hours now, with no luck. So I am posting this issue here hoping that someone has already solved this matter.

Any help would be really appreciated.

Thank you

I am getting a 404/not found for mautic-form.js on a Wordpress contact page where a Mautic form is embedded via a standard [mauticform id=“4”] shortcode.

The page is this one: http://www.eserciziodiavvocatura.it/sampleone/

The not found is due to a wrong construction of the link to mautic-form.js as follows:

http://www.eserciziodiavvocatura.it/m/m/media/js/mautic-form.js

as you can see the /m part is inserted twice.

Mautic base dir is

http://www.eserciziodiavvocatura.it/m

I also checked the “manual copy” option to embed the form into the web pages, and again the issue shows up:

[code]
[/code]

I have been trying to look for a solution for many hours now, with no luck. So I am posting this issue here hoping that someone has already solved this matter.

Any help would be really appreciated.

Thank you

@MxyzptlkFishStix, thank you. Your solution partially resolved.

Following your suggestion the 404 issue is now resolved, thank you for that.

Unfortunately now my form posts the data but the button gets stuck on “Please wait” [which is “si prega di attendere”] in Italian.

The behaviour is the same both if I create a brand new form and also if I change the form behaviour once submitted (redirect, display message or remain at form).

Would you please so kind to have a look at the page again? I would really appreciate that, as I am keen to stick with Mautic.

Thank you
Giovanni

@MxyzptlkFishStix
Thank you for your support - your solution to the first issue was correct.

Still the “please wait” hang is not resolved even after rebuilding cache. This issue is quite difficult to debug - at least for me.

Thank you

I’m giving an update on this case so that this may be useful to someone in future.

My first issue was related to a 404/not found for mautic-form.js on a Wordpress contact page where a Mautic form is embedded via a standard [mauticform id=“4”] shortcode.

This was due to a misconfiguration on my mautic / configure panel where, under “site Url” I wrongly inputed my Matic installation folder, instead of the plain website domain where my Mautic instance was installed.

So, if you, like me, have installed your Mautic instance in your website subdirectory, under the Mautic/Configuration/siteUrl just indicate your site url, e.g. www.yourdomain.com.

This was indicated to me by @MxyzptlkFishStix so all credit and praise should go to him.

After resolving that issue, I had the very annoying issue of my Mautic form hanging on the “please wait” status, instead of proceeding to the scheduled action (e.g. show message, redirect, remain on form).
I tried a different set of solutions posted on the internet (this issue seems pretty common) and what resolved for me was to uninstall the “WP Mautic” plugin which I had installed on my Worpress instance vers. 4.7.4 via the Worpress Plugin repository, and downloaded and installed the one found on Github: https://github.com/mautic/mautic-wordpress

One obvious difference between the 2 versions of the “WP Mautic Plugin” is the embedding shortcode.

The embedding shortcode of the “WP Mautic” plugin downloaded from the Wordpress plugin repository was:

[mauticform id="2"]

The one for the “Wp Mautic” plugin downloaded from Github is

[mautic type="form" id="2"]

The above does not make a lot of sense to me, but still this is what has been working on my use case.

I hope this will be useful for someone else in future.

Thank you for reading and special thanks to @MxyzptlkFishStix

A word of warning to people trying this, when I tried the same thing to fix missing images in the email builder, it broke all the links in the email (Which use the site url field in the configuration, which now doesn’t contain the folder mautic is installed to).

There is some work in progress on github here: https://github.com/mautic/mautic/pull/4148