-
-
Notifications
You must be signed in to change notification settings - Fork 1.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
How Should I Store Image In Jquery Form Builder Because in user data we can't store file,so how i store image,file and show them #1476
Comments
Take a look at this plugin control https://github.com/lucasnetau/formBuilder-plugin-media |
yes i am using this plugin but how to display image when we render form data using userdata method |
That will require a custom control |
can you guide me i am new to this plugin how to add |
can you guide me i am new to this plugin how to add |
Please take a look at the documentation for custom controls. There is also my custom controls example repo https://github.com/lucasnetau/formBuilder-plugins which may guide you. Back of envelope thoughts would be you need to setup both the input[type=file] and likely a hidden input to track the files, and a div to render the images in build() and then in onRender you need to setup your control. You'll need a handler to upload the files to your server and then store a returned filename, then setup the img elements from userData |
can you give any example so i can implement from that because for me is going bit complicated already |
This is very similar to the request in lucasnetau/formBuilder-plugin-media#1 If you need this, and cannot work it out from the examples I've already provided, I'm open to sponsorship to build the custom control, it would then be available to the community. |
Please don't paste images of code, console etc. use the markdown features of GitHub to highlight the text. It is very hard to read and process code from images. Ok, your issue. From memory you cannot dynamically set the src attribute of a input[type=file] for security reasons to prevent rogue script uploading files from a known path. |
thanks i will now upload like that |
Description:
How to store file
Environment Details:
using this scripts .
Expected Behavior
mehtod should be given to store file (image)
Actual Behavior
mehtod not be given to store file (image)
Steps to Reproduce
Screenshot - (optional)
The text was updated successfully, but these errors were encountered: