Forums

ChronoForms Ajax Submit with Gantry

fsiedler 05 Apr, 2020
Hello,

i use gantry with joomla and want to build a contact form with ajax submit to send a mail. The contact form i show via a module. When i submit the form, the mail is sent, but the confirmation message is not showing up. Also redirecting is not working ... After some research i found out, that when i switch to a standard joomla template, everything works fine. This is why, the ajax request on the standard template is returning the message and response data. When i switch to a default gantry template, the ajax response is always empty.
Can someone help me?
GreyHead 06 Apr, 2020
Hi fsiedler,

Do you see any JavaScript errors in your browser Web Developer console when you use the Gantry template?

Bob
fsiedler 06 Apr, 2020
Hi Bob,

no, there is no JavaScript Error. The ajax request after submit (http://localhost/joomla/?chronoform=test2&event=submit&tvout=view&load-form[counter]=0&_counter=0) returns status 200 without any content and that´s the reason, why no success message is shown ... When i change the theme to joomla standard, the ajax request is the same and returns status 200, but with return data like that:
<div class="ui message g2-message error"><ul class="list header"><li>Recipients list is empty</li>
<li>Body is empty</li></ul></div><div class="ui message success">We have received your message, thank you!</div><form action="http://localhost/joomla/?chronoform=test2&event=submit&tvout=view&load-form%5Bcounter%5D=0&_counter=0" method="post" name="submit-form" id="submit-form" data-id="submit-form" class="ui form G2-form G2-dynamic" data-valloc="inlinetext" enctype="multipart/form-data" data-dtask="send/self" data-result="replace/self" data-subanimation="1">
</form>

Do you have any ideas, why with Gantry-Framework the request returns no data?

Flo
GreyHead 08 Apr, 2020
Hi Flo,

Sorry no idea - you might check that Gantry isn't altering any of the form fields, we have seen cases before where the Gantry form templating features interfere with the form display and submission.

Bob
teldrive 04 May, 2021
I had same problems updating older CFv5 to CFv6 and using Gantry template, but also tried with Helix 3 and yoububble and problems remains
I have only issues when using complex ajax -javascript queries based in autocompleter and dropdowns fields updated with events reload
After some research the related cause that generated these issues was the "required" atribute in fields
when disabled this attribute javascript queries started again to work.
Any clues of how allow compatibility of "required" attributes in fields and javascript queries will be welcomed ;-)
This topic is locked and no more replies can be posted.