Comments (8)
Hmm it is called on my test project. I checked form inside CMS Page, Static Page (component snippet).
Did you install responsiv/uploader-plugin
using composer?
Please explain how do you use form and where do you put it.
from formbuilder-plugin-public.
I installed the uploader plugin through the October CMS project / the backend.
The form is embedded into a static page (variable, not the content field) via a snippet: <figure data-ajax="true" data-component="Renatio\FormBuilder\Components\RenderForm" data-property-formcode="some-form" data-snippet="renderForm"> </figure>
from formbuilder-plugin-public.
I don't understand the part (variable, not the content field). Can you elaborate on this?
I have a static page and I clicked on the Snippets menu on the top bar then choose Render Form Component. I clicked on the snippet and choosed the form.
The second form I added using richeditor Insert Snippet button.
The result on the static page source code:
<figure data-ajax="true" data-component="Renatio\FormBuilder\Components\RenderForm" data-property-formcode="default-form" data-snippet="renderForm"> </figure>
<figure data-component="Renatio\FormBuilder\Components\RenderForm" data-property-formcode="contact-form-2" data-snippet="renderForm1"> </figure>
Both forms work fine (image upload and file upload works). Hmm they even work when I remove this data-ajax="true"
attribute, which is weird.
from formbuilder-plugin-public.
By variable I mean that the static page does not use the default content field, but a custom repeater. The snippet is inserted in that rich editor, not in the default content field.
layout.htm
[staticPage]
useContent = 0
==
{repeater name="sections" groups="themes/some-theme/meta/generic-repeaters.yaml" tab="Content" prompt="Add a section"}
{# parser fail if there is noting between open and close tag #}
{/repeater}
generic-repeaters.yaml
text:
name: Text
titleFrom: title
description: Text
icon: icon-newspaper-o
fields:
title:
label: Title
type: text
span: full
content:
label: Content
type: richeditor
span: full
from formbuilder-plugin-public.
Hi,
I managed to replicate this issue. As I can see it, the onRun methods of formbuilder plugin as well of fileupload plugin are running, but the assets are not injected. Maybe it is too late in the process of serving page. Maybe this is a bug of October, so they can help with this issue.
I tried to solve this by adding missing assets manually with onStart() function. This works, but another problem is the fileupload component is not bound to controller and ajax handler onUpload() is missing when you try to add file using the form. This also can be an issue how October handle this type of snippets.
If you have time please report this to October team, maybe they will figure this out.
from formbuilder-plugin-public.
OK, good to know that is not only isolated to my test system. Unfortunately, I am not 100% what to report to the October team. I have tried playing with the code, but haven't really come to any conclusion.
As of now; I believe that it might be best to remove the Uploader dependency entirely, since October's AJAX framework apparently supports uploads in v3. (See responsiv/uploader-plugin#77 and https://docs.octobercms.com/3.x/cms/features/uploads.html) No need for nested components, it removes three JS dependencies and it could potentially be much cleaner.) Happy to open another ticket for this.
from formbuilder-plugin-public.
Yeah I agree, that would be the best way to proceed this. I will try my best to add this feature next week.
from formbuilder-plugin-public.
As discussed I added ajax file uploads in v4.0, so this should be fixed.
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
- Snippet Form cannot find AJAX Handler 'renderForm::onSubmit' HOT 14
- 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.