Forums

Modal event loop loads form from content area

johnoathome 26 Aug, 2015
Hello,

I'm using a number of chronoforms, mostly displayed in the content area, but one is launched in a bootstrap 3 modal.

The form in the modal works as expected, except when it's called on a page which has another form in the content area. In this scenario, the on submit event loop for the modal form loads the form from the content area and further execution of the code associated with the modal form ceases.

So in summary, on an event loop, a Chronoform in a modal loads the form from the content area by default. The obvious solution is to specify the form element to be loaded by the event loop but I can't see any option to do this. The event loop only takes one parameter which is the event to load, not the form.

I'd appreciate any ideas on how to work around this.

John
GreyHead 26 Aug, 2015
Answer
Hi John,

It sounds as though the form in the Modal window is submitting to the wrong URL - that of the form in the content area. I'd suggest that you try hard-coding the Action URL in the form HTML (Render form) action. Please see this FAQ for more on this.

Bob
johnoathome 26 Aug, 2015
Hi Bob,

Just setting 'Relative URL' to 'No' in the HTML render page solved the problem! This has made me realise I've still got a bit to learn about some of the features of Chronoforms.

Brilliant though Bob, thanks for getting back so quickly.

Regards
John
This topic is locked and no more replies can be posted.