Comments (14)
The problem also occurs when downgrading the plugin to v3.0.0.
from formbuilder-plugin-public.
Changing the registerPageSnippets()
method inside Plugin.php
to use an absolute class name seems to fix the problem:
public function registerPageSnippets()
{
return [
\Renatio\FormBuilder\Components\RenderForm::class => 'renderForm',
];
}
from formbuilder-plugin-public.
Hi,
I checked this and it seems to work find with example Contact Form.
October v3.4.15
Plugin v3.1.2
Pages plugin: v1.5.12
Hmm the most weird thing is that the change you made to make it work does not make any sense.
If you:
dd(
[\Renatio\FormBuilder\Components\RenderForm::class => 'renderForm'],
[RenderForm::class => 'renderForm'],
);
This is exactly the same, because first one use fully qualified name and the second shortcut with use import.
from formbuilder-plugin-public.
OK, very weird. I undid the qualified name and it still works. So that was a false flag. Sorry, about that.
However, I noticed that when I edit the componentDetails()
method inside RenderForm.php
as below, the snippet code that is inserted in a static page changes to include <figure data-ajax=\"true\" ...
and the snippet starts working.
public function componentDetails()
{
return [
'name' => 'renatio.formbuilder::lang.render_form.name',
'description' => 'renatio.formbuilder::lang.render_form.description',
'snippetAjax' => true
];
}
Could it be that the data-ajax
is needed? (See https://docs.octobercms.com/3.x/cms/themes/snippets.html#creating-snippets-from-components)
from formbuilder-plugin-public.
Hi,
yes that is probably the issue here. This is a new feature of October, so I did not add it yet. Thanks for reporting this.
I published v3.1.3 where this is added.
Thanks for reporting this and help resolving this.
from formbuilder-plugin-public.
Same problem here FormBuilder 4.0.2, octobercms 3.5.4 (also 3.5.x)
"AJAX handler 'renderForm::onSubmit' was not found"
from formbuilder-plugin-public.
Hi @xmerlin,
please write me steps to reproduce this issue.
from formbuilder-plugin-public.
added {% styles %} in head
added {% framework extras %} and {% scripts %} above script includes in the footer
added standard "Contact Form" in the homepage
"AJAX handler 'renderForm::onSubmit' was not found." when I press send
from formbuilder-plugin-public.
Please copy your homepage and layout file source code. Just the minimum with the form and essential code.
from formbuilder-plugin-public.
layout
<link href="https://fonts.googleapis.com/css?family=Lato:300,400,400i,700|Poppins:300,400,500,600,700|PT+Serif:400,400i&display=swap" rel="stylesheet" type="text/css" />
<link rel="stylesheet" href="{{ [
....
]|theme }}" type="text/css" />
{% styles %}
...
<div id="wrapper" class="clearfix">
{% partial "header" %}
{% page %}
{% partial "footer" %}
</div>
<div id="gotoTop" class="icon-angle-up"></div>
<script src="{{ [
'assets/js/jquery.js',
'assets/js/plugins.min.js',
'assets/js/functions.js'
]|theme}}"></script>
{% framework extras %}
{% scripts %}
concact-form partial
Send us an Email
<div class="contact-widget">
<div class="contact-form-result"></div>
{% component "renderForm"%}
</div>
</div>
</div>
from formbuilder-plugin-public.
I assume that you use partial and put form component inside it.
Maybe this is the isssue: https://talk.octobercms.com/t/ajax-handler-in-php-section-of-partial/1009
https://docs.octobercms.com/3.x/markup/tag/ajax-partial.html
So instead of use {% partial 'contact-form' %} try to use {% ajaxPartial 'contact-form' %}
from formbuilder-plugin-public.
{% ajaxPartial 'contact-form' %} fixed the issue ...now I have to find why there is no message in the form log and/or in mailbox
from formbuilder-plugin-public.
I would check mail settings first. Go to Settings -> Mail Templates and click any mail template. There is a Sent test message button below. If you receive test message, then check Event Logs for any errors.
In form update page there is Options tab, where is setting to disable form logs. Check if it is not disabled.
Also to receive mail message the Mail Template field must not be empty.
from formbuilder-plugin-public.
Mail Template field empty ...now it works as expected, thank you
from formbuilder-plugin-public.
Related Issues (20)
- A 2nd FormLog is created when SendEmailMessage::sendAutoresponderMessage() is called HOT 2
- Form submit 500 error HOT 1
- Multi Page Forms
- Use HTML inside label in checkbox HOT 4
- Unable to submit the form HOT 8
- FileUploader onRun Does Not Run, Does Not Inject Assets HOT 8
- The field type field is required HOT 1
- Remove Uploader Dependency / Use native October AJAX Framework HOT 1
- Export single form HOT 3
- Fil upload filed issue HOT 21
- resetForm function does not fire HOT 2
- Cannot update from v3.1.x to v4.0.x HOT 2
- Problem with new events (fixed) HOT 4
- Can we support Tailwind? HOT 1
- Hidden field with page title or slug, url HOT 2
- could not make your forms plugin for HOT 1
- Send from to specific e-mail, according to dropdown select box HOT 4
- Use options value in mail templates for checkboxes HOT 4
- File upload file being attached to wrong form log HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from formbuilder-plugin-public.