symfony-cmf / media-bundle

UNMAINTAINED - Minimalistic interfaces to handle media in the context of the CMF
http://cmf.symfony.com/
30 stars 40 forks source link

Could not load type "cmf_media_image" #156

Closed samanmohamadi closed 7 years ago

samanmohamadi commented 7 years ago

Symfony 3

when trying to create an image in admin panel I get this : Could not load type "cmf_media_image"

PHPCR is also enabled.

class ImageAdmin extends AbstractAdmin
{
    protected function configureFormFields(FormMapper $formMapper)
    {
        $formMapper
            ->add('image', 'cmf_media_image', array('required' => false))
        ;
    }
}
cmf_media:
    persistence:
        phpcr:
            enabled:         true
            manager_name:    ~
            media_basepath:  "%cmf_media.persistence.phpcr.media_basepath%"
            media_class:     Symfony\Cmf\Bundle\MediaBundle\Doctrine\Phpcr\Media
            file_class:      Symfony\Cmf\Bundle\MediaBundle\Doctrine\Phpcr\File
            directory_class: Symfony\Cmf\Bundle\MediaBundle\Doctrine\Phpcr\Directory
            image_class:     Symfony\Cmf\Bundle\MediaBundle\Doctrine\Phpcr\Image
            event_listeners:
                stream_rewind:    true
                image_dimensions: true
                imagine_cache:    auto
ElectricMaxxx commented 7 years ago

Which Symfony Version are you using? As this bundle is currently not maintained the bundle does not support Symfony 3.x at all. So form type can be a problem.

ElectricMaxxx commented 7 years ago

I can't reproduce that issue so i will close it, please give some feedback if the issue is still there.