Provides a simple media/file management GUI for Symfony2

Installs: 518

Dependents: 0

Watchers: 1

Forks: 2

Open Issues: 7

Type: symfony-bundle

v0.2.0 2014-04-24 18:16 UTC


NOTE: This bundle is under heavy development, use at your own risk

Provides a simple media/file management GUI for Symfony2:

  • Integration with CKEditor
  • Media form type with browse server


View Example Source Code


  1. Add to your composer.json:

    composer require zenstruck/media-bundle
  2. Download and install the AngularJS module ngUpload to your web/vendor folder. I suggest using Bower:

    bower install ngUpload
  3. Optional If using the slugify filename feature, add cocur/slugify to your composer.json

    composer require cocur/slugify
  4. Register the bundle with Symfony2:

    // app/AppKernel.php
    public function registerBundles()
        $bundles = array(
            // ...
            new Zenstruck\MediaBundle\ZenstruckMediaBundle(),
            // enable if you want to use the slugify filename feature
            // new Cocur\Slugify\Bridge\Symfony\CocurSlugifyBundle()
        // ...

Full Default Config

    default_layout:       ZenstruckMediaBundle:Twitter:default_layout.html.twig
    slugify_filename_filter:  false
    filesystem_class:     Zenstruck\MediaBundle\Media\Filesystem
    media_form_type:      false
    role_permissions:     false
    filesystems:          # Required

        # Prototype
            root_dir:             %kernel.root_dir%/../web/files # Required
            web_prefix:           /files # Required
            secure:               false # set true and change the path to a non public path for secure file downloads

            # Comma separated list of extensions
            allowed_extensions:   ~ # Example: jpg,gif,png