Git Product home page Git Product logo

Comments (7)

darinda avatar darinda commented on June 25, 2024

Implemented in https://github.com/darinda/NetgenEnhancedBinaryFileBundle/commit/826f21b3ff27ea3bae214926024b8d7ee2447a13
But PR #11 should be merged first.

from netgenenhancedbinaryfilebundle.

MarioBlazek avatar MarioBlazek commented on June 25, 2024

@darinda, please create PR based on the code from your fork. Just one notice, maybe a better solution would be to use mimeTypeMessage from translation file rather than saving/reading it from the database.

from netgenenhancedbinaryfilebundle.

darinda avatar darinda commented on June 25, 2024

@MarioBlazek PR has been created. I moved the mimeTypeMessage to the database because it can be translated there. ContentTypes can be translated, so i think this is the correct place to put them.

That way the mimeTypeMessage can be specified like "Please upload only PDF documents!" instead of having the standard symfony message stating something about the mime types which a normal end user won't be able to understand.

from netgenenhancedbinaryfilebundle.

emodric avatar emodric commented on June 25, 2024

Hm, that might make sense. What happens if we leave it to an empty value?

from netgenenhancedbinaryfilebundle.

darinda avatar darinda commented on June 25, 2024

What happens if we leave it to an empty value?

Then symfony's default error message will be displayed, as it was before this pull request.

So The mime type of the file is invalid ({{ type }}). Allowed mime types are {{ types }}.

from netgenenhancedbinaryfilebundle.

darinda avatar darinda commented on June 25, 2024

@emodric bump ;)

from netgenenhancedbinaryfilebundle.

emodric avatar emodric commented on June 25, 2024

I've left a couple of comments on #13.

Otherwise, if everything works, I'm +1 for merging.

@MarioBlazek What do you think?

from netgenenhancedbinaryfilebundle.

Related Issues (6)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.