Comments (4)
@tifabien is there still the need for the symfony form validation? Because its already happening on js side with mimetype and file extension
from sonata-multiupload-bundle.
IIRC symfony will release symfony/mime component soon. Can this help?
from sonata-multiupload-bundle.
The mime-types comes from provider so before post to multiUploadAction it gets validated. So the validation depends on the configuration of the provider
sonata.media.provider.video:
# ...
arguments:
# ....
- ['mp4', 'mov', 'flv', 'wmv', 'mxf', 'mkv','m4v','mpg']
- ['video/mp4', 'video/quicktime', 'video/x-flv','video/x-ms-wmv','application/mxf','video/x-matroska','video/x-m4v','video/mpeg']
from sonata-multiupload-bundle.
@silasjoisten I don't really remember the origin of my issue but I think there is still a need of using the Symfony form validation as I think we should not trust only the client side and do also our own validation in the controller method (isFormValid, handleRequest, ...) This way we could also for exemple use the Validator component in the Media Entity.
from sonata-multiupload-bundle.
Related Issues (20)
- 4.0.0 version ability to remove provider on runtime over Provider Chain
- Testing `4.0.1-rc` version of this bundle HOT 2
- Rework docs
- Replacing jQuery with VueJS
- Refactoring Translation files
- Return to the media list onComplete HOT 2
- Can't get this bundle to work HOT 1
- Could not upload file in Gallery (Sonata Media Bundle) HOT 6
- Video upload no image shown
- ManagerInterface HOT 1
- Drop PHP 7.0 Support
- Fix TreeBuilder deprecations
- Does not work on Symfony 4 HOT 30
- Cannot autowire service HOT 2
- Argument 1 passed to Sonata\AdminBundle\Controller\CRUDController::get() must be of the type string, null given, called in /var/www/html/Project/vendor/silasjoisten/sonata-multiupload-bundle/src/Controller/MultiUploadController.php on line 55 HOT 13
- Can't get it to work SF4 HOT 1
- Is there any way to define the min/max width-height and orientation requirements? HOT 5
- Update with recent sonata version, drop requirement of "sonata-project/core-bundle" HOT 2
- Add from model type not working anymore HOT 1
- Update Sonata Version HOT 1
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 sonata-multiupload-bundle.